Skip to content

Commit

Permalink
placing camera on z axis
Browse files Browse the repository at this point in the history
  • Loading branch information
jpinedev committed Apr 4, 2023
1 parent 27771a4 commit ed98302
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Controller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ using namespace std;
Controller::Controller(istream& scenegraphFile, Model& m,View& v): model(m), view(v) {
initScenegraph(scenegraphFile);

globalCamera = new StationaryCamera(glm::vec3(200.0, 250.0, 200.0));
globalCamera = new StationaryCamera(glm::vec3(0.0, 0.0, 100.0));
globalCamera->LookAt(glm::vec3(0.0,0.0,0.0));
cameras.push_back(globalCamera);

Expand All @@ -46,7 +46,9 @@ void Controller::initScenegraph(istream& scenegraphFile) {

Controller::~Controller()
{
delete globalCamera;
if (globalCamera) delete globalCamera;
if (helicopterCamera) delete helicopterCamera;
if (firstPersonCamera) delete firstPersonCamera;
}

void Controller::run()
Expand Down

0 comments on commit ed98302

Please sign in to comment.