Commit e4e8a895 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

ALSA: use software amplification

parent db635d17
......@@ -28,9 +28,9 @@ if HAVE_OSS
libvlc_LTLIBRARIES += liboss_plugin.la
endif
libalsa_plugin_la_SOURCES = alsa.c
libalsa_plugin_la_SOURCES = alsa.c volume.h
libalsa_plugin_la_CFLAGS = $(AM_CFLAGS) $(ALSA_CFLAGS)
libalsa_plugin_la_LIBADD = $(AM_LIBADD) $(ALSA_LIBS)
libalsa_plugin_la_LIBADD = $(AM_LIBADD) $(ALSA_LIBS) $(LIBM)
libalsa_plugin_la_DEPENDENCIES =
if HAVE_ALSA
libvlc_LTLIBRARIES += libalsa_plugin.la
......
......@@ -44,8 +44,12 @@ struct aout_sys_t
{
snd_pcm_t *pcm;
void (*reorder) (void *, size_t, unsigned);
float soft_gain;
bool soft_mute;
};
#include "volume.h"
#define A52_FRAME_NB 1536
static int Open (vlc_object_t *);
......@@ -88,6 +92,7 @@ vlc_module_begin ()
add_integer ("alsa-audio-channels", AOUT_CHANS_FRONT,
AUDIO_CHAN_TEXT, AUDIO_CHAN_LONGTEXT, false)
change_integer_list (channels, channels_text)
add_sw_gain ()
set_capability( "audio output", 150 )
set_callbacks( Open, Close )
vlc_module_end ()
......@@ -528,7 +533,7 @@ static int Open (vlc_object_t *obj)
sys->reorder = NULL;
}
aout_VolumeSoftInit (aout);
aout_SoftVolumeInit (aout);
}
aout->pf_play = Play;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment