Fix T44133 SSAO in OpenGL rendering from orthographic camera did not

work

Safe to include in final release
This commit is contained in:
Antonis Ryakiotakis 2015-03-25 15:05:36 +01:00
parent 1a866d55ac
commit 4fd2f678ea
Notes: blender-bot 2023-02-14 09:20:10 +01:00
Referenced by issue #44133, SSAO orthographic camera viewport render bug
1 changed files with 6 additions and 1 deletions

View File

@ -223,7 +223,12 @@ static void screen_opengl_render_apply(OGLRender *oglrender)
/*int is_ortho = scene->r.mode & R_ORTHO;*/
camera = v3d->camera;
RE_GetCameraWindow(oglrender->re, camera, scene->r.cfra, winmat);
is_persp = true;
if (camera->type == OB_CAMERA) {
Camera *cam = camera->data;
is_persp = cam->type == CAM_PERSP;
}
else
is_persp = true;
BKE_camera_to_gpu_dof(camera, &fx_settings);
}
else {