Skip to content

Commit

Permalink
Merge pull request #278 from phunkyfish/patch-dxva2-windows
Browse files Browse the repository at this point in the history
Patch dxva2 windows
  • Loading branch information
phunkyfish authored Feb 14, 2024
2 parents 6751090 + 7804e51 commit 1834f76
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
diff --git a/libavcodec/dxva2.c b/libavcodec/dxva2.c
--- a/libavcodec/dxva2.c
+++ b/libavcodec/dxva2.c
@@ -777,7 +777,7 @@ unsigned ff_dxva2_get_surface_index(const AVCodecContext *avctx,
#if CONFIG_D3D11VA
if (avctx->pix_fmt == AV_PIX_FMT_D3D11)
return (intptr_t)frame->data[1];
- if (avctx->pix_fmt == AV_PIX_FMT_D3D11VA_VLD) {
+ if (avctx->pix_fmt == AV_PIX_FMT_D3D11VA_VLD && surface) {
D3D11_VIDEO_DECODER_OUTPUT_VIEW_DESC viewDesc;
ID3D11VideoDecoderOutputView_GetDesc((ID3D11VideoDecoderOutputView*) surface, &viewDesc);
return viewDesc.Texture2D.ArraySlice;
2 changes: 1 addition & 1 deletion inputstream.ffmpegdirect/addon.xml.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="inputstream.ffmpegdirect"
version="21.3.2"
version="21.3.3"
name="Inputstream FFmpeg Direct"
provider-name="Ross Nicholson">
<requires>@ADDON_DEPENDS@</requires>
Expand Down
3 changes: 3 additions & 0 deletions inputstream.ffmpegdirect/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
v21.3.3
- Patch to check for nullptr on surface for dxva2 on window

v21.3.2
- Fix deprecations for m_pFormatContext's codecpar->channels for streams ffmpeg6 and a single use of vsprintf

Expand Down

0 comments on commit 1834f76

Please sign in to comment.