#ifndef BLUECORE_CAMERA_H
#define BLUECORE_CAMERA_H

// project includes
#include "Utilities/Referenced.h"
#include "Math/Vector.h"
#include "Math/Quaternion.h"
#include "Math/Plane.h"
//#include "geometry/frustum.h"

namespace BlueCore
{

class Camera : public Referenced
{

private:

	Vector3 _LookAtPoint;
	Vector3 _LookAtUp;
	bool _LookAt;
	Scalar _FoV, _NearPlane, _FarPlane;
	//Frustum _Frustum;

	Vector3 _Position;
	Quaternion _Rotation;

	void updateLookAtRotation();

public:

	Camera();
	~Camera();

	void lookAt(const Vector3 &point);
	void lookAt(const Vector3 &point, const Vector3 &up);
	void lookStraight();

	void setFoV(Scalar fov);
	void setNearPlane(Scalar near);
	void setFarPlane(Scalar far);

	void setPosition(const Vector3& position);
	const Vector3& getPosition();

	void setRotation(const Quaternion& rotation);
	const Quaternion& getRotation();

	Scalar getNearPlane() const;
	Scalar getFarPlane() const;
	Scalar getFov() const;

	//const Frustum &getFrustum() const;
};

} // namespace BlueCore

#endif

