NLS Engine  v0.1
The Next Logical Step in game engine design.
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Defines
CameraComponent.h
Go to the documentation of this file.
00001 
00013 #pragma once
00014 
00015 #include "../../sharedbase/ComponentInterface.h"
00016 
00017 namespace GraphicsCore {
00018   class CameraComponent: public ComponentInterface {
00019   public:
00020     CameraComponent(EntitySPTR owner, ModuleInterface* renderModule);
00021 
00022     virtual ~CameraComponent();
00023 
00024     float GetFov();
00025     bool SetFov(float fov);
00026 
00027     float GetFarClipRange();
00028     float GetNearClipRange();
00029     bool SetClipRanges(float nearClip, float farClip);
00030 
00031     D3DXQUATERNION GetRotation();
00032     bool SetRotation(D3DXQUATERNION rot);
00033     bool SetRotation(float yaw, float pitch, float roll);
00034     bool SetOffset(D3DXVECTOR3 offset);
00035     D3DXVECTOR3 GetOffset();
00036     bool ChangeOffset(D3DXVECTOR3 delta);
00037     bool ChangeRotation(D3DXQUATERNION delta);
00038     bool ChangeRotation(float deltaYaw, float deltaPitch, float deltaRoll);
00039 
00040   private:
00041 
00042     // Relative offset
00043     D3DXVECTOR3 offset;
00044 
00045     // Relative rotation
00046     D3DXQUATERNION rotation;
00047 
00048     float fov, nearClip, farClip;
00049   };
00050 }