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
f5124bf7
Commit
f5124bf7
authored
Apr 06, 2011
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cosmetics
parent
7a86d4e4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
5 deletions
+9
-5
modules/audio_output/pulse.c
modules/audio_output/pulse.c
+9
-5
No files found.
modules/audio_output/pulse.c
View file @
f5124bf7
...
@@ -100,9 +100,11 @@ static void sink_info_cb(pa_context *c, const pa_sink_info *i, int eol,
...
@@ -100,9 +100,11 @@ static void sink_info_cb(pa_context *c, const pa_sink_info *i, int eol,
return
;
return
;
(
void
)
c
;
(
void
)
c
;
/* PulseAudio maps 100% to no SW amplification and maximum HW amplification.
/* PulseAudio flat volume NORM / 100% / 0dB corresponds to no software
* VLC maps 100% to no amplification at all. Thus we need to use the sink
* amplification and maximum hardware amplification.
* base_volume as a multiplier, if and only if flat volume is active. */
* VLC maps DEFAULT / 100% to no gain at all (software/hardware).
* Thus we need to use the sink base_volume as a multiplier,
* if and only if flat volume is active for our current sink. */
if
(
i
->
flags
&
PA_SINK_FLAT_VOLUME
)
if
(
i
->
flags
&
PA_SINK_FLAT_VOLUME
)
sys
->
base_volume
=
i
->
base_volume
;
sys
->
base_volume
=
i
->
base_volume
;
else
else
...
@@ -132,8 +134,10 @@ static void stream_moved_cb(pa_stream *s, void *userdata)
...
@@ -132,8 +134,10 @@ static void stream_moved_cb(pa_stream *s, void *userdata)
pa_operation
*
op
;
pa_operation
*
op
;
uint32_t
idx
=
pa_stream_get_device_index
(
s
);
uint32_t
idx
=
pa_stream_get_device_index
(
s
);
msg_Dbg
(
aout
,
"connected to device %s (%u)"
,
pa_stream_get_device_name
(
s
),
idx
);
msg_Dbg
(
aout
,
"connected to sink %"
PRIu32
": %s"
,
idx
,
op
=
pa_context_get_sink_info_by_index
(
sys
->
context
,
idx
,
sink_info_cb
,
aout
);
pa_stream_get_device_name
(
s
));
op
=
pa_context_get_sink_info_by_index
(
sys
->
context
,
idx
,
sink_info_cb
,
aout
);
if
(
likely
(
op
!=
NULL
))
if
(
likely
(
op
!=
NULL
))
pa_operation_unref
(
op
);
pa_operation_unref
(
op
);
}
}
...
...
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