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
0508657f
Commit
0508657f
authored
Aug 02, 2015
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avcodec/cngenc: Use ff_alloc_packet2()
Signed-off-by:
Michael Niedermayer
<
michael@niedermayer.cc
>
parent
7e9cd4e1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
cngenc.c
libavcodec/cngenc.c
+2
-2
No files found.
libavcodec/cngenc.c
View file @
0508657f
...
...
@@ -75,7 +75,7 @@ static int cng_encode_frame(AVCodecContext *avctx, AVPacket *avpkt,
int
qdbov
;
int16_t
*
samples
=
(
int16_t
*
)
frame
->
data
[
0
];
if
((
ret
=
ff_alloc_packet
(
avpkt
,
1
+
p
->
order
)))
{
if
((
ret
=
ff_alloc_packet
2
(
avctx
,
avpkt
,
1
+
p
->
order
,
1
+
p
->
order
)))
{
av_log
(
avctx
,
AV_LOG_ERROR
,
"Error getting output packet
\n
"
);
return
ret
;
}
...
...
@@ -97,7 +97,7 @@ static int cng_encode_frame(AVCodecContext *avctx, AVPacket *avpkt,
avpkt
->
data
[
1
+
i
]
=
p
->
ref_coef
[
i
]
*
127
+
127
;
*
got_packet_ptr
=
1
;
av
pkt
->
size
=
1
+
p
->
order
;
av
_assert1
(
avpkt
->
size
==
1
+
p
->
order
)
;
return
0
;
}
...
...
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