Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-1.1
Commits
2f64eb29
Commit
2f64eb29
authored
Jan 15, 2001
by
Christophe Massiot
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* Fixed a bug in the frame rate handling ;
* Fixed a bug in the DTS/PTS ordering. Our pts are _at last_ accurate.
parent
3a3f1725
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
17 deletions
+23
-17
src/video_decoder/vpar_synchro.h
src/video_decoder/vpar_synchro.h
+4
-2
src/video_parser/vpar_headers.c
src/video_parser/vpar_headers.c
+3
-2
src/video_parser/vpar_synchro.c
src/video_parser/vpar_synchro.c
+16
-13
No files found.
src/video_decoder/vpar_synchro.h
View file @
2f64eb29
...
...
@@ -2,7 +2,7 @@
* vpar_synchro.h : video parser blocks management
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: vpar_synchro.h,v 1.
5 2001/01/15 18:02:49
massiot Exp $
* $Id: vpar_synchro.h,v 1.
6 2001/01/15 19:54:34
massiot Exp $
*
* Author: Christophe Massiot <massiot@via.ecp.fr>
*
...
...
@@ -64,7 +64,9 @@ typedef struct video_synchro_s
unsigned
int
i_eta_p
,
i_eta_b
;
boolean_t
b_dropped_last
;
/* for special synchros below */
mtime_t
backward_pts
,
current_pts
;
mtime_t
next_period
;
/* period to add to the next picture */
mtime_t
current_period
;
/* period to add to the next picture */
mtime_t
backward_period
;
/* period to add after the next
* reference picture */
#ifdef STATS
unsigned
int
i_trashed_pic
,
i_not_chosen_pic
,
i_pic
;
...
...
src/video_parser/vpar_headers.c
View file @
2f64eb29
...
...
@@ -2,7 +2,7 @@
* vpar_headers.c : headers parsing
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: vpar_headers.c,v 1.
69 2001/01/15 18:02:49
massiot Exp $
* $Id: vpar_headers.c,v 1.
70 2001/01/15 19:54:34
massiot Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
* Stphane Borel <stef@via.ecp.fr>
...
...
@@ -565,7 +565,8 @@ static void PictureHeader( vpar_thread_t * p_vpar )
p_vpar
->
picture
.
b_q_scale_type
=
0
;
p_vpar
->
picture
.
b_intra_vlc_format
=
0
;
p_vpar
->
picture
.
b_alternate_scan
=
0
;
/* zigzag */
p_vpar
->
picture
.
b_repeat_first_field
=
1
;
p_vpar
->
picture
.
b_repeat_first_field
=
1
;
/* FIXME! this contradicts
* ISO/IEC */
p_vpar
->
picture
.
b_progressive
=
1
;
}
...
...
src/video_parser/vpar_synchro.c
View file @
2f64eb29
...
...
@@ -2,7 +2,7 @@
* vpar_synchro.c : frame dropping routines
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: vpar_synchro.c,v 1.7
3 2001/01/15 18:02:49
massiot Exp $
* $Id: vpar_synchro.c,v 1.7
4 2001/01/15 19:54:34
massiot Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
* Samuel Hocevar <sam@via.ecp.fr>
...
...
@@ -150,7 +150,8 @@ void vpar_SynchroInit( vpar_thread_t * p_vpar )
memset
(
p_vpar
->
synchro
.
pi_meaningful
,
0
,
4
*
sizeof
(
unsigned
int
)
);
p_vpar
->
synchro
.
b_dropped_last
=
0
;
p_vpar
->
synchro
.
current_pts
=
mdate
()
+
DEFAULT_PTS_DELAY
;
p_vpar
->
synchro
.
backward_pts
=
p_vpar
->
synchro
.
next_period
=
0
;
p_vpar
->
synchro
.
backward_pts
=
p_vpar
->
synchro
.
current_period
=
p_vpar
->
synchro
.
backward_period
=
0
;
#ifdef STATS
p_vpar
->
synchro
.
i_trashed_pic
=
p_vpar
->
synchro
.
i_not_chosen_pic
=
p_vpar
->
synchro
.
i_pic
=
0
;
...
...
@@ -228,7 +229,7 @@ boolean_t vpar_SynchroChoose( vpar_thread_t * p_vpar, int i_coding_type,
#endif
now
=
mdate
();
period
=
1000000
/
(
p_vpar
->
sequence
.
i_frame_rate
)
*
1001
;
period
=
1000000
*
1001
/
p_vpar
->
sequence
.
i_frame_rate
;
vlc_mutex_lock
(
&
p_vpar
->
p_vout
->
change_lock
);
tau_yuv
=
p_vpar
->
p_vout
->
render_time
;
...
...
@@ -420,7 +421,7 @@ mtime_t vpar_SynchroDate( vpar_thread_t * p_vpar )
void
vpar_SynchroNewPicture
(
vpar_thread_t
*
p_vpar
,
int
i_coding_type
,
int
i_repeat_field
)
{
mtime_t
period
=
1000000
/
(
p_vpar
->
sequence
.
i_frame_rate
)
*
1001
;
mtime_t
period
=
1000000
*
1001
/
p_vpar
->
sequence
.
i_frame_rate
;
switch
(
i_coding_type
)
{
...
...
@@ -468,16 +469,16 @@ void vpar_SynchroNewPicture( vpar_thread_t * p_vpar, int i_coding_type,
break
;
}
p_vpar
->
synchro
.
current_pts
+=
p_vpar
->
synchro
.
next_period
;
/* A video frame can be displayed 1, 2 or 3 times, according to
* repeat_first_field, top_field_first, progressive_sequence and
* progressive_frame. */
p_vpar
->
synchro
.
next_period
=
i_repeat_field
*
(
period
>>
1
);
p_vpar
->
synchro
.
current_pts
+=
p_vpar
->
synchro
.
current_period
;
#define PTS_THRESHOLD (period >> 2)
if
(
i_coding_type
==
B_CODING_TYPE
)
{
/* A video frame can be displayed 1, 2 or 3 times, according to
* repeat_first_field, top_field_first, progressive_sequence and
* progressive_frame. */
p_vpar
->
synchro
.
current_period
=
i_repeat_field
*
(
period
>>
1
);
if
(
p_vpar
->
sequence
.
next_pts
)
{
if
(
p_vpar
->
sequence
.
next_pts
-
p_vpar
->
synchro
.
current_pts
...
...
@@ -496,6 +497,9 @@ void vpar_SynchroNewPicture( vpar_thread_t * p_vpar, int i_coding_type,
}
else
{
p_vpar
->
synchro
.
current_period
=
p_vpar
->
synchro
.
backward_period
;
p_vpar
->
synchro
.
backward_period
=
i_repeat_field
*
(
period
>>
1
);
if
(
p_vpar
->
synchro
.
backward_pts
)
{
if
(
p_vpar
->
sequence
.
next_dts
&&
...
...
@@ -506,10 +510,9 @@ void vpar_SynchroNewPicture( vpar_thread_t * p_vpar, int i_coding_type,
{
intf_WarnMsg
(
2
,
"vpar synchro warning: backward_pts != dts (%lld)"
,
p_vpar
->
s
ynchro
.
backward_p
ts
-
p_vpar
->
s
equence
.
next_d
ts
);
p_vpar
->
s
equence
.
next_d
ts
-
p_vpar
->
s
ynchro
.
backward_p
ts
);
}
if
(
p_vpar
->
synchro
.
backward_pts
-
p_vpar
->
synchro
.
current_pts
>
PTS_THRESHOLD
||
p_vpar
->
synchro
.
current_pts
-
p_vpar
->
synchro
.
backward_pts
...
...
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