Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
VLC
Manage
Activity
Members
Labels
Plan
Issues
4k
Issue boards
Milestones
Code
Merge requests
448
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
VideoLAN
VLC
Commits
049885a2
Commit
049885a2
authored
2 years ago
by
Thomas Guillem
Committed by
Steve Lhomme
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
aout: dec: don't require a valid time_get cb
Refs
#27023
parent
53d8690a
No related branches found
Branches containing commit
No related tags found
1 merge request
!2018
clock: fix audio/video synchronisation issues
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include/vlc_aout.h
+4
-5
4 additions, 5 deletions
include/vlc_aout.h
src/audio_output/dec.c
+2
-0
2 additions, 0 deletions
src/audio_output/dec.c
src/audio_output/output.c
+1
-1
1 addition, 1 deletion
src/audio_output/output.c
with
7 additions
and
6 deletions
include/vlc_aout.h
+
4
−
5
View file @
049885a2
...
...
@@ -181,7 +181,7 @@ struct audio_output
*/
int
(
*
time_get
)(
audio_output_t
*
,
vlc_tick_t
*
delay
);
/**< Estimates playback buffer latency (
mandatory, cannot
be NULL).
/**< Estimates playback buffer latency (
can
be NULL).
*
* This callback computes an estimation of the delay until the current
* tail of the audio output buffer would be rendered. This is essential
...
...
@@ -189,10 +189,9 @@ struct audio_output
* clock and the media upstream clock (if any).
*
* If the audio output clock is exactly synchronized with the system
* monotonic clock (i.e. vlc_tick_now()), then aout_TimeGetDefault() can
* implement this callback. In that case, drain must be implemented (since
* the default implementation uses the delay to wait for the end of the
* stream).
* monotonic clock (i.e. vlc_tick_now()), then this callback is not
* mandatory. In that case, drain must be implemented (since the default
* implementation uses the delay to wait for the end of the stream).
*
* This callback is called before the first play() in order to get the
* initial delay (the hw latency). Most modules won't be able to know this
...
...
This diff is collapsed.
Click to expand it.
src/audio_output/dec.c
+
2
−
0
View file @
049885a2
...
...
@@ -101,6 +101,8 @@ static inline struct vlc_tracer *aout_stream_tracer(vlc_aout_stream *stream)
static
int
aout_TimeGet
(
audio_output_t
*
aout
,
vlc_tick_t
*
delay
)
{
if
(
aout
->
time_get
==
NULL
)
return
-
1
;
return
aout
->
time_get
(
aout
,
delay
);
}
...
...
This diff is collapsed.
Click to expand it.
src/audio_output/output.c
+
1
−
1
View file @
049885a2
...
...
@@ -772,7 +772,7 @@ int aout_OutputNew(audio_output_t *aout, vlc_aout_stream *stream,
"failing back to linear format"
);
return
-
1
;
}
assert
(
aout
->
flush
&&
aout
->
play
&&
aout
->
time_get
&&
aout
->
pause
);
assert
(
aout
->
flush
&&
aout
->
play
&&
aout
->
pause
);
/* Autoselect the headphones mode if available and if the user didn't
* request any mode */
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment