Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
454a3688
Commit
454a3688
authored
Jan 28, 2010
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added es_out_ControlGetPcrSystem helper.
Original patch by Jean-Paul Saman.
parent
ee3b7205
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
48 additions
and
0 deletions
+48
-0
include/vlc_es_out.h
include/vlc_es_out.h
+8
-0
src/input/clock.c
src/input/clock.c
+13
-0
src/input/clock.h
src/input/clock.h
+6
-0
src/input/es_out.c
src/input/es_out.c
+14
-0
src/input/es_out_timeshift.c
src/input/es_out_timeshift.c
+7
-0
No files found.
include/vlc_es_out.h
View file @
454a3688
...
...
@@ -85,6 +85,9 @@ enum es_out_query_e
/* Set global meta data (The vlc_meta_t is not modified nor released) */
ES_OUT_SET_META
,
/* arg1=const vlc_meta_t * */
/* PCR system clock manipulation for external clock synchronization */
ES_OUT_GET_PCR_SYSTEM
,
/* arg1=mtime_t * res=can fail */
/* First value usable for private control */
ES_OUT_PRIVATE_START
=
0x10000
,
};
...
...
@@ -145,6 +148,11 @@ static inline int es_out_ControlSetMeta( es_out_t *out, const vlc_meta_t *p_meta
return
es_out_Control
(
out
,
ES_OUT_SET_META
,
p_meta
);
}
static
inline
int
es_out_ControlGetPcrSystem
(
es_out_t
*
out
,
mtime_t
*
pi_system
)
{
return
es_out_Control
(
out
,
ES_OUT_GET_PCR_SYSTEM
,
pi_system
);
}
/**
* @}
*/
...
...
src/input/clock.c
View file @
454a3688
...
...
@@ -495,6 +495,19 @@ void input_clock_ChangeSystemOrigin( input_clock_t *cl, mtime_t i_system )
vlc_mutex_unlock
(
&
cl
->
lock
);
}
mtime_t
input_clock_GetSystemOrigin
(
input_clock_t
*
cl
)
{
vlc_mutex_lock
(
&
cl
->
lock
);
assert
(
cl
->
b_has_reference
);
const
mtime_t
i_system
=
cl
->
ref
.
i_system
;
vlc_mutex_unlock
(
&
cl
->
lock
);
return
i_system
;
}
#warning "input_clock_SetJitter needs more work"
void
input_clock_SetJitter
(
input_clock_t
*
cl
,
mtime_t
i_pts_delay
,
int
i_cr_average
)
...
...
src/input/clock.h
View file @
454a3688
...
...
@@ -83,6 +83,12 @@ void input_clock_ChangeRate( input_clock_t *, int i_rate );
*/
void
input_clock_ChangePause
(
input_clock_t
*
,
bool
b_paused
,
mtime_t
i_date
);
/**
* This function returns the original system value date for the current
* reference point (a valid reference point must have been set).
*/
mtime_t
input_clock_GetSystemOrigin
(
input_clock_t
*
);
/**
* This function allows to rebase the original system value date.
* It can be called only imediatly after a input_clock_Update call.
...
...
src/input/es_out.c
View file @
454a3688
...
...
@@ -2566,6 +2566,20 @@ static int EsOutControlLocked( es_out_t *out, int i_query, va_list args )
return
VLC_SUCCESS
;
}
case
ES_OUT_GET_PCR_SYSTEM
:
{
if
(
p_sys
->
b_buffering
)
return
VLC_EGENERIC
;
es_out_pgrm_t
*
p_pgrm
=
p_sys
->
p_pgrm
;
if
(
!
p_pgrm
)
return
VLC_EGENERIC
;
mtime_t
*
pi_system
=
va_arg
(
args
,
mtime_t
*
);
*
pi_system
=
input_clock_GetSystemOrigin
(
p_pgrm
->
p_clock
);
return
VLC_SUCCESS
;
}
default:
msg_Err
(
p_sys
->
p_input
,
"unknown query in es_out_Control"
);
return
VLC_EGENERIC
;
...
...
src/input/es_out_timeshift.c
View file @
454a3688
...
...
@@ -673,7 +673,14 @@ static int ControlLocked( es_out_t *p_out, int i_query, va_list args )
{
return
ControlLockedSetFrameNext
(
p_out
);
}
case
ES_OUT_GET_PCR_SYSTEM
:
{
if
(
p_sys
->
b_delayed
)
return
VLC_EGENERIC
;
mtime_t
*
pi_system
=
(
mtime_t
*
)
va_arg
(
args
,
mtime_t
*
);
return
es_out_ControlGetPcrSystem
(
p_sys
->
p_out
,
pi_system
);
}
default:
msg_Err
(
p_sys
->
p_input
,
"Unknown es_out_Control query !"
);
assert
(
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