Colobot
|
Camera moving in 3D scene. More...
#include <camera.h>
Public Member Functions | |
bool | EventProcess (const Event &event) |
Management of an event. More... | |
void | Init (Math::Vector eye, Math::Vector lookat, float delay) |
Initializes the camera. More... | |
void | SetControllingObject (CObject *object) |
Sets the object controlling the camera. More... | |
CObject * | GetControllingObject () |
void | SetType (CameraType type) |
Change the type of camera. More... | |
CameraType | GetType () |
void | SetSmooth (CameraSmooth type) |
Management of the smoothing mode. More... | |
CameraSmooth | GetSmooth () |
void | SetDist (float dist) |
Management of the setback distance. More... | |
float | GetDist () |
void | SetFixDirectionH (float angle) |
Manage angle mode CAM_TYPE_FIX. More... | |
float | GetFixDirectionH () |
void | SetFixDirectionV (float angle) |
float | GetFixDirectionV () |
void | SetRemotePan (float value) |
Managing the triggering mode of the camera panning. More... | |
float | GetRemotePan () |
void | SetRemoteZoom (float value) |
Management of the remote zoom (0 .. 1) of the camera. More... | |
float | GetRemoteZoom () |
void | StartVisit (Math::Vector goal, float dist) |
Start with a tour round the camera. More... | |
void | StopVisit () |
Circular end of a visit with the camera. More... | |
void | GetCamera (Math::Vector &eye, Math::Vector &lookat) |
Returns the point of view of the camera. More... | |
bool | StartCentering (CObject *object, float angleH, float angleV, float dist, float time) |
Specifies a special movement of camera to frame action. More... | |
bool | StopCentering (CObject *object, float time) |
Ends a special movement of camera to frame action. More... | |
void | AbortCentering () |
Stop framing special in the current position. More... | |
void | FlushEffect () |
Removes the special effect with the camera. More... | |
void | StartEffect (CameraEffect effect, Math::Vector pos, float force) |
Starts a special effect with the camera. More... | |
void | FlushOver () |
Removes the effect of superposition in the foreground. More... | |
void | SetOverBaseColor (Color color) |
Specifies the base color. More... | |
void | StartOver (CameraOverEffect effect, Math::Vector pos, float force) |
void | FixCamera () |
Sets the soft movement of the camera. More... | |
void | SetScriptEye (Math::Vector eye) |
void | SetScriptLookat (Math::Vector lookat) |
void | SetEffect (bool enable) |
bool | GetEffect () |
void | SetBlood (bool enable) |
bool | GetBlood () |
void | SetOldCameraScroll (bool scroll) |
bool | GetOldCameraScroll () |
void | SetCameraInvertX (bool invert) |
bool | GetCameraInvertX () |
void | SetCameraInvertY (bool invert) |
bool | GetCameraInvertY () |
void | SetCameraSpeed (float speed) |
Protected Member Functions | |
bool | EventMouseMove (const Event &event) |
Changes the camera according to the mouse moved. More... | |
void | EventMouseWheel (const Event &event) |
Mouse wheel operation. More... | |
void | EventMouseButton (const Event &event) |
Mouse button handling. More... | |
bool | EventFrame (const Event &event) |
Changes the camera according to the time elapsed. More... | |
bool | EventFrameFree (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameEdit (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameDialog (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameBack (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameFix (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameExplo (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameOnBoard (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameInfo (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameVisit (const Event &event) |
Moves the point of view. More... | |
bool | EventFrameScript (const Event &event) |
Moves the point of view. More... | |
void | SetViewTime (const Math::Vector &eyePt, const Math::Vector &lookatPt, float rTime) |
Specifies the location and direction of view to the 3D engine. More... | |
bool | IsCollision (Math::Vector &eye, Math::Vector lookat) |
Avoid the obstacles. More... | |
bool | IsCollisionBack (Math::Vector &eye, Math::Vector lookat) |
Avoid the obstacles. More... | |
bool | IsCollisionFix (Math::Vector &eye, Math::Vector lookat) |
Avoid the obstacles. More... | |
Math::Vector | ExcludeTerrain (Math::Vector eye, Math::Vector lookat, float &angleH, float &angleV) |
Adjusts the camera not to enter the ground. More... | |
Math::Vector | ExcludeObject (Math::Vector eye, Math::Vector lookat, float &angleH, float &angleV) |
Adjusts the camera not to enter an object. More... | |
void | SetViewParams (const Math::Vector &eye, const Math::Vector &lookat, const Math::Vector &up) |
Specifies the location and direction of view. More... | |
void | EffectFrame (const Event &event) |
Advances the effect of the camera. More... | |
void | OverFrame (const Event &event) |
Advanced overlay effect in the foreground. More... | |
Protected Attributes | |
CEngine * | m_engine |
CRobotMain * | m_main |
CTerrain * | m_terrain |
CWater * | m_water |
CInput * | m_input |
CameraType | m_type |
The type of camera. More... | |
CameraSmooth | m_smooth |
Type of smoothing. More... | |
CObject * | m_cameraObj |
Object linked to the camera. More... | |
float | m_eyeDistance |
Distance between the eyes. More... | |
float | m_initDelay |
Time of initial centering. More... | |
Math::Vector | m_actualEye |
Current eye. More... | |
Math::Vector | m_actualLookat |
Current aim. More... | |
Math::Vector | m_finalEye |
Final eye. More... | |
Math::Vector | m_finalLookat |
Final aim. More... | |
Math::Vector | m_normEye |
Normal eye. More... | |
Math::Vector | m_normLookat |
Normal aim. More... | |
float | m_focus |
Math::Vector | m_eyePt |
CAM_TYPE_FREE: eye. More... | |
float | m_directionH |
CAM_TYPE_FREE: horizontal direction. More... | |
float | m_directionV |
CAM_TYPE_FREE: vertical direction. More... | |
float | m_heightEye |
CAM_TYPE_FREE: height above the ground. More... | |
float | m_heightLookat |
CAM_TYPE_FREE: height above the ground. More... | |
float | m_speed |
CAM_TYPE_FREE: speed of movement. More... | |
float | m_backDist |
CAM_TYPE_BACK: distance. More... | |
float | m_backMin |
CAM_TYPE_BACK: distance minimal. More... | |
float | m_addDirectionH |
CAM_TYPE_BACK: additional direction. More... | |
float | m_addDirectionV |
CAM_TYPE_BACK: additional direction. More... | |
bool | m_transparency |
float | m_fixDist |
CAM_TYPE_FIX: distance. More... | |
float | m_fixDirectionH |
CAM_TYPE_FIX: direction. More... | |
float | m_fixDirectionV |
CAM_TYPE_FIX: direction. More... | |
Math::Vector | m_visitGoal |
CAM_TYPE_VISIT: target position. More... | |
float | m_visitDist |
CAM_TYPE_VISIT: distance. More... | |
float | m_visitTime |
CAM_TYPE_VISIT: relative time. More... | |
CameraType | m_visitType |
CAM_TYPE_VISIT: initial type. More... | |
float | m_visitDirectionV |
CAM_TYPE_VISIT: direction. More... | |
float | m_editHeight |
CAM_TYPE_EDIT: height. More... | |
float | m_remotePan |
Math::Point | m_mousePos = Math::Point(0.5f, 0.5f) |
Last known mouse position, used to calculate change since last frame. More... | |
Math::Point | m_mouseDelta = Math::Point(0.0f, 0.0f) |
Math::Point | m_mouseDeltaEdge = Math::Point(0.0f, 0.0f) |
CenteringPhase | m_centeringPhase |
float | m_centeringAngleH |
float | m_centeringAngleV |
float | m_centeringDist |
float | m_centeringCurrentH |
float | m_centeringCurrentV |
float | m_centeringTime |
float | m_centeringProgress |
CameraEffect | m_effectType |
Math::Vector | m_effectPos |
float | m_effectForce |
float | m_effectProgress |
Math::Vector | m_effectOffset |
CameraOverEffect | m_overType |
float | m_overForce |
float | m_overTime |
Color | m_overColorBase |
Color | m_overColor |
int | m_overMode |
float | m_overFadeIn |
float | m_overFadeOut |
Math::Vector | m_scriptEye |
Math::Vector | m_scriptLookat |
bool | m_effect |
Shocks if explosion? More... | |
bool | m_blood |
Blood? More... | |
bool | m_oldCameraScroll |
Scroll in the edges? More... | |
bool | m_cameraInvertX |
X inversion in the edges? More... | |
bool | m_cameraInvertY |
Y inversion in the edges? More... | |
Camera moving in 3D scene.
...
bool Gfx::CCamera::EventProcess | ( | const Event & | event | ) |
Management of an event.
void Gfx::CCamera::Init | ( | Math::Vector | eye, |
Math::Vector | lookat, | ||
float | delay | ||
) |
Initializes the camera.
void Gfx::CCamera::SetControllingObject | ( | CObject * | object | ) |
Sets the object controlling the camera.
void Gfx::CCamera::SetType | ( | CameraType | type | ) |
Change the type of camera.
void Gfx::CCamera::SetSmooth | ( | CameraSmooth | type | ) |
Management of the smoothing mode.
void Gfx::CCamera::SetDist | ( | float | dist | ) |
Management of the setback distance.
void Gfx::CCamera::SetFixDirectionH | ( | float | angle | ) |
Manage angle mode CAM_TYPE_FIX.
void Gfx::CCamera::SetRemotePan | ( | float | value | ) |
Managing the triggering mode of the camera panning.
void Gfx::CCamera::SetRemoteZoom | ( | float | value | ) |
Management of the remote zoom (0 .. 1) of the camera.
void Gfx::CCamera::StartVisit | ( | Math::Vector | goal, |
float | dist | ||
) |
Start with a tour round the camera.
void Gfx::CCamera::StopVisit | ( | ) |
Circular end of a visit with the camera.
void Gfx::CCamera::GetCamera | ( | Math::Vector & | eye, |
Math::Vector & | lookat | ||
) |
Returns the point of view of the camera.
bool Gfx::CCamera::StartCentering | ( | CObject * | object, |
float | angleH, | ||
float | angleV, | ||
float | dist, | ||
float | time | ||
) |
Specifies a special movement of camera to frame action.
bool Gfx::CCamera::StopCentering | ( | CObject * | object, |
float | time | ||
) |
Ends a special movement of camera to frame action.
void Gfx::CCamera::AbortCentering | ( | ) |
Stop framing special in the current position.
void Gfx::CCamera::FlushEffect | ( | ) |
Removes the special effect with the camera.
void Gfx::CCamera::StartEffect | ( | CameraEffect | effect, |
Math::Vector | pos, | ||
float | force | ||
) |
Starts a special effect with the camera.
void Gfx::CCamera::FlushOver | ( | ) |
Removes the effect of superposition in the foreground.
void Gfx::CCamera::SetOverBaseColor | ( | Color | color | ) |
Specifies the base color.
void Gfx::CCamera::FixCamera | ( | ) |
Sets the soft movement of the camera.
|
protected |
Changes the camera according to the mouse moved.
|
protected |
Mouse wheel operation.
|
protected |
Mouse button handling.
|
protected |
Changes the camera according to the time elapsed.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Moves the point of view.
|
protected |
Specifies the location and direction of view to the 3D engine.
|
protected |
Avoid the obstacles.
|
protected |
Avoid the obstacles.
|
protected |
Avoid the obstacles.
|
protected |
Adjusts the camera not to enter the ground.
|
protected |
Adjusts the camera not to enter an object.
|
protected |
Specifies the location and direction of view.
|
protected |
Advances the effect of the camera.
|
protected |
Advanced overlay effect in the foreground.
|
protected |
The type of camera.
|
protected |
Type of smoothing.
|
protected |
Object linked to the camera.
|
protected |
Distance between the eyes.
|
protected |
Time of initial centering.
|
protected |
Current eye.
|
protected |
Current aim.
|
protected |
Final eye.
|
protected |
Final aim.
|
protected |
Normal eye.
|
protected |
Normal aim.
|
protected |
CAM_TYPE_FREE: eye.
|
protected |
CAM_TYPE_FREE: horizontal direction.
|
protected |
CAM_TYPE_FREE: vertical direction.
|
protected |
CAM_TYPE_FREE: height above the ground.
|
protected |
CAM_TYPE_FREE: height above the ground.
|
protected |
CAM_TYPE_FREE: speed of movement.
|
protected |
CAM_TYPE_BACK: distance.
|
protected |
CAM_TYPE_BACK: distance minimal.
|
protected |
CAM_TYPE_BACK: additional direction.
|
protected |
CAM_TYPE_BACK: additional direction.
|
protected |
CAM_TYPE_FIX: distance.
|
protected |
CAM_TYPE_FIX: direction.
|
protected |
CAM_TYPE_FIX: direction.
|
protected |
CAM_TYPE_VISIT: target position.
|
protected |
CAM_TYPE_VISIT: distance.
|
protected |
CAM_TYPE_VISIT: relative time.
|
protected |
CAM_TYPE_VISIT: initial type.
|
protected |
CAM_TYPE_VISIT: direction.
|
protected |
CAM_TYPE_EDIT: height.
|
protected |
Last known mouse position, used to calculate change since last frame.
|
protected |
Shocks if explosion?
|
protected |
Blood?
|
protected |
Scroll in the edges?
|
protected |
X inversion in the edges?
|
protected |
Y inversion in the edges?