Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
f532964f
Commit
f532964f
authored
Jan 04, 2015
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
output/pulse: add wrapper for pa_threaded_mainloop_signal()
parent
efea609d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
7 deletions
+11
-7
PulseOutputPlugin.cxx
src/output/plugins/PulseOutputPlugin.cxx
+11
-7
No files found.
src/output/plugins/PulseOutputPlugin.cxx
View file @
f532964f
...
...
@@ -92,7 +92,7 @@ public:
void
OnStreamWrite
(
size_t
nbytes
);
void
OnStreamSuccess
()
{
pa_threaded_mainloop_signal
(
mainloop
,
0
);
Signal
(
);
}
gcc_const
...
...
@@ -136,6 +136,10 @@ private:
*/
void
DeleteContext
();
void
Signal
()
{
pa_threaded_mainloop_signal
(
mainloop
,
0
);
}
/**
* Check if the context is (already) connected, and waits if
* not. If the context has been disconnected, retry to
...
...
@@ -299,7 +303,7 @@ PulseOutput::OnContextStateChanged(pa_context_state_t new_state)
if
(
mixer
!=
nullptr
)
pulse_mixer_on_connect
(
*
mixer
,
context
);
pa_threaded_mainloop_signal
(
mainloop
,
0
);
Signal
(
);
break
;
case
PA_CONTEXT_TERMINATED
:
...
...
@@ -309,7 +313,7 @@ PulseOutput::OnContextStateChanged(pa_context_state_t new_state)
/* the caller thread might be waiting for these
states */
pa_threaded_mainloop_signal
(
mainloop
,
0
);
Signal
(
);
break
;
case
PA_CONTEXT_UNCONNECTED
:
...
...
@@ -549,7 +553,7 @@ PulseOutput::OnStreamSuspended(gcc_unused pa_stream *_stream)
/* wake up the main loop to break out of the loop in
pulse_output_play() */
pa_threaded_mainloop_signal
(
mainloop
,
0
);
Signal
(
);
}
static
void
...
...
@@ -573,7 +577,7 @@ PulseOutput::OnStreamStateChanged(pa_stream *_stream,
if
(
mixer
!=
nullptr
)
pulse_mixer_on_change
(
*
mixer
,
context
,
_stream
);
pa_threaded_mainloop_signal
(
mainloop
,
0
);
Signal
(
);
break
;
case
PA_STREAM_FAILED
:
...
...
@@ -581,7 +585,7 @@ PulseOutput::OnStreamStateChanged(pa_stream *_stream,
if
(
mixer
!=
nullptr
)
pulse_mixer_on_disconnect
(
*
mixer
);
pa_threaded_mainloop_signal
(
mainloop
,
0
);
Signal
(
);
break
;
case
PA_STREAM_UNCONNECTED
:
...
...
@@ -604,7 +608,7 @@ PulseOutput::OnStreamWrite(size_t nbytes)
assert
(
mainloop
!=
nullptr
);
writable
=
nbytes
;
pa_threaded_mainloop_signal
(
mainloop
,
0
);
Signal
(
);
}
static
void
...
...
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