Project

General

Profile

SO3Engine
SO3::SCamera Class Reference

#include <SO3Camera.h>

Inheritance diagram for SO3::SCamera:
SO3::SNode SO3::SData

Public Member Functions

 SCamera (SScene *parent, const std::string &cameraName)
 
 ~SCamera ()
 
Ogre::Camera * GetOgreCameraPointer ()
 
SViewPortgetCurrentViewPort ()
 
void SetCurrentViewPort (SViewPort *mViewPort)
 
void SetAspectRatio (const float &ratio)
 
void SetAutoAspectRatio (bool state)
 
void SetFrustumOffset (const float &x, const float &y)
 
Ogre::Vector2 GetFrustumOffset ()
 
void SetCustomProjectionMatrix (bool state, Ogre::Matrix4 projmat=Ogre::Matrix4::IDENTITY)
 
float GetAspectRatio ()
 
bool IsFacingPoint (const Ogre::Vector3 &point)
 
Ogre::Vector3 ToScreenSpace (const Ogre::Vector3 &point)
 
virtual void SetRenderingDistance (const float &distance)
 
virtual float GetRenderingDistance ()
 
virtual Ogre::Vector3 GetBoundingBoxSize (const bool &childs=false)
 
virtual Ogre::Vector3 GetBoundingBoxCenter (const bool &childs=false)
 
virtual Ogre::Vector3 GetWorldBoundingBoxSize (const bool &childs=false)
 
virtual Ogre::Vector3 GetWorldBoundingBoxCenter (const bool &childs=false)
 
void SetNearClipDistance (const float &distance)
 
float GetNearClipDistance ()
 
void SetFarClipDistance (const float &distance)
 
float GetFarClipDistance ()
 
const Ogre::Matrix4 & GetProjectionMatrix ()
 
const Ogre::Affine3 & GetViewMatrix ()
 
const Ogre::Real GetFocalLength ()
 
void SetFocalLength (const Ogre::Real &focalLength)
 
float GetFOVy ()
 
void SetFOVy (const float &newFovY)
 
float GetLODbias ()
 
void SetLODbias (const float &bias)
 
void SetProjectionType (const Ogre::ProjectionType &type)
 
Ogre::ProjectionType GetProjectionType ()
 
void SetOrthoWindow (const SPoint< float > &size)
 
SPoint< float > GetOrthoWindow ()
 
unsigned int GetNumRenderedFaces ()
 
unsigned int GetNumRenderedBatches ()
 
- Public Member Functions inherited from SO3::SNode
 SNode (SScene *parent, const std::string &nodeName, const bool &isRootNode=false)
 
virtual ~SNode ()
 
SSceneGetParentScene ()
 
Ogre::SceneNode * GetOgreSceneNodePointer ()
 
Ogre::MovableObject * GetMovableObjectPointer ()
 
bool GetSceneNodeIsMouseForeground ()
 
void SetSceneNodeIsMouseForeground (const bool &mForeground)
 
bool GetSceneNodeIsMouseClick ()
 
void SetSceneNodeIsMouseClick (const bool &mClickable)
 
int GetSceneNodeMouseFlags ()
 
void SetSceneNodeMouseFlags (const int &flags)
 
bool GetSceneNodeHasBody ()
 
SBodyGetSceneNodeBody ()
 
void RestoreStaticGraph ()
 
void SetAsStaticGeometry (const bool &state)
 
bool GetAsStaticGeometry ()
 
Ogre::StaticGeometry * GetStaticGeometry ()
 
void SetFlags (const int &flags)
 
void SetPhysicsOverride (bool state)
 
bool GetPhysicsOverride ()
 
int GetFlags ()
 
void UpdateNodeBody (const bool &bScale)
 
void DisableAutoTarget ()
 
NodeType GetNodeType ()
 
void AttachToParent (SNode *newParentNode)
 
void DetachFromParent ()
 
SNodeGetParentSceneNode ()
 
const SNodeMap GetChildrenNodes () const
 
virtual int GetNumChildren ()
 
void DetachAllChildren ()
 
virtual void SetCastShadows (const bool &castShadows)
 
virtual bool GetCastShadows ()
 
virtual Ogre::Matrix4 GetTransformationMatrix ()
 
virtual Ogre::Vector3 GetPosition ()
 
virtual void SetPosition (const Ogre::Vector3 &pos)
 
virtual Ogre::Quaternion GetOrientation ()
 
virtual void SetOrientation (const Ogre::Quaternion &quat)
 
virtual void AddOrientation (const Ogre::Quaternion &quat)
 
virtual Ogre::Vector3 GetScale ()
 
virtual void SetScale (const Ogre::Vector3 &scale)
 
virtual Ogre::Vector3 GetGlobalPosition ()
 
virtual void SetGlobalPosition (const Ogre::Vector3 &pos, bool updateBody=true)
 
virtual Ogre::Quaternion GetGlobalOrientation ()
 
virtual void SetGlobalOrientation (const Ogre::Quaternion &quat, bool updateBody=true)
 
virtual Ogre::Vector3 GetGlobalScale ()
 
virtual void SetGlobalScale (const Ogre::Vector3 &scale, bool updateBody=true)
 
virtual void StoreInitialPRS ()
 
virtual void ResetToInitialPRS ()
 
void ResetToInitialPosition ()
 
virtual void ResetToInitialOrientation ()
 
void ResetToInitialScale ()
 
virtual Ogre::Vector3 GetInitialPosition ()
 
virtual Ogre::Quaternion GetInitialOrientation ()
 
virtual Ogre::Vector3 GetInitialScale ()
 
bool GetShowBoundingBox ()
 
void SetShowBoundingBox (const bool &showBounding)
 
void SetAutoTracking (const bool &autoTrack, SNode *targetNode=0, const Ogre::Vector3 &localDirectionVector=Ogre::Vector3::NEGATIVE_UNIT_Z, const Ogre::Vector3 &offset=Ogre::Vector3::ZERO)
 
SNodeGetAutoTrackingTarget ()
 
virtual void Pitch (const float &radianAngle, const SNode::NodeTransformSpace &relativeTo=SNode::SO3_LOCAL_TS)
 
virtual void Yaw (const float &radianAngle, const SNode::NodeTransformSpace &relativeTo=SNode::SO3_LOCAL_TS)
 
virtual void Roll (const float &radianAngle, const SNode::NodeTransformSpace &relativeTo=SNode::SO3_LOCAL_TS)
 
virtual void Rotate (const Ogre::Vector3 &axis, const float &radianAngle, const SNode::NodeTransformSpace &relativeTo=SNode::SO3_LOCAL_TS)
 
virtual void Translate (const Ogre::Vector3 &d, const SNode::NodeTransformSpace &relativeTo=SNode::SO3_PARENT_TS)
 
void SetDirection (const Ogre::Vector3 &vec, const SNode::NodeTransformSpace &relativeTo=SNode::SO3_LOCAL_TS, const Ogre::Vector3 &localDirectionVector=Ogre::Vector3::NEGATIVE_UNIT_Z)
 
Ogre::Vector3 GetDirection (bool derived=false, Ogre::Vector3 axis=Ogre::Vector3::NEGATIVE_UNIT_Z)
 
void LookAt (const Ogre::Vector3 &targetPoint, const SNode::NodeTransformSpace &relativeTo, const Ogre::Vector3 &localDirectionVector=Ogre::Vector3::NEGATIVE_UNIT_Z)
 
bool GetVisible ()
 
void SetVisible (const bool &visible, const bool &cascade=true)
 
SNodeAnimationCreateNodeAnimation (const std::string &animationName, const float &animationLength)
 
void DeleteAnimation (SAnim *existingAnimation)
 
size_t GetNumAnimations ()
 
SAnimGetAnimation (const std::string &animationName)
 
SAnimGetAnimation (const unsigned short &animationIndex)
 
SAnimMap GetAnimations () const
 
bool IsAnimated ()
 
Ogre::Vector3 GetPositionFromNode (SNode *nodeRef)
 
Ogre::Quaternion GetOrientationFromNode (SNode *nodeRef)
 
Ogre::Vector3 GetScaleFromNode (SNode *nodeRef)
 
virtual void SetInheritOrientation (const bool &state)
 
virtual bool GetInheritOrientation ()
 
virtual void ResetOrientation ()
 
void DeleteBody ()
 
SBodyCreateBoxBody (const Ogre::Vector3 &boxsetting)
 
SBodyCreateBoxBody (const Ogre::Vector3 &boxsetting, const Ogre::Vector3 &offset, const Ogre::Quaternion &quat)
 
SBodyCreateConeBody (const Ogre::Real &radius, const Ogre::Real &height)
 
SBodyCreateConeBody (const Ogre::Real &radius, const Ogre::Real &height, const Ogre::Vector3 &offset, const Ogre::Quaternion &quat)
 
SBodyCreateEllipsoidBody (const Ogre::Vector3 &size)
 
SBodyCreateEllipsoidBody (const Ogre::Vector3 &size, const Ogre::Vector3 &offset, const Ogre::Quaternion &quat)
 
SBodyCreateCapsuleBody (const Ogre::Real &radius, const Ogre::Real &height)
 
SBodyCreateCapsuleBody (const Ogre::Real &radius, const Ogre::Real &height, const Ogre::Vector3 &offset, const Ogre::Quaternion &quat)
 
SBodyCreateCylinderBody (const Ogre::Real &radius, const Ogre::Real &height)
 
SBodyCreateCylinderBody (const Ogre::Real &radius, const Ogre::Real &height, const Ogre::Vector3 &offset, const Ogre::Quaternion &quat)
 
SBodyCreateChamferCylinderBody (const Ogre::Real &radius, const Ogre::Real &height)
 
SBodyCreateChamferCylinderBody (const Ogre::Real &radius, const Ogre::Real &height, const Ogre::Vector3 &offset, const Ogre::Quaternion &quat)
 
SBodyCreatePyramidBody (const Ogre::Vector3 &size)
 
SBodyCreatePyramidBody (const Ogre::Vector3 &size, const Ogre::Vector3 &offset, const Ogre::Quaternion &quat)
 
SBodyCreateConvexHullBody (const Ogre::Real &tolerance)
 
SBodyCreateConcaveHullBody (const Ogre::Real &tolerance)
 
SBodyCreateTreeBody (const bool &optimize)
 
bool IsDirty ()
 
void SetDirty (bool state)
 
void UpdateNodeFromBody ()
 
void ResetNode ()
 
- Public Member Functions inherited from SO3::SData
 SData (const std::string &dataName)
 
virtual ~SData ()
 
std::string GetName () const
 
SUserObjectBindingsGetUserObjectBindings ()
 
const SUserObjectBindingsGetUserObjectBindings () const
 

Additional Inherited Members

- Public Types inherited from SO3::SNode
enum  NodeType {
  NODE_TYPE_ID = 0 , ENTITY_TYPE_ID = 1 , CAMERA_TYPE_ID = 2 , LIGHT_TYPE_ID = 3 ,
  SKELETON_TYPE_ID = 4 , BONE_TYPE_ID = 5 , PARTICLE_SYSTEM_TYPE_ID = 6 , DYNAMIC_CUBE_MAP_ID = 7 ,
  DYNAMIC_REFLECTION_MAP_ID = 8 , RENDER_TO_TEXTURE_ID = 9 , LINE_ENTITY_TYPE_ID = 10 , VIRTUAL_POINTER_TYPE_ID = 11
}
 
enum  NodeTransformSpace { SO3_LOCAL_TS = 0 , SO3_PARENT_TS = 1 , SO3_WORLD_TS = 2 }
 
- Protected Member Functions inherited from SO3::SNode
 SNode (SScene *parent, const std::string &nodeName, const NodeType &nodeType)
 
void AddAnimation (SAnim *existingAnimation)
 
void RemoveAnimation (SAnim *existingAnimation)
 
void RemoveAnimation (const std::string &animationName)
 
Ogre::Vector3 GetSonsBoundingBox ()
 
Ogre::Vector3 GetSonsWorldBoundingBox ()
 
- Protected Attributes inherited from SO3::SNode
SScenecurrentScene
 
Ogre::SceneNode * O3SceneNode
 
Ogre::MovableObject * ogreMovableObject
 
SBodynodeBody
 
unsigned short animationCounter
 
Ogre::Vector3 initialPosition
 
Ogre::Quaternion initialOrientation
 
Ogre::Vector3 initialScale
 
- Protected Attributes inherited from SO3::SData
std::string name
 

Detailed Description

Definition at line 42 of file SO3Camera.h.

Constructor & Destructor Documentation

◆ SCamera()

SO3::SCamera::SCamera ( SScene parent,
const std::string &  cameraName 
)

Definition at line 22 of file SO3Camera.cpp.

◆ ~SCamera()

SO3::SCamera::~SCamera ( )

Definition at line 38 of file SO3Camera.cpp.

Member Function Documentation

◆ GetAspectRatio()

float SO3::SCamera::GetAspectRatio ( )

Definition at line 84 of file SO3Camera.cpp.

◆ GetBoundingBoxCenter()

Ogre::Vector3 SO3::SCamera::GetBoundingBoxCenter ( const bool &  childs = false)
virtual
Remarks
: SCamera implementation, re-define from SNode .

Reimplemented from SO3::SNode.

Definition at line 145 of file SO3Camera.cpp.

◆ GetBoundingBoxSize()

Ogre::Vector3 SO3::SCamera::GetBoundingBoxSize ( const bool &  childs = false)
virtual
Remarks
: SCamera implementation, re-define from SNode .

Reimplemented from SO3::SNode.

Definition at line 137 of file SO3Camera.cpp.

◆ getCurrentViewPort()

SViewPort * SO3::SCamera::getCurrentViewPort ( )

Definition at line 55 of file SO3Camera.cpp.

◆ GetFarClipDistance()

float SO3::SCamera::GetFarClipDistance ( )

Definition at line 193 of file SO3Camera.cpp.

◆ GetFocalLength()

const Ogre::Real SO3::SCamera::GetFocalLength ( )

Definition at line 209 of file SO3Camera.cpp.

◆ GetFOVy()

float SO3::SCamera::GetFOVy ( )

Definition at line 228 of file SO3Camera.cpp.

◆ GetFrustumOffset()

Ogre::Vector2 SO3::SCamera::GetFrustumOffset ( )

Definition at line 104 of file SO3Camera.cpp.

◆ GetLODbias()

float SO3::SCamera::GetLODbias ( )

Definition at line 248 of file SO3Camera.cpp.

◆ GetNearClipDistance()

float SO3::SCamera::GetNearClipDistance ( )

Definition at line 174 of file SO3Camera.cpp.

◆ GetNumRenderedBatches()

unsigned int SO3::SCamera::GetNumRenderedBatches ( )

Definition at line 298 of file SO3Camera.cpp.

◆ GetNumRenderedFaces()

unsigned int SO3::SCamera::GetNumRenderedFaces ( )

Definition at line 290 of file SO3Camera.cpp.

◆ GetOgreCameraPointer()

Ogre::Camera * SO3::SCamera::GetOgreCameraPointer ( )

Definition at line 50 of file SO3Camera.cpp.

◆ GetOrthoWindow()

SPoint< float > SO3::SCamera::GetOrthoWindow ( )

Definition at line 281 of file SO3Camera.cpp.

◆ GetProjectionMatrix()

const Ogre::Matrix4 & SO3::SCamera::GetProjectionMatrix ( )

Definition at line 198 of file SO3Camera.cpp.

◆ GetProjectionType()

Ogre::ProjectionType SO3::SCamera::GetProjectionType ( )

Definition at line 270 of file SO3Camera.cpp.

◆ GetRenderingDistance()

float SO3::SCamera::GetRenderingDistance ( )
virtual
Remarks
: SCamera implementation, re-define from SNode .

Reimplemented from SO3::SNode.

Definition at line 132 of file SO3Camera.cpp.

◆ GetViewMatrix()

const Ogre::Affine3 & SO3::SCamera::GetViewMatrix ( )

Definition at line 203 of file SO3Camera.cpp.

◆ GetWorldBoundingBoxCenter()

Ogre::Vector3 SO3::SCamera::GetWorldBoundingBoxCenter ( const bool &  childs = false)
virtual
Remarks
: SCamera implementation, re-define from SNode .

Reimplemented from SO3::SNode.

Definition at line 158 of file SO3Camera.cpp.

◆ GetWorldBoundingBoxSize()

Ogre::Vector3 SO3::SCamera::GetWorldBoundingBoxSize ( const bool &  childs = false)
virtual
Remarks
: SCamera implementation, re-define from SNode .

Reimplemented from SO3::SNode.

Definition at line 150 of file SO3Camera.cpp.

◆ IsFacingPoint()

bool SO3::SCamera::IsFacingPoint ( const Ogre::Vector3 &  point)

Definition at line 116 of file SO3Camera.cpp.

◆ SetAspectRatio()

void SO3::SCamera::SetAspectRatio ( const float &  ratio)

Definition at line 72 of file SO3Camera.cpp.

◆ SetAutoAspectRatio()

void SO3::SCamera::SetAutoAspectRatio ( bool  state)

Definition at line 89 of file SO3Camera.cpp.

◆ SetCurrentViewPort()

void SO3::SCamera::SetCurrentViewPort ( SViewPort mViewPort)

Definition at line 60 of file SO3Camera.cpp.

◆ SetCustomProjectionMatrix()

void SO3::SCamera::SetCustomProjectionMatrix ( bool  state,
Ogre::Matrix4  projmat = Ogre::Matrix4::IDENTITY 
)

Definition at line 109 of file SO3Camera.cpp.

◆ SetFarClipDistance()

void SO3::SCamera::SetFarClipDistance ( const float &  distance)

Definition at line 179 of file SO3Camera.cpp.

◆ SetFocalLength()

void SO3::SCamera::SetFocalLength ( const Ogre::Real &  focalLength)

Definition at line 214 of file SO3Camera.cpp.

◆ SetFOVy()

void SO3::SCamera::SetFOVy ( const float &  newFovY)

Definition at line 233 of file SO3Camera.cpp.

◆ SetFrustumOffset()

void SO3::SCamera::SetFrustumOffset ( const float &  x,
const float &  y 
)

Definition at line 99 of file SO3Camera.cpp.

◆ SetLODbias()

void SO3::SCamera::SetLODbias ( const float &  bias)

Definition at line 253 of file SO3Camera.cpp.

◆ SetNearClipDistance()

void SO3::SCamera::SetNearClipDistance ( const float &  distance)

Definition at line 163 of file SO3Camera.cpp.

◆ SetOrthoWindow()

void SO3::SCamera::SetOrthoWindow ( const SPoint< float > &  size)

Definition at line 275 of file SO3Camera.cpp.

◆ SetProjectionType()

void SO3::SCamera::SetProjectionType ( const Ogre::ProjectionType &  type)

Definition at line 263 of file SO3Camera.cpp.

◆ SetRenderingDistance()

void SO3::SCamera::SetRenderingDistance ( const float &  distance)
virtual
Remarks
: SCamera implementation, re-define from SNode .

Reimplemented from SO3::SNode.

Definition at line 127 of file SO3Camera.cpp.

◆ ToScreenSpace()

Ogre::Vector3 SO3::SCamera::ToScreenSpace ( const Ogre::Vector3 &  point)

Definition at line 122 of file SO3Camera.cpp.


The documentation for this class was generated from the following files: