You've already forked FFmpeg
							
							
				mirror of
				https://github.com/FFmpeg/FFmpeg.git
				synced 2025-10-30 23:18:11 +02:00 
			
		
		
		
	dxva2: fix surface selection when compiled with both d3d11va and dxva2
Fixes a regression introduced in 9b462a0b9
			
			
This commit is contained in:
		| @@ -41,7 +41,7 @@ unsigned ff_dxva2_get_surface_index(const AVCodecContext *avctx, | ||||
|     void *surface = ff_dxva2_get_surface(frame); | ||||
|     unsigned i; | ||||
|  | ||||
|     for (i = 0; i < DXVA_CONTEXT_COUNT(avctx, ctx); i++) | ||||
|     for (i = 0; i < DXVA_CONTEXT_COUNT(avctx, ctx); i++) { | ||||
| #if CONFIG_D3D11VA | ||||
|         if (avctx->pix_fmt == AV_PIX_FMT_D3D11VA_VLD && ctx->d3d11va.surface[i] == surface) | ||||
|         { | ||||
| @@ -54,6 +54,7 @@ unsigned ff_dxva2_get_surface_index(const AVCodecContext *avctx, | ||||
|         if (avctx->pix_fmt == AV_PIX_FMT_DXVA2_VLD && ctx->dxva2.surface[i] == surface) | ||||
|             return i; | ||||
| #endif | ||||
|     } | ||||
|  | ||||
|     assert(0); | ||||
|     return 0; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user