git-svn-id: svn://db.shs.com.ru/libs@75 a8b55f48-bf90-11e4-a774-851b48703e85

This commit is contained in:
2016-01-18 14:41:29 +00:00
parent 5b523a65ae
commit d88b341070
28 changed files with 539 additions and 112 deletions

View File

@@ -47,13 +47,13 @@ void Camera::apply(const GLdouble & aspect) {
glMatrixMode(GL_PROJECTION);
if (aspect <= 1.)
glScaled(aspect, aspect, 1.);
QMatrix4x4 pm;// = glMatrixPerspective(fov_, aspect, depth_start, depth_end);
pm.perspective(fov_, aspect, depth_start, depth_end);
QMatrix4x4 pm = glMatrixPerspective(fov_, aspect, depth_start, depth_end);
//pm.perspective(fov_, aspect, depth_start, depth_end);
//qDebug() << pm;// << glMatrixPerspective(fov_, aspect, depth_start, depth_end);
//qDebug() << pm;
setGLMatrix(pm);
glMatrixMode(GL_MODELVIEW);
pm.setToIdentity();
//qDebug() << pm;
pm.translate(0., 0., -distance());
pm.rotate(angles_.y(), 1., 0., 0.);
pm.rotate(angles_.x(), 0., 1., 0.);