Skip to content

Commit

Permalink
change functions for windows
Browse files Browse the repository at this point in the history
  • Loading branch information
comaralex committed Mar 22, 2017
1 parent ffd067f commit 3744c0a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
12 changes: 6 additions & 6 deletions src/core/blcamera.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,20 @@ class Camera {
public:

Camera();
Camera(float fov, float ratio, float near, float far);
Camera(float fov, float ratio, float nearPlane, float farPlane);

virtual ~Camera();

// Setters
void setPerspective(float fov, float ratio,
float near, float far);
float nearPlane, float farPlane);

void setPerspective(const QMatrix4x4 &perspective);

void setFov(float fov);
void setAspectRatio(float ratio);
void setNearPlane(float near);
void setFarPlane(float far);
void setNearPlane(float nearPlane);
void setFarPlane(float farPlane);

void setView(const QVector3D &position,
const QVector3D &lookAt,
Expand Down Expand Up @@ -67,8 +67,8 @@ class Camera {
// Getters
float fov() const { return m_fov; }
float ratio() const { return m_ratio; }
float near() const { return m_near; }
float far() const { return m_far; }
float nearPlane() const { return m_near; }
float farPlane() const { return m_far; }

QMatrix4x4 perspective();
QMatrix4x4 view();
Expand Down
2 changes: 2 additions & 0 deletions src/core/blmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ Model::Model()
m_rotation(), m_matModel(),
m_needUpdate()
{
initializeOpenGLFunctions();

m_texture = std::shared_ptr<Texture>(ResourceManager::getInstance()
.get<Texture>("textures/default.jpg"));
}
Expand Down
2 changes: 1 addition & 1 deletion src/core/blmodel.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ namespace black {
* @version 1.0 19.03.2017
* Working version of Model class
*/
class Model : public Resource
class Model : public Resource, private QOpenGLFunctions
{
friend class ResourceManager;
public:
Expand Down

0 comments on commit 3744c0a

Please sign in to comment.