Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
DX11 - Support non-array texture allocation
  • Loading branch information
softworkz committed May 9, 2020
1 parent 8f22257 commit c09cc37
Show file tree
Hide file tree
Showing 3 changed files with 193 additions and 97 deletions.
16 changes: 8 additions & 8 deletions libavcodec/dxva2.c
Expand Up @@ -559,10 +559,10 @@ static void ff_dxva2_lock(AVCodecContext *avctx)
AVDXVAContext *ctx = DXVA_CONTEXT(avctx);
if (D3D11VA_CONTEXT(ctx)->context_mutex != INVALID_HANDLE_VALUE)
WaitForSingleObjectEx(D3D11VA_CONTEXT(ctx)->context_mutex, INFINITE, FALSE);
if (sctx->device_ctx) {
AVD3D11VADeviceContext *hwctx = sctx->device_ctx->hwctx;
hwctx->lock(hwctx->lock_ctx);
}
////if (sctx->device_ctx) {
//// AVD3D11VADeviceContext *hwctx = sctx->device_ctx->hwctx;
//// hwctx->lock(hwctx->lock_ctx);
////}
}
#endif
}
Expand All @@ -575,10 +575,10 @@ static void ff_dxva2_unlock(AVCodecContext *avctx)
AVDXVAContext *ctx = DXVA_CONTEXT(avctx);
if (D3D11VA_CONTEXT(ctx)->context_mutex != INVALID_HANDLE_VALUE)
ReleaseMutex(D3D11VA_CONTEXT(ctx)->context_mutex);
if (sctx->device_ctx) {
AVD3D11VADeviceContext *hwctx = sctx->device_ctx->hwctx;
hwctx->unlock(hwctx->lock_ctx);
}
////if (sctx->device_ctx) {
//// AVD3D11VADeviceContext *hwctx = sctx->device_ctx->hwctx;
//// hwctx->unlock(hwctx->lock_ctx);
////}
}
#endif
}
Expand Down

0 comments on commit c09cc37

Please sign in to comment.