Merge remote-tracking branch 'refs/remotes/origin/master' into culling
This commit is contained in:
@@ -34,21 +34,21 @@ namespace Ndk
|
||||
inline void EnsureViewMatrixUpdate() const;
|
||||
inline void EnsureViewportUpdate() const;
|
||||
|
||||
inline float GetAspectRatio() const override;
|
||||
inline Nz::Vector3f GetEyePosition() const override;
|
||||
inline Nz::Vector3f GetForward() const override;
|
||||
float GetAspectRatio() const override;
|
||||
Nz::Vector3f GetEyePosition() const override;
|
||||
Nz::Vector3f GetForward() const override;
|
||||
inline float GetFOV() const;
|
||||
inline const Nz::Frustumf& GetFrustum() const override;
|
||||
const Nz::Frustumf& GetFrustum() const override;
|
||||
inline unsigned int GetLayer() const;
|
||||
inline const Nz::Matrix4f& GetProjectionMatrix() const override;
|
||||
const Nz::Matrix4f& GetProjectionMatrix() const override;
|
||||
inline Nz::ProjectionType GetProjectionType() const;
|
||||
inline const Nz::Vector2f& GetSize() const;
|
||||
inline const Nz::RenderTarget* GetTarget() const override;
|
||||
const Nz::RenderTarget* GetTarget() const override;
|
||||
inline const Nz::Rectf& GetTargetRegion() const;
|
||||
inline const Nz::Matrix4f& GetViewMatrix() const override;
|
||||
inline const Nz::Recti& GetViewport() const override;
|
||||
inline float GetZFar() const override;
|
||||
inline float GetZNear() const override;
|
||||
const Nz::Matrix4f& GetViewMatrix() const override;
|
||||
const Nz::Recti& GetViewport() const override;
|
||||
float GetZFar() const override;
|
||||
float GetZNear() const override;
|
||||
|
||||
inline void SetFOV(float fov);
|
||||
inline void SetLayer(unsigned int layer);
|
||||
|
||||
@@ -97,40 +97,15 @@ namespace Ndk
|
||||
UpdateViewport();
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the aspect ratio of the camera
|
||||
* \return Aspect ratio of the camera
|
||||
*/
|
||||
|
||||
inline float CameraComponent::GetAspectRatio() const
|
||||
{
|
||||
EnsureViewportUpdate();
|
||||
|
||||
return m_aspectRatio;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the field of view of the camera
|
||||
* \return Field of view of the camera
|
||||
*/
|
||||
|
||||
inline float CameraComponent::GetFOV() const
|
||||
float CameraComponent::GetFOV() const
|
||||
{
|
||||
return m_fov;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the frutum of the camera
|
||||
* \return A constant reference to the frustum of the camera
|
||||
*/
|
||||
|
||||
inline const Nz::Frustumf& CameraComponent::GetFrustum() const
|
||||
{
|
||||
EnsureFrustumUpdate();
|
||||
|
||||
return m_frustum;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the layer of the camera
|
||||
* \return Layer of the camera
|
||||
@@ -141,18 +116,6 @@ namespace Ndk
|
||||
return m_layer;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the projection matrix of the camera
|
||||
* \return A constant reference to the projection matrix of the camera
|
||||
*/
|
||||
|
||||
inline const Nz::Matrix4f& CameraComponent::GetProjectionMatrix() const
|
||||
{
|
||||
EnsureProjectionMatrixUpdate();
|
||||
|
||||
return m_projectionMatrix;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the projection type of the camera
|
||||
* \return Projection type of the camera
|
||||
@@ -173,16 +136,6 @@ namespace Ndk
|
||||
return m_size;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the target of the camera
|
||||
* \return A constant reference to the render target of the camera
|
||||
*/
|
||||
|
||||
inline const Nz::RenderTarget* CameraComponent::GetTarget() const
|
||||
{
|
||||
return m_target;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the target region of the camera
|
||||
* \return A constant reference to the target region of the camera
|
||||
@@ -193,50 +146,6 @@ namespace Ndk
|
||||
return m_targetRegion;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the view matrix of the camera
|
||||
* \return A constant reference to the view matrix of the camera
|
||||
*/
|
||||
|
||||
inline const Nz::Matrix4f& CameraComponent::GetViewMatrix() const
|
||||
{
|
||||
EnsureViewMatrixUpdate();
|
||||
|
||||
return m_viewMatrix;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the view port of the camera
|
||||
* \return A constant reference to the view port of the camera
|
||||
*/
|
||||
|
||||
inline const Nz::Recti& CameraComponent::GetViewport() const
|
||||
{
|
||||
EnsureViewportUpdate();
|
||||
|
||||
return m_viewport;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the Z far distance of the camera
|
||||
* \return Z far distance of the camera
|
||||
*/
|
||||
|
||||
inline float CameraComponent::GetZFar() const
|
||||
{
|
||||
return m_zFar;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Gets the Z near distance of the camera
|
||||
* \return Z near distance of the camera
|
||||
*/
|
||||
|
||||
inline float CameraComponent::GetZNear() const
|
||||
{
|
||||
return m_zNear;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Sets the field of view of the camera
|
||||
*
|
||||
|
||||
@@ -172,4 +172,4 @@ namespace Ndk
|
||||
InvalidateBoundingVolume();
|
||||
InvalidateRenderables();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -51,7 +51,7 @@ namespace Ndk
|
||||
inline bool IsVisible() const;
|
||||
|
||||
void SendCharacter(char32_t character);
|
||||
void SendEvent(Nz::WindowEvent event);
|
||||
void SendEvent(const Nz::WindowEvent& event);
|
||||
|
||||
void SetCharacterSize(unsigned int size);
|
||||
void SetSize(const Nz::Vector2f& size);
|
||||
|
||||
@@ -27,32 +27,15 @@
|
||||
|
||||
#include <Nazara/Prerequesites.hpp>
|
||||
|
||||
// Version of SDK
|
||||
#define NDK_VERSION_MAJOR 0
|
||||
#define NDK_VERSION_MINOR 1
|
||||
|
||||
// Importation/Exportation of the API
|
||||
#if defined(NAZARA_PLATFORM_WINDOWS)
|
||||
#if !defined(NDK_STATIC)
|
||||
#ifdef NDK_BUILD
|
||||
#define NDK_API NAZARA_EXPORT
|
||||
#else
|
||||
#define NDK_API NAZARA_IMPORT
|
||||
#endif
|
||||
#else
|
||||
#define NDK_API
|
||||
#endif
|
||||
#elif defined(NAZARA_PLATFORM_LINUX)
|
||||
#if !defined(NDK_STATIC) && defined(NAZARA_COMPILER_GCC)
|
||||
#define NDK_API NAZARA_EXPORT
|
||||
#else
|
||||
#define NDK_API
|
||||
#endif
|
||||
#if defined(NAZARA_STATIC)
|
||||
#define #define NDK_API
|
||||
#else
|
||||
// To comment to force a compilation
|
||||
#error This operating system is not fully supported by the Nazara Development Kit
|
||||
|
||||
#define NDK_API
|
||||
#ifdef NDK_BUILD
|
||||
#define NDK_API NAZARA_EXPORT
|
||||
#else
|
||||
#define NDK_API NAZARA_IMPORT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
namespace Ndk
|
||||
|
||||
Reference in New Issue
Block a user