瀏覽代碼

fix to avoid video texture scaling

Juan Linietsky 9 年之前
父節點
當前提交
fd6667a7dc
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/gles2/rasterizer_gles2.cpp

+ 1 - 1
drivers/gles2/rasterizer_gles2.cpp

@@ -921,7 +921,7 @@ void RasterizerGLES2::texture_allocate(RID p_texture,int p_width, int p_height,I
 		texture->alloc_height = texture->height;
 	};
 
-	if (shrink_textures_x2) {
+	if (!(p_flags&VS::TEXTURE_FLAG_VIDEO_SURFACE) && shrink_textures_x2) {
 		texture->alloc_height = MAX(1,texture->alloc_height/2);
 		texture->alloc_width = MAX(1,texture->alloc_width/2);
 	}