Added viewer-relative directions

Former-commit-id: 9d80744bd227689426b76df7e3c273de13424041
This commit is contained in:
Lynix
2015-01-03 22:39:51 +01:00
parent 596f407a79
commit ed1cc7a092
11 changed files with 223 additions and 9 deletions

View File

@@ -28,6 +28,9 @@ class NAZARA_API NzAbstractViewer
virtual NzVector3f GetEyePosition() const = 0;
virtual NzVector3f GetForward() const = 0;
virtual const NzFrustumf& GetFrustum() const = 0;
virtual NzVector3f GetGlobalForward() const = 0;
virtual NzVector3f GetGlobalRight() const = 0;
virtual NzVector3f GetGlobalUp() const = 0;
virtual const NzMatrix4f& GetProjectionMatrix() const = 0;
virtual const NzRenderTarget* GetTarget() const = 0;
virtual const NzMatrix4f& GetViewMatrix() const = 0;

View File

@@ -32,6 +32,9 @@ class NAZARA_API NzCamera : public NzAbstractViewer, public NzNode, NzRenderTarg
NzVector3f GetForward() const;
float GetFOV() const;
const NzFrustumf& GetFrustum() const;
NzVector3f GetGlobalForward() const;
NzVector3f GetGlobalRight() const;
NzVector3f GetGlobalUp() const;
const NzMatrix4f& GetProjectionMatrix() const;
const NzRenderTarget* GetTarget() const;
const NzRectf& GetTargetRegion() const;

View File

@@ -41,9 +41,15 @@ class NAZARA_API NzScene
NzColor GetAmbientColor() const;
NzAbstractBackground* GetBackground() const;
NzVector3f GetBackward() const;
NzVector3f GetDown() const;
NzVector3f GetForward() const;
NzVector3f GetLeft() const;
NzAbstractRenderTechnique* GetRenderTechnique() const;
NzVector3f GetRight() const;
NzSceneNode& GetRoot() const;
NzAbstractViewer* GetViewer() const;
NzVector3f GetUp() const;
float GetUpdateTime() const;
unsigned int GetUpdatePerSecond() const;

View File

@@ -27,10 +27,16 @@ class NAZARA_API NzSceneNode : public NzNode
void EnableDrawing(bool drawingEnabled);
NzVector3f GetBackward() const;
virtual const NzBoundingVolumef& GetBoundingVolume() const = 0;
NzVector3f GetDown() const;
NzVector3f GetForward() const;
NzVector3f GetLeft() const;
nzNodeType GetNodeType() const final;
NzVector3f GetRight() const;
NzScene* GetScene() const;
virtual nzSceneNodeType GetSceneNodeType() const = 0;
NzVector3f GetUp() const;
virtual bool IsDrawable() const = 0;
bool IsDrawingEnabled() const;

View File

@@ -32,6 +32,9 @@ class NAZARA_API NzView : public NzAbstractViewer, public NzNode, NzRenderTarget
NzVector3f GetEyePosition() const;
NzVector3f GetForward() const;
const NzFrustumf& GetFrustum() const;
NzVector3f GetGlobalForward() const;
NzVector3f GetGlobalRight() const;
NzVector3f GetGlobalUp() const;
const NzMatrix4f& GetProjectionMatrix() const;
const NzVector2f& GetSize() const;
const NzRenderTarget* GetTarget() const;

View File

@@ -24,26 +24,26 @@ class NAZARA_API NzNode
void EnsureDerivedUpdate() const;
void EnsureTransformMatrixUpdate() const;
NzVector3f GetBackward() const;
virtual NzVector3f GetBackward() const;
const std::vector<NzNode*>& GetChilds() const;
NzVector3f GetDown() const;
NzVector3f GetForward() const;
virtual NzVector3f GetDown() const;
virtual NzVector3f GetForward() const;
bool GetInheritPosition() const;
bool GetInheritRotation() const;
bool GetInheritScale() const;
NzVector3f GetInitialPosition() const;
NzQuaternionf GetInitialRotation() const;
NzVector3f GetInitialScale() const;
NzVector3f GetLeft() const;
virtual NzVector3f GetLeft() const;
const NzString& GetName() const;
virtual nzNodeType GetNodeType() const;
const NzNode* GetParent() const;
NzVector3f GetPosition(nzCoordSys coordSys = nzCoordSys_Global) const;
NzVector3f GetRight() const;
virtual NzVector3f GetRight() const;
NzQuaternionf GetRotation(nzCoordSys coordSys = nzCoordSys_Global) const;
NzVector3f GetScale(nzCoordSys coordSys = nzCoordSys_Global) const;
const NzMatrix4f& GetTransformMatrix() const;
NzVector3f GetUp() const;
virtual NzVector3f GetUp() const;
bool HasChilds() const;
@@ -95,7 +95,7 @@ class NAZARA_API NzNode
virtual void InvalidateNode();
virtual void OnParenting(const NzNode* parent);
void RemoveChild(NzNode* node) const;
void UpdateDerived() const;
virtual void UpdateDerived() const;
virtual void UpdateTransformMatrix() const;
mutable std::vector<NzNode*> m_childs;