Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
f74db532
Commit
f74db532
authored
Dec 16, 2012
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
aout: use aout_RequestRestart() where applicable
parent
ad6442ae
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
16 additions
and
27 deletions
+16
-27
include/vlc_aout.h
include/vlc_aout.h
+10
-1
modules/audio_output/alsa.c
modules/audio_output/alsa.c
+2
-3
modules/audio_output/mmdevice.c
modules/audio_output/mmdevice.c
+2
-8
modules/audio_output/oss.c
modules/audio_output/oss.c
+1
-2
modules/audio_output/pulse.c
modules/audio_output/pulse.c
+1
-2
src/audio_output/dec.c
src/audio_output/dec.c
+0
-10
src/libvlccore.sym
src/libvlccore.sym
+0
-1
No files found.
include/vlc_aout.h
View file @
f74db532
...
...
@@ -334,7 +334,16 @@ static inline void aout_RestartRequest(audio_output_t *aout, unsigned mode)
aout
->
event
.
restart_request
(
aout
,
mode
);
}
VLC_API
int
aout_ChannelsRestart
(
vlc_object_t
*
,
const
char
*
,
vlc_value_t
,
vlc_value_t
,
void
*
);
static
inline
int
aout_ChannelsRestart
(
vlc_object_t
*
obj
,
const
char
*
varname
,
vlc_value_t
oldval
,
vlc_value_t
newval
,
void
*
data
)
{
audio_output_t
*
aout
=
(
audio_output_t
*
)
obj
;
(
void
)
varname
;
(
void
)
oldval
;
(
void
)
newval
;
(
void
)
data
;
aout_RestartRequest
(
aout
,
AOUT_RESTART_OUTPUT
);
return
0
;
}
/* */
VLC_API
vout_thread_t
*
aout_filter_RequestVout
(
filter_t
*
,
vout_thread_t
*
p_vout
,
video_format_t
*
p_fmt
)
VLC_USED
;
...
...
modules/audio_output/alsa.c
View file @
f74db532
...
...
@@ -792,9 +792,8 @@ static int DeviceSelect (audio_output_t *aout, const char *id)
var_Create
(
aout
,
"alsa-audio-device"
,
VLC_VAR_STRING
);
var_SetString
(
aout
,
"alsa-audio-device"
,
id
);
vlc_value_t
dummy
;
return
aout_ChannelsRestart
(
VLC_OBJECT
(
aout
),
"audio-device"
,
dummy
,
dummy
,
NULL
);
aout_RestartRequest
(
aout
,
AOUT_RESTART_OUTPUT
);
return
0
;
}
static
int
Open
(
vlc_object_t
*
obj
)
...
...
modules/audio_output/mmdevice.c
View file @
f74db532
...
...
@@ -104,10 +104,7 @@ static int vlc_FromHR(audio_output_t *aout, HRESULT hr)
{
/* Restart on unplug */
if
(
unlikely
(
hr
==
AUDCLNT_E_DEVICE_INVALIDATED
))
{
vlc_value_t
d
;
aout_ChannelsRestart
(
VLC_OBJECT
(
aout
),
"audio-device"
,
d
,
d
,
NULL
);
}
aout_RestartRequest
(
aout
,
AOUT_RESTART_OUTPUT
);
return
SUCCEEDED
(
hr
)
?
0
:
-
1
;
}
...
...
@@ -652,11 +649,8 @@ static int DeviceSelect(audio_output_t *aout, const char *id)
LeaveMTA
();
if
(
sys
->
stream
!=
NULL
)
{
vlc_value_t
d
;
/* Request restart of stream with the new device */
aout_ChannelsRestart
(
VLC_OBJECT
(
aout
),
"audio-device"
,
d
,
d
,
NULL
);
}
aout_RestartRequest
(
aout
,
AOUT_RESTART_OUTPUT
);
return
FAILED
(
hr
)
?
-
1
:
0
;
}
...
...
modules/audio_output/oss.c
View file @
f74db532
...
...
@@ -86,11 +86,10 @@ static int MuteSet (audio_output_t *, bool);
static
int
DeviceChanged
(
vlc_object_t
*
obj
,
const
char
*
varname
,
vlc_value_t
prev
,
vlc_value_t
cur
,
void
*
data
)
{
aout_ChannelsRestart
(
obj
,
varname
,
prev
,
cur
,
data
);
if
(
!
var_Type
(
obj
,
"oss-audio-device"
))
var_Create
(
obj
,
"oss-audio-device"
,
VLC_VAR_STRING
);
var_SetString
(
obj
,
"oss-audio-device"
,
cur
.
psz_string
);
aout_RestartRequest
((
audio_output_t
*
)
aout
,
AOUT_RESTART_OUTPUT
);
return
VLC_SUCCESS
;
}
...
...
modules/audio_output/pulse.c
View file @
f74db532
...
...
@@ -315,8 +315,7 @@ static void stream_event_cb(pa_stream *s, const char *name, pa_proplist *pl,
vlc_value_t
dummy
=
{
.
i_int
=
0
};
msg_Dbg
(
aout
,
"format lost"
);
aout_ChannelsRestart
(
VLC_OBJECT
(
aout
),
"audio-device"
,
dummy
,
dummy
,
NULL
);
aout_RestartRequest
(
aout
,
AOUT_RESTART_OUTPUT
);
}
else
#endif
msg_Warn
(
aout
,
"unhandled stream event
\"
%s
\"
"
,
name
);
...
...
src/audio_output/dec.c
View file @
f74db532
...
...
@@ -169,16 +169,6 @@ void aout_RequestRestart (audio_output_t *aout, unsigned mode)
atomic_fetch_or
(
&
owner
->
restart
,
mode
);
}
int
aout_ChannelsRestart
(
vlc_object_t
*
obj
,
const
char
*
varname
,
vlc_value_t
oldval
,
vlc_value_t
newval
,
void
*
data
)
{
audio_output_t
*
aout
=
(
audio_output_t
*
)
obj
;
(
void
)
oldval
;
(
void
)
newval
;
(
void
)
data
;
aout_RequestRestart
(
aout
,
AOUT_RESTART_OUTPUT
);
return
0
;
}
/*
* Buffer management
*/
...
...
src/libvlccore.sym
View file @
f74db532
...
...
@@ -3,7 +3,6 @@ AddMD5
aout_BitsPerSample
aout_ChannelExtract
aout_ChannelReorder
aout_ChannelsRestart
aout_CheckChannelExtraction
aout_CheckChannelReorder
aout_filter_RequestVout
...
...
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