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
0667327f
Commit
0667327f
authored
Mar 24, 2016
by
Rodger Combs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavc/audiotoolboxenc: fix iOS build
parent
c820e600
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
audiotoolboxenc.c
libavcodec/audiotoolboxenc.c
+6
-1
No files found.
libavcodec/audiotoolboxenc.c
View file @
0667327f
...
@@ -307,6 +307,7 @@ static av_cold int ffat_init_encoder(AVCodecContext *avctx)
...
@@ -307,6 +307,7 @@ static av_cold int ffat_init_encoder(AVCodecContext *avctx)
sizeof
(
avctx
->
bits_per_raw_sample
),
sizeof
(
avctx
->
bits_per_raw_sample
),
&
avctx
->
bits_per_raw_sample
);
&
avctx
->
bits_per_raw_sample
);
#if !TARGET_OS_IPHONE
if
(
at
->
mode
==
-
1
)
if
(
at
->
mode
==
-
1
)
at
->
mode
=
(
avctx
->
flags
&
AV_CODEC_FLAG_QSCALE
)
?
at
->
mode
=
(
avctx
->
flags
&
AV_CODEC_FLAG_QSCALE
)
?
kAudioCodecBitRateControlMode_Variable
:
kAudioCodecBitRateControlMode_Variable
:
...
@@ -325,7 +326,9 @@ static av_cold int ffat_init_encoder(AVCodecContext *avctx)
...
@@ -325,7 +326,9 @@ static av_cold int ffat_init_encoder(AVCodecContext *avctx)
q
=
127
-
q
*
9
;
q
=
127
-
q
*
9
;
AudioConverterSetProperty
(
at
->
converter
,
kAudioCodecPropertySoundQualityForVBR
,
AudioConverterSetProperty
(
at
->
converter
,
kAudioCodecPropertySoundQualityForVBR
,
sizeof
(
q
),
&
q
);
sizeof
(
q
),
&
q
);
}
else
if
(
avctx
->
bit_rate
>
0
)
{
}
else
#endif
if
(
avctx
->
bit_rate
>
0
)
{
UInt32
rate
=
avctx
->
bit_rate
;
UInt32
rate
=
avctx
->
bit_rate
;
UInt32
size
;
UInt32
size
;
status
=
AudioConverterGetPropertyInfo
(
at
->
converter
,
status
=
AudioConverterGetPropertyInfo
(
at
->
converter
,
...
@@ -553,12 +556,14 @@ static const AVProfile aac_profiles[] = {
...
@@ -553,12 +556,14 @@ static const AVProfile aac_profiles[] = {
#define AE AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_ENCODING_PARAM
#define AE AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_ENCODING_PARAM
static
const
AVOption
options
[]
=
{
static
const
AVOption
options
[]
=
{
#if !TARGET_OS_IPHONE
{
"aac_at_mode"
,
"ratecontrol mode"
,
offsetof
(
ATDecodeContext
,
mode
),
AV_OPT_TYPE_INT
,
{.
i64
=
-
1
},
-
1
,
kAudioCodecBitRateControlMode_Variable
,
AE
,
"mode"
},
{
"aac_at_mode"
,
"ratecontrol mode"
,
offsetof
(
ATDecodeContext
,
mode
),
AV_OPT_TYPE_INT
,
{.
i64
=
-
1
},
-
1
,
kAudioCodecBitRateControlMode_Variable
,
AE
,
"mode"
},
{
"auto"
,
"VBR if global quality is given; CBR otherwise"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
-
1
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"auto"
,
"VBR if global quality is given; CBR otherwise"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
-
1
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"cbr"
,
"constant bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_Constant
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"cbr"
,
"constant bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_Constant
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"abr"
,
"long-term average bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_LongTermAverage
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"abr"
,
"long-term average bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_LongTermAverage
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"cvbr"
,
"constrained variable bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_VariableConstrained
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"cvbr"
,
"constrained variable bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_VariableConstrained
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"vbr"
,
"variable bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_Variable
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
{
"vbr"
,
"variable bitrate"
,
0
,
AV_OPT_TYPE_CONST
,
{.
i64
=
kAudioCodecBitRateControlMode_Variable
},
INT_MIN
,
INT_MAX
,
AE
,
"mode"
},
#endif
{
"aac_at_quality"
,
"quality vs speed control"
,
offsetof
(
ATDecodeContext
,
quality
),
AV_OPT_TYPE_INT
,
{.
i64
=
0
},
0
,
2
,
AE
},
{
"aac_at_quality"
,
"quality vs speed control"
,
offsetof
(
ATDecodeContext
,
quality
),
AV_OPT_TYPE_INT
,
{.
i64
=
0
},
0
,
2
,
AE
},
{
NULL
},
{
NULL
},
};
};
...
...
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