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
261e8ccb
Commit
261e8ccb
authored
Jan 16, 2015
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ffmpeg: drop redundant frame_pts value
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
2d0440f9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
5 deletions
+2
-5
ffmpeg.c
ffmpeg.c
+2
-5
No files found.
ffmpeg.c
View file @
261e8ccb
...
@@ -1214,7 +1214,6 @@ static int reap_filters(void)
...
@@ -1214,7 +1214,6 @@ static int reap_filters(void)
{
{
AVFrame
*
filtered_frame
=
NULL
;
AVFrame
*
filtered_frame
=
NULL
;
int
i
;
int
i
;
int64_t
frame_pts
;
/* Reap all buffers present in the buffer sinks */
/* Reap all buffers present in the buffer sinks */
for
(
i
=
0
;
i
<
nb_output_streams
;
i
++
)
{
for
(
i
=
0
;
i
<
nb_output_streams
;
i
++
)
{
...
@@ -1247,10 +1246,10 @@ static int reap_filters(void)
...
@@ -1247,10 +1246,10 @@ static int reap_filters(void)
av_frame_unref
(
filtered_frame
);
av_frame_unref
(
filtered_frame
);
continue
;
continue
;
}
}
frame_pts
=
AV_NOPTS_VALUE
;
if
(
filtered_frame
->
pts
!=
AV_NOPTS_VALUE
)
{
if
(
filtered_frame
->
pts
!=
AV_NOPTS_VALUE
)
{
int64_t
start_time
=
(
of
->
start_time
==
AV_NOPTS_VALUE
)
?
0
:
of
->
start_time
;
int64_t
start_time
=
(
of
->
start_time
==
AV_NOPTS_VALUE
)
?
0
:
of
->
start_time
;
filtered_frame
->
pts
=
frame_pts
=
filtered_frame
->
pts
=
av_rescale_q
(
filtered_frame
->
pts
,
filter
->
inputs
[
0
]
->
time_base
,
enc
->
time_base
)
-
av_rescale_q
(
filtered_frame
->
pts
,
filter
->
inputs
[
0
]
->
time_base
,
enc
->
time_base
)
-
av_rescale_q
(
start_time
,
AV_TIME_BASE_Q
,
enc
->
time_base
);
av_rescale_q
(
start_time
,
AV_TIME_BASE_Q
,
enc
->
time_base
);
}
}
...
@@ -1259,7 +1258,6 @@ static int reap_filters(void)
...
@@ -1259,7 +1258,6 @@ static int reap_filters(void)
switch
(
filter
->
inputs
[
0
]
->
type
)
{
switch
(
filter
->
inputs
[
0
]
->
type
)
{
case
AVMEDIA_TYPE_VIDEO
:
case
AVMEDIA_TYPE_VIDEO
:
filtered_frame
->
pts
=
frame_pts
;
if
(
!
ost
->
frame_aspect_ratio
.
num
)
if
(
!
ost
->
frame_aspect_ratio
.
num
)
enc
->
sample_aspect_ratio
=
filtered_frame
->
sample_aspect_ratio
;
enc
->
sample_aspect_ratio
=
filtered_frame
->
sample_aspect_ratio
;
...
@@ -1272,7 +1270,6 @@ static int reap_filters(void)
...
@@ -1272,7 +1270,6 @@ static int reap_filters(void)
do_video_out
(
of
->
ctx
,
ost
,
filtered_frame
);
do_video_out
(
of
->
ctx
,
ost
,
filtered_frame
);
break
;
break
;
case
AVMEDIA_TYPE_AUDIO
:
case
AVMEDIA_TYPE_AUDIO
:
filtered_frame
->
pts
=
frame_pts
;
if
(
!
(
enc
->
codec
->
capabilities
&
CODEC_CAP_PARAM_CHANGE
)
&&
if
(
!
(
enc
->
codec
->
capabilities
&
CODEC_CAP_PARAM_CHANGE
)
&&
enc
->
channels
!=
av_frame_get_channels
(
filtered_frame
))
{
enc
->
channels
!=
av_frame_get_channels
(
filtered_frame
))
{
av_log
(
NULL
,
AV_LOG_ERROR
,
av_log
(
NULL
,
AV_LOG_ERROR
,
...
...
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