mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-12-26 08:56:42 -05:00
lfe-filter: change the crossover frequency as a parameter
Add a user defined parameter lfe-crossover-freq for the lfe-filter, to pass this parameter to the lfe-filter, we need to change the pa_resampler_new() API as well. Signed-off-by: Hui Wang <hui.wang@canonical.com>
This commit is contained in:
parent
3538e6636e
commit
c36e191ce5
14 changed files with 28 additions and 8 deletions
|
|
@ -83,6 +83,7 @@ static const pa_daemon_conf default_conf = {
|
|||
.resample_method = PA_RESAMPLER_AUTO,
|
||||
.disable_remixing = false,
|
||||
.disable_lfe_remixing = true,
|
||||
.lfe_crossover_freq = 120,
|
||||
.config_file = NULL,
|
||||
.use_pid_file = true,
|
||||
.system_instance = false,
|
||||
|
|
@ -553,6 +554,7 @@ int pa_daemon_conf_load(pa_daemon_conf *c, const char *filename) {
|
|||
{ "enable-remixing", pa_config_parse_not_bool, &c->disable_remixing, NULL },
|
||||
{ "disable-lfe-remixing", pa_config_parse_bool, &c->disable_lfe_remixing, NULL },
|
||||
{ "enable-lfe-remixing", pa_config_parse_not_bool, &c->disable_lfe_remixing, NULL },
|
||||
{ "lfe-crossover-freq", pa_config_parse_unsigned, &c->lfe_crossover_freq, NULL },
|
||||
{ "load-default-script-file", pa_config_parse_bool, &c->load_default_script_file, NULL },
|
||||
{ "shm-size-bytes", pa_config_parse_size, &c->shm_size, NULL },
|
||||
{ "log-meta", pa_config_parse_bool, &c->log_meta, NULL },
|
||||
|
|
@ -745,6 +747,7 @@ char *pa_daemon_conf_dump(pa_daemon_conf *c) {
|
|||
pa_strbuf_printf(s, "resample-method = %s\n", pa_resample_method_to_string(c->resample_method));
|
||||
pa_strbuf_printf(s, "enable-remixing = %s\n", pa_yes_no(!c->disable_remixing));
|
||||
pa_strbuf_printf(s, "enable-lfe-remixing = %s\n", pa_yes_no(!c->disable_lfe_remixing));
|
||||
pa_strbuf_printf(s, "lfe-crossover-freq = %u\n", c->lfe_crossover_freq);
|
||||
pa_strbuf_printf(s, "default-sample-format = %s\n", pa_sample_format_to_string(c->default_sample_spec.format));
|
||||
pa_strbuf_printf(s, "default-sample-rate = %u\n", c->default_sample_spec.rate);
|
||||
pa_strbuf_printf(s, "alternate-sample-rate = %u\n", c->alternate_sample_rate);
|
||||
|
|
|
|||
|
|
@ -127,6 +127,7 @@ typedef struct pa_daemon_conf {
|
|||
unsigned default_n_fragments, default_fragment_size_msec;
|
||||
unsigned deferred_volume_safety_margin_usec;
|
||||
int deferred_volume_extra_delay_usec;
|
||||
unsigned lfe_crossover_freq;
|
||||
pa_sample_spec default_sample_spec;
|
||||
uint32_t alternate_sample_rate;
|
||||
pa_channel_map default_channel_map;
|
||||
|
|
|
|||
|
|
@ -55,6 +55,7 @@ ifelse(@HAVE_DBUS@, 1, [dnl
|
|||
; resample-method = speex-float-1
|
||||
; enable-remixing = yes
|
||||
; enable-lfe-remixing = no
|
||||
; lfe-crossover-freq = 120
|
||||
|
||||
; flat-volumes = yes
|
||||
|
||||
|
|
|
|||
|
|
@ -1029,6 +1029,7 @@ int main(int argc, char *argv[]) {
|
|||
c->default_fragment_size_msec = conf->default_fragment_size_msec;
|
||||
c->deferred_volume_safety_margin_usec = conf->deferred_volume_safety_margin_usec;
|
||||
c->deferred_volume_extra_delay_usec = conf->deferred_volume_extra_delay_usec;
|
||||
c->lfe_crossover_freq = conf->lfe_crossover_freq;
|
||||
c->exit_idle_time = conf->exit_idle_time;
|
||||
c->scache_idle_time = conf->scache_idle_time;
|
||||
c->resample_method = conf->resample_method;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue