Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
ffmpeg
Commits
a7e03804
Commit
a7e03804
authored
Jan 25, 2015
by
Hendrik Leppkes
Committed by
Anton Khirnov
Jan 27, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avconv_dxva2: add hevc support
Signed-off-by:
Anton Khirnov
<
anton@khirnov.net
>
parent
7e850fa6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
avconv_dxva2.c
avconv_dxva2.c
+9
-1
No files found.
avconv_dxva2.c
View file @
a7e03804
...
...
@@ -52,6 +52,7 @@ DEFINE_GUID(DXVA2_ModeH264_F, 0x1b81be69, 0xa0c7,0x11d3,0xb9,0x84,0x00,0
DEFINE_GUID
(
DXVADDI_Intel_ModeH264_E
,
0x604F8E68
,
0x4951
,
0x4C54
,
0x88
,
0xFE
,
0xAB
,
0xD2
,
0x5C
,
0x15
,
0xB3
,
0xD6
);
DEFINE_GUID
(
DXVA2_ModeVC1_D
,
0x1b81beA3
,
0xa0c7
,
0x11d3
,
0xb9
,
0x84
,
0x00
,
0xc0
,
0x4f
,
0x2e
,
0x73
,
0xc5
);
DEFINE_GUID
(
DXVA2_ModeVC1_D2010
,
0x1b81beA4
,
0xa0c7
,
0x11d3
,
0xb9
,
0x84
,
0x00
,
0xc0
,
0x4f
,
0x2e
,
0x73
,
0xc5
);
DEFINE_GUID
(
DXVA2_ModeHEVC_VLD_Main
,
0x5b11d51b
,
0x2f4c
,
0x4452
,
0xbc
,
0xc3
,
0x09
,
0xf2
,
0xa1
,
0x16
,
0x0c
,
0xc0
);
DEFINE_GUID
(
DXVA2_NoEncrypt
,
0x1b81beD0
,
0xa0c7
,
0x11d3
,
0xb9
,
0x84
,
0x00
,
0xc0
,
0x4f
,
0x2e
,
0x73
,
0xc5
);
DEFINE_GUID
(
GUID_NULL
,
0x00000000
,
0x0000
,
0x0000
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
);
...
...
@@ -80,6 +81,9 @@ static const dxva2_mode dxva2_modes[] = {
{
&
DXVA2_ModeVC1_D
,
AV_CODEC_ID_VC1
},
{
&
DXVA2_ModeVC1_D
,
AV_CODEC_ID_WMV3
},
/* HEVC/H.265 */
{
&
DXVA2_ModeHEVC_VLD_Main
,
AV_CODEC_ID_HEVC
},
{
NULL
,
0
},
};
...
...
@@ -525,6 +529,10 @@ static int dxva2_create_decoder(AVCodecContext *s)
but it causes issues for H.264 on certain AMD GPUs..... */
if
(
s
->
codec_id
==
AV_CODEC_ID_MPEG2VIDEO
)
surface_alignment
=
32
;
/* the HEVC DXVA2 spec asks for 128 pixel aligned surfaces to ensure
all coding features have enough room to work with */
else
if
(
s
->
codec_id
==
AV_CODEC_ID_HEVC
)
surface_alignment
=
128
;
else
surface_alignment
=
16
;
...
...
@@ -532,7 +540,7 @@ static int dxva2_create_decoder(AVCodecContext *s)
ctx
->
num_surfaces
=
4
;
/* add surfaces based on number of possible refs */
if
(
s
->
codec_id
==
AV_CODEC_ID_H264
)
if
(
s
->
codec_id
==
AV_CODEC_ID_H264
||
s
->
codec_id
==
AV_CODEC_ID_HEVC
)
ctx
->
num_surfaces
+=
16
;
else
ctx
->
num_surfaces
+=
2
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment