Disable high quality depth of field for GPUs that don't support it,
system will fall back to low quality depth of field. Also add check in case some of the errors are caused by crappy framebuffer object support.
This commit is contained in:
@@ -469,7 +469,7 @@ bool GPU_fx_compositor_initialize_passes(
|
||||
}
|
||||
}
|
||||
|
||||
fx->dof_high_quality = dof_high_quality;
|
||||
fx->dof_high_quality = dof_high_quality && GPU_geometry_shader_support() && GPU_instanced_drawing_support();
|
||||
}
|
||||
else {
|
||||
/* cleanup unnecessary buffers */
|
||||
@@ -851,6 +851,8 @@ bool GPU_fx_do_composite_pass(GPUFX *fx, float projmat[4][4], bool is_persp, str
|
||||
/* binding takes care of setting the viewport to the downsampled size */
|
||||
GPU_framebuffer_slots_bind(fx->gbuffer, 0);
|
||||
|
||||
GPU_framebuffer_check_valid(fx->gbuffer);
|
||||
|
||||
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
|
||||
/* disable bindings */
|
||||
GPU_texture_filter_mode(src, false, true);
|
||||
|
||||
Reference in New Issue
Block a user