Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
5a5df90d
Commit
5a5df90d
authored
Sep 30, 2016
by
Mark Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vaapi_h265: Add main 10 encode support
parent
eaaaabf6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
vaapi_encode_h265.c
libavcodec/vaapi_encode_h265.c
+8
-8
No files found.
libavcodec/vaapi_encode_h265.c
View file @
5a5df90d
...
...
@@ -803,8 +803,10 @@ static int vaapi_encode_h265_init_sequence_params(AVCodecContext *avctx)
vseq
->
seq_fields
.
bits
.
chroma_format_idc
=
1
;
// 4:2:0.
vseq
->
seq_fields
.
bits
.
separate_colour_plane_flag
=
0
;
vseq
->
seq_fields
.
bits
.
bit_depth_luma_minus8
=
0
;
// 8-bit luma.
vseq
->
seq_fields
.
bits
.
bit_depth_chroma_minus8
=
0
;
// 8-bit chroma.
vseq
->
seq_fields
.
bits
.
bit_depth_luma_minus8
=
avctx
->
profile
==
FF_PROFILE_HEVC_MAIN_10
?
2
:
0
;
vseq
->
seq_fields
.
bits
.
bit_depth_chroma_minus8
=
avctx
->
profile
==
FF_PROFILE_HEVC_MAIN_10
?
2
:
0
;
// Other misc flags all zero.
// These have to come from the capabilities of the encoder. We have
...
...
@@ -1231,11 +1233,12 @@ static av_cold int vaapi_encode_h265_init(AVCodecContext *avctx)
case
FF_PROFILE_HEVC_MAIN
:
case
FF_PROFILE_UNKNOWN
:
ctx
->
va_profile
=
VAProfileHEVCMain
;
ctx
->
va_rt_format
=
VA_RT_FORMAT_YUV420
;
break
;
case
FF_PROFILE_HEVC_MAIN_10
:
av_log
(
avctx
,
AV_LOG_ERROR
,
"H.265 main 10-bit profile "
"is not supported.
\n
"
)
;
return
AVERROR_PATCHWELCOME
;
ctx
->
va_profile
=
VAProfileHEVCMain10
;
ctx
->
va_rt_format
=
VA_RT_FORMAT_YUV420_10BPP
;
break
;
default:
av_log
(
avctx
,
AV_LOG_ERROR
,
"Unknown H.265 profile %d.
\n
"
,
avctx
->
profile
);
...
...
@@ -1243,9 +1246,6 @@ static av_cold int vaapi_encode_h265_init(AVCodecContext *avctx)
}
ctx
->
va_entrypoint
=
VAEntrypointEncSlice
;
// This will be dependent on profile when 10-bit is supported.
ctx
->
va_rt_format
=
VA_RT_FORMAT_YUV420
;
if
(
avctx
->
bit_rate
>
0
)
ctx
->
va_rc_mode
=
VA_RC_CBR
;
else
...
...
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