src/ui/canvas.cpp

changeset 206
654661eab7f3
parent 205
1a4342d80de7
child 214
8e1fe64ce4e3
equal deleted inserted replaced
205:1a4342d80de7 206:654661eab7f3
381 * @return vector 381 * @return vector
382 */ 382 */
383 glm::vec3 Canvas::cameraVector() const 383 glm::vec3 Canvas::cameraVector() const
384 { 384 {
385 // Find out where the grid is projected on the screen 385 // Find out where the grid is projected on the screen
386 const QPoint gridOrigin2d = pointFToPoint(this->modelToScreenCoordinates(this->gridPlane.anchor)); 386 const QPointF gridOrigin2d = this->modelToScreenCoordinates(this->gridPlane.anchor);
387 // Find out which direction the camera is looking at the grid origin in 3d 387 // Find out which direction the camera is looking at the grid origin in 3d
388 return glm::normalize(this->cameraLine(gridOrigin2d).direction); 388 return glm::normalize(this->cameraLine(gridOrigin2d).direction);
389 } 389 }
390 390
391 /** 391 /**

mercurial