Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FFmpeg
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
libremedia
Tethys
FFmpeg
Commits
9bf41210
Commit
9bf41210
authored
12 years ago
by
John Van Sickle
Committed by
Anton Khirnov
12 years ago
Browse files
Options
Downloads
Patches
Plain Diff
libx264: add support for nal-hrd, required for Blu-ray streams.
Signed-off-by:
Anton Khirnov
<
anton@khirnov.net
>
parent
d17d0ec8
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libavcodec/libx264.c
+9
-0
9 additions, 0 deletions
libavcodec/libx264.c
with
9 additions
and
0 deletions
libavcodec/libx264.c
+
9
−
0
View file @
9bf41210
...
...
@@ -69,6 +69,7 @@ typedef struct X264Context {
int
direct_pred
;
int
slice_max_size
;
char
*
stats
;
int
nal_hrd
}
X264Context
;
static
void
X264_log
(
void
*
p
,
int
level
,
const
char
*
fmt
,
va_list
args
)
...
...
@@ -373,6 +374,9 @@ static av_cold int X264_init(AVCodecContext *avctx)
if
(
x4
->
fastfirstpass
)
x264_param_apply_fastfirstpass
(
&
x4
->
params
);
if
(
x4
->
nal_hrd
>=
0
)
x4
->
params
.
i_nal_hrd
=
x4
->
nal_hrd
;
if
(
x4
->
profile
)
if
(
x264_param_apply_profile
(
&
x4
->
params
,
x4
->
profile
)
<
0
)
{
av_log
(
avctx
,
AV_LOG_ERROR
,
"Error setting profile %s.
\n
"
,
x4
->
profile
);
...
...
@@ -518,6 +522,11 @@ static const AVOption options[] = {
{
"auto"
,
NULL
,
0
,
AV_OPT_TYPE_CONST
,
{
.
i64
=
X264_DIRECT_PRED_AUTO
},
0
,
0
,
VE
,
"direct-pred"
},
{
"slice-max-size"
,
"Limit the size of each slice in bytes"
,
OFFSET
(
slice_max_size
),
AV_OPT_TYPE_INT
,
{
.
i64
=
-
1
},
-
1
,
INT_MAX
,
VE
},
{
"stats"
,
"Filename for 2 pass stats"
,
OFFSET
(
stats
),
AV_OPT_TYPE_STRING
,
{
0
},
0
,
0
,
VE
},
{
"nal-hrd"
,
"Signal HRD information (requires vbv-bufsize; "
"cbr not allowed in .mp4)"
,
OFFSET
(
nal_hrd
),
AV_OPT_TYPE_INT
,
{
.
i64
=
-
1
},
-
1
,
INT_MAX
,
VE
,
"nal-hrd"
},
{
"none"
,
NULL
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
X264_NAL_HRD_NONE
},
INT_MIN
,
INT_MAX
,
VE
,
"nal-hrd"
},
{
"vbr"
,
NULL
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
X264_NAL_HRD_VBR
},
INT_MIN
,
INT_MAX
,
VE
,
"nal-hrd"
},
{
"cbr"
,
NULL
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
X264_NAL_HRD_CBR
},
INT_MIN
,
INT_MAX
,
VE
,
"nal-hrd"
},
{
NULL
},
};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment