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
77a1a288
Commit
77a1a288
authored
Mar 17, 2005
by
Gildas Bazin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/audio_filter/converter/mpgatofixed32.c: added downmixing from stereo to mono.
parent
004f8aab
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
1 deletion
+14
-1
modules/audio_filter/converter/mpgatofixed32.c
modules/audio_filter/converter/mpgatofixed32.c
+14
-1
No files found.
modules/audio_filter/converter/mpgatofixed32.c
View file @
77a1a288
...
...
@@ -165,6 +165,12 @@ static void DoWork( aout_instance_t * p_aout, aout_filter_t * p_filter,
switch
(
p_pcm
->
channels
)
{
case
2
:
if
(
p_filter
->
output
.
i_original_channels
==
AOUT_CHAN_CENTER
)
while
(
i_samples
--
)
{
*
p_samples
++
=
(
*
p_left
++
>>
1
)
+
(
*
p_right
++
>>
1
);
}
else
while
(
i_samples
--
)
{
*
p_samples
++
=
*
p_left
++
;
...
...
@@ -191,10 +197,17 @@ static void DoWork( aout_instance_t * p_aout, aout_filter_t * p_filter,
mad_fixed_t
const
*
p_left
=
p_pcm
->
samples
[
0
];
mad_fixed_t
const
*
p_right
=
p_pcm
->
samples
[
1
];
float
f_temp
=
(
float
)
FIXED32_ONE
;
switch
(
p_pcm
->
channels
)
{
case
2
:
if
(
p_filter
->
output
.
i_original_channels
==
AOUT_CHAN_CENTER
)
while
(
i_samples
--
)
{
*
p_samples
++
=
(
float
)
*
p_left
++
/
f_temp
/
2
+
(
float
)
*
p_right
++
/
f_temp
/
2
;
}
else
while
(
i_samples
--
)
{
*
p_samples
++
=
(
float
)
*
p_left
++
/
f_temp
;
...
...
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