Explorar o código

libobs: Always query shared texture handle for encoding

Always query the texture's shared handle in case the texture had to be
rebuilt from a driver crash.
jp9000 %!s(int64=6) %!d(string=hai) anos
pai
achega
7f01fee8c2
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      libobs/obs-video.c

+ 1 - 1
libobs/obs-video.c

@@ -440,12 +440,12 @@ static inline bool queue_frame(struct obs_core_video *video, bool raw_active,
 
 		tf.tex = tex;
 		tf.tex_uv = tex_uv;
-		tf.handle = gs_texture_get_shared_handle(tex);
 	}
 
 	tf.count = 1;
 	tf.timestamp = vframe_info->timestamp;
 	tf.released = true;
+	tf.handle = gs_texture_get_shared_handle(tf.tex);
 	gs_texture_release_sync(tf.tex, ++tf.lock_key);
 	circlebuf_push_back(&video->gpu_encoder_queue, &tf, sizeof(tf));