Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
F
ffmpeg
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ffmpeg
Commits
1d3eb0b5
Commit
1d3eb0b5
authored
May 26, 2014
by
Andrew Kelley
Committed by
Martin Storsjö
May 27, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
oggenc: Move ogg_write_pages up above ogg_write_header
Signed-off-by:
Martin Storsjö
<
martin@martin.st
>
parent
512f3ffe
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
22 deletions
+22
-22
oggenc.c
libavformat/oggenc.c
+22
-22
No files found.
libavformat/oggenc.c
View file @
1d3eb0b5
...
...
@@ -388,6 +388,28 @@ static int ogg_build_opus_headers(AVCodecContext *avctx,
return
0
;
}
static
void
ogg_write_pages
(
AVFormatContext
*
s
,
int
flush
)
{
OGGContext
*
ogg
=
s
->
priv_data
;
OGGPageList
*
next
,
*
p
;
if
(
!
ogg
->
page_list
)
return
;
for
(
p
=
ogg
->
page_list
;
p
;
)
{
OGGStreamContext
*
oggstream
=
s
->
streams
[
p
->
page
.
stream_index
]
->
priv_data
;
if
(
oggstream
->
page_count
<
2
&&
!
flush
)
break
;
ogg_write_page
(
s
,
&
p
->
page
,
flush
&&
oggstream
->
page_count
==
1
?
4
:
0
);
// eos
next
=
p
->
next
;
av_freep
(
&
p
);
p
=
next
;
}
ogg
->
page_list
=
p
;
}
static
int
ogg_write_header
(
AVFormatContext
*
s
)
{
OGGContext
*
ogg
=
s
->
priv_data
;
...
...
@@ -522,28 +544,6 @@ static int ogg_write_header(AVFormatContext *s)
return
0
;
}
static
void
ogg_write_pages
(
AVFormatContext
*
s
,
int
flush
)
{
OGGContext
*
ogg
=
s
->
priv_data
;
OGGPageList
*
next
,
*
p
;
if
(
!
ogg
->
page_list
)
return
;
for
(
p
=
ogg
->
page_list
;
p
;
)
{
OGGStreamContext
*
oggstream
=
s
->
streams
[
p
->
page
.
stream_index
]
->
priv_data
;
if
(
oggstream
->
page_count
<
2
&&
!
flush
)
break
;
ogg_write_page
(
s
,
&
p
->
page
,
flush
&&
oggstream
->
page_count
==
1
?
4
:
0
);
// eos
next
=
p
->
next
;
av_freep
(
&
p
);
p
=
next
;
}
ogg
->
page_list
=
p
;
}
static
int
ogg_write_packet
(
AVFormatContext
*
s
,
AVPacket
*
pkt
)
{
AVStream
*
st
=
s
->
streams
[
pkt
->
stream_index
];
...
...
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