Skip to content

Commit 39c449f

Browse files
committed
Add null check when getting motion vector fbo
1 parent 06827c9 commit 39c449f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gles3/rasterizer_scene_gles3.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2495,7 +2495,7 @@ void RasterizerSceneGLES3::render_scene(const Ref<RenderSceneBuffers> &p_render_
24952495

24962496
scene_state.reset_gl_state();
24972497

2498-
GLuint motion_vectors_fbo = rt->overridden.velocity_fbo;
2498+
GLuint motion_vectors_fbo = rt ? rt->overridden.velocity_fbo : 0;
24992499
if (motion_vectors_fbo != 0 && GLES3::Config::get_singleton()->max_vertex_attribs >= 22) {
25002500
RENDER_TIMESTAMP("Motion Vectors Pass");
25012501
glBindFramebuffer(GL_FRAMEBUFFER, motion_vectors_fbo);

0 commit comments

Comments
 (0)