[Решено]pulseaudio-equalizer-ladspa и громкость

redix
Пробовал значения 2000, 3000, 4500, 5300 — громкость практически на нуле,
Это мало взял ... пробуй сначала хотя бы 30000
Ошибки не исчезают с опытом - они просто умнеют
Уже! ) Одновременно написали. )))
In Tux We Trust
А теперь ход конём!
1 - меняем настройки эквалайзера (к примеру, выбираем там другой пресет), сохраняем
2 - открываем default.pa и видим..... 65536 вместо тех цифр, что мы устанавливали
))))

P.S> можно вообще ничего не менять! достаточно просто нажать Apply Settings и цифры возвращаются к исходному значению

P.P.S> Видео
Gnome 2 >> Unity >> KDE 4 >> Openbox >> Awesome >> Xmonad
GitHub , BitBuket
Ну хоть так, буду знать. Там еще файлик нарыл /usr/bin/pulseaudio-equalizer.orig вот с таким содержимым:
#!/bin/bash

# PulseAudio LADSPA Equalizer - support script
# Author: Conn O'Griofa <connogriofa AT gmail DOT com>
#
# Intended for use in conjunction with PulseAudio Equalizer (pulseaudio-equalizer.py/pulseaudio-equalizer-gtk) PyGTK script.
#

# Default LADSPA plugin & control settings; settings will be overridden if $CONFIG_NAME file exists.
PA_LADSPA_PLUGIN="mbeq_1197"
PA_LADSPA_PLUGIN_NAME="Multiband EQ"
PA_LADSPA_LABEL="mbeq"
PA_NUM_LADSPA_INPUTS="15"
PA_LADSPA_CONTROLS="0,0,0,0,0,0,0,0,0,0,0,0,0,0,0"
PA_LADSPA_INPUTS="50,100,156,220,311,440,622,880,1250,1750,2500,3500,5000,10000,20000"
PA_CONTROL_MIN="-30"
PA_CONTROL_MAX="30"
PA_PREAMP="1.0"
PA_CURRENT_PRESET=""

PRESET_DIR1=$HOME/.pulse/presets
PRESET_DIR2=/usr/share/pulseaudio-equalizer/presets
SCRIPT_NAME=pulseaudio-equalizer
SCRIPT_VERSION="2.7 (05/02/2010)"
CONFIG_NAME=$HOME/.pulse/equalizerrc
LOG_NAME=$HOME/Desktop/pulseaudio-equalizer.log

# Don't execute the script with elevated privileges
if [[ ! $EUID -ne 0 ]]; then
   echo "This script must not be run as root!" 1>&2
   exit 1
fi

# PyGTK Interface - Reset Settings
if [ "$1" = "interface.resetsettings" ]; then
  # Convert commas into newlines and dump all settings to configuration file
  echo $PA_LADSPA_PLUGIN,$PA_LADSPA_LABEL,$PA_LADSPA_PLUGIN_NAME,$PA_PREAMP,$PA_CURRENT_PRESET,$PA_EQUALIZER_STATUS,$PA_EQUALIZER_PERSISTENCE,$PA_CONTROL_MIN,$PA_CONTROL_MAX,$PA_NUM_LADSPA_INPUTS,$PA_LADSPA_CONTROLS,$PA_LADSPA_INPUTS | sed 's/,/\n/g' >$CONFIG_NAME

  $SCRIPT_NAME disable-config
  $SCRIPT_NAME disable
  exit
fi

# If $CONFIG_NAME file exists, override built-in control settings with user-customized values
if [ -f $CONFIG_NAME ]; then
  # Read configuration file into "MYARRAY" array
  index=0
  while read line ; do
    MYARRAY[$index]="$line"
    index=$(($index+1))
  done < $CONFIG_NAME

  # Grab simple values
  PA_LADSPA_PLUGIN="${MYARRAY[0]}"
  PA_LADSPA_LABEL=${MYARRAY[1]}
  PA_LADSPA_PLUGIN_NAME=${MYARRAY[2]}
  PA_PREAMP=${MYARRAY[3]}
  PA_CURRENT_PRESET=${MYARRAY[4]}
  PA_EQUALIZER_STATUS=${MYARRAY[5]}
  PA_EQUALIZER_PERSISTENCE=${MYARRAY[6]}
  PA_CONTROL_MIN=${MYARRAY[7]}
  PA_CONTROL_MAX=${MYARRAY[8]}
  PA_NUM_LADSPA_INPUTS=${MYARRAY[9]}

  # Unpack controls from array
  index=0
  current=10
  while [ $index -lt $PA_NUM_LADSPA_INPUTS ]; do
    RAWDATA1="$RAWDATA1 ${MYARRAY[$current]}"
    index=$(($index+1))
    current=$(($current+1))
  done
  # Convert spaces into commas
  PA_LADSPA_CONTROLS=$(echo $RAWDATA1 | sed 's/ /,/g')

  # Unpack inputs from array
  index=0
  current=$((10+$PA_NUM_LADSPA_INPUTS))
  while [ $index -lt $PA_NUM_LADSPA_INPUTS ]; do
    RAWDATA2="$RAWDATA2 ${MYARRAY[$current]}"
    index=$(($index+1))
    current=$(($current+1))
  done
  # Convert spaces into commas
  PA_LADSPA_INPUTS=$(echo $RAWDATA2 | sed 's/ /,/g')
fi

# PyGTK Interface - Apply Settings
if [ "$1" = "interface.applysettings" ]; then
  # Process new settings
  if [ "$PA_EQUALIZER_PERSISTENCE" = "1" ]; then
    echo "Enabling persistence..."
    $SCRIPT_NAME enable-config
  elif [ "$PA_EQUALIZER_PERSISTENCE" = "0" ]; then
    echo "Disabling persistence..."
    $SCRIPT_NAME disable-config
  fi

  if [ "$PA_EQUALIZER_STATUS" = "1" ]; then
    echo "Enabling..."
    $SCRIPT_NAME enable
  elif [ "$PA_EQUALIZER_STATUS" = "0" ]; then
    echo "Disabling..."
    $SCRIPT_NAME disable
  fi
  exit
fi

# Get sink names and volumes
PA_LADSPA_SINK="ladspa_output.$PA_LADSPA_PLUGIN.$PA_LADSPA_LABEL"
PA_CURRENT_SINK=$(pacmd stat | grep "Default sink name" | sed 's/Default sink name: //g')
PA_CURRENT_VOLUME=$(pacmd list | grep -A20 "<$PA_CURRENT_SINK>" | grep -m1 'volume: 0:' | awk '{print $NF}' | sed 's/%//g')
PA_REAL_VOLUME=$((PA_CURRENT_VOLUME*65536/100))
PA_REAL_PREAMP_FLOAT=$(echo "$PA_PREAMP*65536" | bc)
PA_REAL_PREAMP=${PA_REAL_PREAMP_FLOAT/\.*}
PA_CURRENT_MUTE=$(pacmd list-sinks | grep -A20 "<$PA_CURRENT_SINK>" | grep -m1 'muted: ' | sed 's/[\t]muted: no/0/g' | sed 's/[\t]muted: yes/1/g')

# Check if equalizer is running and get accurate master sink name
if [ "$PA_CURRENT_SINK" = "$PA_LADSPA_SINK" ]; then
  PA_EQUALIZER_STATUS=1
  PA_MASTER_SINK=$(pacmd info | grep -A30 "<$PA_CURRENT_SINK>" | grep -m1 'device.master_device = ' | sed 's/device.master_device = //g' | sed 's/"//g' | sed 's/^[ \t]*//')
else
  PA_EQUALIZER_STATUS=0
  PA_MASTER_SINK=$(pacmd stat | grep 'Default sink name' | sed 's/Default sink name: //g')
fi

# Check if equalizer is set as persistent
if [ -f $HOME/.pulse/default.pa ]; then
    if [ "$(cat $HOME/.pulse/default.pa | grep -m1 "### BEGIN: Equalized audio configuration")" = "### BEGIN: Equalized audio configuration" ]; then
    PA_EQUALIZER_PERSISTENCE=1
    else
    PA_EQUALIZER_PERSISTENCE=0
    fi
else
  PA_EQUALIZER_PERSISTENCE=0
fi

# DEBUG
if [ "$1" = "debug" ]; then
  echo "Please wait (approximate time: 25 seconds)..."
  sleep 3
  echo >$LOG_NAME "State: Initial state"
  echo >>$LOG_NAME "---"
  $SCRIPT_NAME log >>$LOG_NAME

  $SCRIPT_NAME disable-config >/dev/null
  pulseaudio -k
  sleep 10

  # Disabled/not saved
  $SCRIPT_NAME disable >/dev/null
  $SCRIPT_NAME disable-config >/dev/null
  sleep 3
  echo >>$LOG_NAME "State: Disabled [not saved]"
  echo >>$LOG_NAME "---"
  $SCRIPT_NAME log >>$LOG_NAME

  # Enabled/not saved
  $SCRIPT_NAME enable >/dev/null
  $SCRIPT_NAME disable-config >/dev/null
  sleep 3
  echo >>$LOG_NAME "State: Enabled [not saved]"
  echo >>$LOG_NAME "---"
  $SCRIPT_NAME log >>$LOG_NAME

  # Disabled/saved
  $SCRIPT_NAME disable >/dev/null
  $SCRIPT_NAME enable-config >/dev/null
  sleep 3
  echo >>$LOG_NAME "State: Disabled [saved]"
  echo >>$LOG_NAME "---"
  $SCRIPT_NAME log >>$LOG_NAME

  # Enabled/saved
  $SCRIPT_NAME enable >/dev/null
  $SCRIPT_NAME enable-config >/dev/null
  sleep 3
  echo >>$LOG_NAME "State: Enabled [saved]"
  echo >>$LOG_NAME "---"
  $SCRIPT_NAME log >>$LOG_NAME

  echo "Finished! Log created at $LOG_NAME."
  exit
fi

if [ "$1" = "log" ]; then
  echo SCRIPT_VERSION=$SCRIPT_VERSION
  echo PA_LADSPA_PLUGIN=$PA_LADSPA_PLUGIN
  echo PA_LADSPA_LABEL=$PA_LADSPA_LABEL
  echo PA_LADSPA_PLUGIN_NAME=$PA_LADSPA_PLUGIN_NAME
  echo PA_CURRENT_PRESET=$PA_CURRENT_PRESET
  echo PA_EQUALIZER_STATUS=$PA_EQUALIZER_STATUS
  echo PA_EQUALIZER_PERSISTENCE=$PA_EQUALIZER_PERSISTENCE
  echo PA_NUM_LADSPA_INPUTS=$PA_NUM_LADSPA_INPUTS
  echo PA_LADSPA_CONTROLS=$PA_LADSPA_CONTROLS
  echo PA_LADSPA_INPUTS=$PA_LADSPA_INPUTS
  echo PA_CONTROL_MIN=$PA_CONTROL_MIN
  echo PA_CONTROL_MAX=$PA_CONTROL_MAX

  echo PA_MASTER_SINK=$PA_MASTER_SINK
  echo PA_LADSPA_SINK=$PA_LADSPA_SINK
  echo PA_CURRENT_SINK=$PA_CURRENT_SINK
  echo PA_CURRENT_MUTE=$PA_CURRENT_MUTE
  echo PA_CURRENT_VOLUME=$PA_CURRENT_VOLUME
  echo PA_REAL_VOLUME=$PA_REAL_VOLUME
  echo PA_PREAMP=$PA_PREAMP
  echo PA_REAL_PREAMP=$PA_REAL_PREAMP

  if [ -f $HOME/.pulse/default.pa ]; then
    tail -n7 $HOME/.pulse/default.pa
  fi

  echo "---"
  echo ""
  exit
fi

# PyGTK Interface - Get Settings
if [ "$1" = "interface.getsettings" ]; then
  # Convert commas into newlines and dump all settings to configuration file
  echo $PA_LADSPA_PLUGIN,$PA_LADSPA_LABEL,$PA_LADSPA_PLUGIN_NAME,$PA_PREAMP,$PA_CURRENT_PRESET,$PA_EQUALIZER_STATUS,$PA_EQUALIZER_PERSISTENCE,$PA_CONTROL_MIN,$PA_CONTROL_MAX,$PA_NUM_LADSPA_INPUTS,$PA_LADSPA_CONTROLS,$PA_LADSPA_INPUTS | sed 's/,/\n/g' >$CONFIG_NAME

  # Ensure that user preset directory exists
  if [ ! -d $PRESET_DIR1 ]; then
    mkdir $PRESET_DIR1
  fi

  # Generate list of available presets (system)
  ls -x1 $PRESET_DIR2/*.preset | sed "s|$PRESET_DIR2/||g" | sed 's/.preset//g' >$CONFIG_NAME.availablepresets.unsorted

  # Generate list of available presets (user)
  ls -x1 $PRESET_DIR1/*.preset | sed "s|$PRESET_DIR1/||g" | sed 's/.preset//g' >>$CONFIG_NAME.availablepresets.unsorted

  # Sort list
  sort $CONFIG_NAME.availablepresets.unsorted >$CONFIG_NAME.availablepresets
  rm $CONFIG_NAME.availablepresets.unsorted
  exit
fi

# Toggle equalizer on/off
if [ "$1" = "toggle" -a "$PA_EQUALIZER_STATUS" = "1" ]; then
  $SCRIPT_NAME disable
  exit
else if [ "$1" = "toggle" -a "$PA_EQUALIZER_STATUS" = "0" ]; then
  $SCRIPT_NAME enable
  exit
  fi
fi

if [ "$1" = "enable-config" ]; then
  # Enable the equalizer (if necessary)
  #$SCRIPT_NAME enable

  echo "Current operation: saving configuration (enable-config)"
  echo "-------------------------------------"

  # If equalizer configuration is already set, delete file
  if [ -f $HOME/.pulse/default.pa ]; then
    if [ "$(cat $HOME/.pulse/default.pa | grep -m1 "### BEGIN: Equalized audio configuration")" = "### BEGIN: Equalized audio configuration" ]; then
      echo "Equalizer definition detected in file '$HOME/.pulse/default.pa', deleting..."
      rm $HOME/.pulse/default.pa
    fi
  fi

  # Make a backup of configuration if necessary
  if [ -f $HOME/.pulse/default.pa ]; then
    echo "Found '$HOME/.pulse/default.pa', making a copy..."
    cp $HOME/.pulse/default.pa $HOME/.pulse/default.pa.noeq
    CFG_SOURCE_FILE="$HOME/.pulse/default.pa.noeq"
  fi

  # Decide which file to use as the configuration source
  if [ -f $HOME/.pulse/default.pa.noeq ]; then
    echo "Found '$HOME/.pulse/default.pa.noeq'..."
    CFG_SOURCE_FILE="$HOME/.pulse/default.pa.noeq"
  else
    CFG_SOURCE_FILE="/etc/pulse/default.pa"
  fi

  echo "Using configuration file '$CFG_SOURCE_FILE' as source..."

  # Modify module-stream-restore line to disable cached sinks
  cat $CFG_SOURCE_FILE | sed 's/load-module module-stream-restore/load-module module-stream-restore restore_device=false/g' >$HOME/.pulse/default.pa

  # Add module-ladspa-sink definition
  echo "" >>$HOME/.pulse/default.pa
  echo "### BEGIN: Equalized audio configuration" >>$HOME/.pulse/default.pa
  echo "### Generated from: $SCRIPT_NAME" >>$HOME/.pulse/default.pa
  echo "load-module module-ladspa-sink sink_name=$PA_LADSPA_SINK master=$PA_MASTER_SINK plugin=$PA_LADSPA_PLUGIN label=$PA_LADSPA_LABEL control=$PA_LADSPA_CONTROLS" >>$HOME/.pulse/default.pa

  # Set LADSPA sink as default sink & set appropriate master sink (preamp) volume
  echo "set-default-sink $PA_LADSPA_SINK" >>$HOME/.pulse/default.pa
  echo "set-sink-volume $PA_MASTER_SINK $PA_REAL_PREAMP" >>$HOME/.pulse/default.pa
  echo "set-sink-mute $PA_MASTER_SINK 0" >>$HOME/.pulse/default.pa
  echo "### END: Equalized audio configuration" >>$HOME/.pulse/default.pa

  echo "Equalizer setting saved (enable-config)."
  echo "-------------------------------------"
  #$SCRIPT_NAME status
  exit
fi

if [ "$1" = "disable-config" ]; then
  # Disable the equalizer (if necessary)
  #$SCRIPT_NAME disable

  echo "Current operation: saving configuration (disable-config)"
  echo "-------------------------------------"

  # Move .noeq configuration file if it exists
  if [ -f $HOME/.pulse/default.pa.noeq ]; then
    echo "Found '$HOME/.pulse/default.pa.noeq', moving..."
    mv $HOME/.pulse/default.pa.noeq $HOME/.pulse/default.pa
  fi

  # If equalizer configuration is present, delete file
  if [ -f $HOME/.pulse/default.pa ]; then
    if [ "$(cat $HOME/.pulse/default.pa | grep -m1 "### BEGIN: Equalized audio configuration")" = "### BEGIN: Equalized audio configuration" ]; then
     echo "Equalizer definition detected, deleting '$HOME/.pulse/default.pa'..."
     rm $HOME/.pulse/default.pa
   fi
  fi

  echo "Equalizer setting saved (disable-config)."
  echo "-------------------------------------"
  #$SCRIPT_NAME status
  exit
fi

echo "PulseAudio Equalizer/LADSPA Processor $SCRIPT_VERSION"

if [ "$1" = "disable" -o "$1" = "enable" ]; then
  echo "-------------------------------------"
  echo "Current operation: disabling equalizer"
  echo "-------------------------------------"
  echo -n >/tmp/eqcommands.sh

  # Unload & reload stream-restore module
  echo "Unloading & reloading stream-restore module..."
  echo >>/tmp/eqcommands.sh "unload-module $(pacmd list | grep -B1 -m1 'name: <module-stream-restore>' | grep '    index: ' | sed 's/    index: //g')"
  echo >>/tmp/eqcommands.sh "load-module module-stream-restore"

  # Unload LADSPA sink module (if it is already loaded)
  echo "Unloading module-ladspa-sink..."
  echo >>/tmp/eqcommands.sh "unload-module $(pacmd list | grep -B1 -m1 'name: <module-ladspa-sink>' | grep '    index: ' | sed 's/    index: //g')"

  # Move active client sinks to ALSA sink
  echo "Moving active PulseAudio clients to ALSA sink ($PA_MASTER_SINK)..."
  echo >>/tmp/eqcommands.sh "$(pacmd "list-sink-inputs" | grep 'index: ' | sed 's/    index: /move-sink-input /g' | sed "s/$/ $PA_MASTER_SINK/g")"

  # Transfer current mute/sink volume to ALSA sink
  echo "Transferring current mute ($PA_CURRENT_MUTE) & volume ($PA_CURRENT_VOLUME%) to ALSA sink ($PA_MASTER_SINK)..."
  echo >>/tmp/eqcommands.sh "set-default-sink $PA_MASTER_SINK"
  echo >>/tmp/eqcommands.sh "set-sink-volume $PA_MASTER_SINK $PA_REAL_VOLUME"
  echo >>/tmp/eqcommands.sh "set-sink-mute $PA_MASTER_SINK $PA_CURRENT_MUTE"

  # Execute all queued commands (for potential speed benefit)...
  pacmd </tmp/eqcommands.sh >/dev/null
fi

if [ "$1" = "enable" ]; then
  echo "-------------------------------------"
  echo "Current operation: enabling equalizer"
  echo "-------------------------------------"
  echo -n >/tmp/eqcommands.sh

  # Unload & reload stream-restore module with restore_device option disabled (to ensure that previously cached per-client sinks are not used)
  echo "Unloading & reloading stream-restore module..."
  echo >>/tmp/eqcommands.sh "unload-module $(pacmd list | grep -B1 -m1 'name: <module-stream-restore>' | grep '    index: ' | sed 's/    index: //g')"
  echo >>/tmp/eqcommands.sh "load-module module-stream-restore restore_device=false"

  # Load LADSPA sink module
  echo "Loading module-ladspa-sink..."
  echo >>/tmp/eqcommands.sh "load-module module-ladspa-sink sink_name=$PA_LADSPA_SINK master=$PA_MASTER_SINK plugin=$PA_LADSPA_PLUGIN label=$PA_LADSPA_LABEL control=$PA_LADSPA_CONTROLS"

  # Transfer current sink mute/volume to LADSPA sink
  echo "Transferring current mute ($PA_CURRENT_MUTE) & volume ($PA_CURRENT_VOLUME%) to LADSPA sink ($PA_LADSPA_SINK)..."
  echo >>/tmp/eqcommands.sh "set-sink-volume $PA_LADSPA_SINK $PA_REAL_VOLUME"
  echo >>/tmp/eqcommands.sh "set-sink-mute $PA_LADSPA_SINK $PA_CURRENT_MUTE"

  # Unmute & set preamp level on ALSA sink (as LADSPA sink will act as primary volume control)
  echo "Setting ALSA sink ($PA_MASTER_SINK) preamp ("$PA_PREAMP"x)..."
  #echo >>/tmp/eqcommands.sh "set-sink-volume $PA_MASTER_SINK $PA_REAL_PREAMP"
  echo >>/tmp/eqcommands.sh "set-sink-mute $PA_MASTER_SINK 0"

  # Set the LADSPA sink as the default
  echo "Setting LADSPA sink ($PA_LADSPA_SINK) as default sink..."
  echo >>/tmp/eqcommands.sh "set-default-sink $PA_LADSPA_SINK"

  # Move currently active client sinks to LADSPA sink
  echo "Moving active PulseAudio clients to LADSPA sink ($PA_LADSPA_SINK)..."
  echo >>/tmp/eqcommands.sh "$(pacmd "list-sink-inputs" | grep 'index: ' | sed 's/    index: /move-sink-input /g' | sed "s/$/ $PA_LADSPA_SINK/g")"

  # Execute all queued commands (for potential speed benefit)...
  pacmd </tmp/eqcommands.sh >/dev/null
fi

if [ "$1" = "" -o "$1" = "-h" -o "$1" = "--help" ]; then
  echo -e "Usage: $SCRIPT_NAME [option]"
  echo -e "WARNING: This is for internal use by the pulseaudio-equalizer-gtk interface."
  echo -e "         Use for debugging/troubleshooting purposes only."
  echo -e ""
  echo -e "Options (current session):"
  echo -e "  enable\t\t enable the equalizer"
  echo -e "  disable\t\t disable the equalizer"
  echo -e "  toggle\t\t enable/disable the equalizer"
  echo -e ""
  echo -e "Options (persistent):"
  echo -e "  enable-config\t\t enable the equalizer configuration"
  echo -e "  disable-config\t disable the equalizer configuration"
  echo -e ""
  echo -e "Options (all):"
  echo -e "  debug\t\t\t run equalizer diagnostics"
  echo -e "  log\t\t\t show current equalizer log"
  echo -e "  status\t\t show current equalizer status"
  echo -e ""
  exit
fi

if [ "$1" = "status" ]; then
 # Do nothing except show status
 echo -n
fi

# Refresh current sink status and display equalizer information
PA_CURRENT_SINK=$(pacmd stat | grep "Default sink name" | sed 's/Default sink name: //g')
if [ "$PA_CURRENT_SINK" = "$PA_LADSPA_SINK" ]; then
  echo "-------------------------------------"
  echo "Equalizer status: [enabled]"

  if [ -f $HOME/.pulse/default.pa ]; then
    if [ "$(cat $HOME/.pulse/default.pa | grep -m1 "### BEGIN: Equalized audio configuration")" = "### BEGIN: Equalized audio configuration" ]; then
      echo "Equalizer configuration status: [enabled]"
    else
      echo "Equalizer configuration status: [disabled]"
    fi
  else
    echo "Equalizer configuration status: [disabled]"
  fi

  echo "Equalizer plugin: [$PA_LADSPA_PLUGIN/$PA_LADSPA_LABEL]"
  echo "Equalizer control: [$PA_LADSPA_CONTROLS]"

  if [ -f $CONFIG_NAME ]; then
    echo "NOTE: Using user-customized settings from '$CONFIG_NAME'..."
  fi

  echo "-------------------------------------"
else
  echo "-------------------------------------"
  echo "Equalizer status: [disabled]"

  if [ -f $HOME/.pulse/default.pa ]; then
    if [ "$(cat $HOME/.pulse/default.pa | grep -m1 "### BEGIN: Equalized audio configuration")" = "### BEGIN: Equalized audio configuration" ]; then
      echo "Equalizer configuration status: [enabled]"
      echo "Equalizer plugin: [$PA_LADSPA_PLUGIN/$PA_LADSPA_LABEL]"
      echo "Equalizer control: [$PA_LADSPA_CONTROLS]"

      if [ -f $CONFIG_NAME ]; then
        echo "NOTE: Using user-customized settings from '$CONFIG_NAME'..."
      fi

    else
      echo "Equalizer configuration status: [disabled]"
    fi
  else
    echo "Equalizer configuration status: [disabled]"
  fi

  echo "-------------------------------------"
fi
Почитаю затра, похоже это конфиг, с правами 0755.
In Tux We Trust
redix,
смотрите строки 113-114
Gnome 2 >> Unity >> KDE 4 >> Openbox >> Awesome >> Xmonad
GitHub , BitBuket
Я уже увидел:
In Tux We Trust
но фишка в том, что изменение этих значений ничего не даёт
я пробовал менять на 13007/20 в первой строке и 13007 во второй
перезагружал пульс, открывал эквалайзер и он по-прежнему сбрасывал значение на 65536 при нажатии кнопки сохранения
возможно, нужен ребут... :dumb:

P.S> я с этим эквалайзером давненько уже воевал - безуспешно, ни один рецепт из инета не помог
снёс его нафиг, всё равно у меня 99% музыки flac и alac, а она и без эквалайзера нормально звучит, имхо
сейчас вот подумал, что нашлось решение... ан нет (((
Gnome 2 >> Unity >> KDE 4 >> Openbox >> Awesome >> Xmonad
GitHub , BitBuket
Haron_Prime
я с этим эквалайзером давненько уже воевал
Я тоже, года два как, там еще один файл есть /usr/share/pulseaudio-equalizer/pulseaudio-equalizer.py, тоже с 755-ми правами:
#!/usr/bin/env python2

# PulseAudio Equalizer (PyGTK Interface)
#
# Intended for use in conjunction with pulseaudio-equalizer script
#
# Author: Conn O'Griofa <connogriofa AT gmail DOT com>
# Version: (see '/usr/pulseaudio-equalizer' script)
#

import pygtk
pygtk.require('2.0')
import gtk, gobject
import os

configdir = os.getenv('HOME') + "/.config/pulse"
eqconfig = configdir + "/equalizerrc"
eqconfig2 = configdir + "/equalizerrc.test"
eqpresets = eqconfig + ".availablepresets"
presetdir1 = configdir + "/presets"
presetdir2 = "/usr/share/pulseaudio-equalizer/presets"

def GetSettings():
	global rawdata
	global rawpresets
	global ladspa_filename
	global ladspa_name
	global ladspa_label
	global preamp
	global num_ladspa_controls
	global ladspa_controls
	global ladspa_inputs
	global status
	global realstatus
	global persistence
	global preset
	global ranges
	global windowtitle
	global presetmatch
	global clearpreset

	print "Getting settings..."

	os.system('pulseaudio-equalizer interface.getsettings')

	f = open(eqconfig, "r")
	rawdata=f.read().split('\n')
	f.close()

	rawpresets = {}
	f = open(eqpresets, "r")
	rawpresets=f.read().split('\n')
	f.close()
	del rawpresets[len(rawpresets)-1]

	ladspa_filename = str(rawdata[0])
	ladspa_name = str(rawdata[1])
	ladspa_label = str(rawdata[2])
	preamp = (rawdata[3])
	preset = str(rawdata[4])
	status = int(rawdata[5])
	persistence = int(rawdata[6])
	ranges = rawdata[7:9]
	num_ladspa_controls = int(rawdata[9])
	ladspa_controls = rawdata[10:(10+num_ladspa_controls)]
	ladspa_inputs = rawdata[(10+num_ladspa_controls):(10+num_ladspa_controls)+(num_ladspa_controls)]

	if status == 1:
		realstatus = "Enabled"
	else:
		realstatus = "Disabled"

	windowtitle = "PulseAudio " + ladspa_label

	clearpreset = 1
	presetmatch = ''
	for i in range(len(rawpresets)):
		if rawpresets[i] == preset:
			print "Match!"
			presetmatch = 1

def ApplySettings():
	print "Applying settings..."
	f = open(eqconfig, "w")
	del rawdata[:]
	rawdata.append(str(ladspa_filename))
	rawdata.append(str(ladspa_name))
	rawdata.append(str(ladspa_label))
	rawdata.append(str(preamp))
	rawdata.append(str(preset))
	rawdata.append(str(status))
	rawdata.append(str(persistence))
	for i in range(2):
		rawdata.append(str(ranges[i]))
	rawdata.append(str(num_ladspa_controls))
	for i in range(num_ladspa_controls):
		rawdata.append(str(ladspa_controls[i]))
	for i in range(num_ladspa_controls):
		rawdata.append(str(ladspa_inputs[i]))

	for i in rawdata:
		f.write(str(i)+'\n')
	f.close()

	os.system('pulseaudio-equalizer interface.applysettings')

def FormatLabels(x):
		global c
		global suffix
		global whitespace1
		global whitespace2

		whitespace1 = ""
		whitespace2 = ""

		current_input = int(ladspa_inputs[x-1])
		if current_input < 99:
			a = current_input
			suffix = "Hz"
		if current_input > 99 and current_input < 999:
			a = current_input
			suffix = "Hz"
		if current_input > 999 and current_input < 9999:
			a = float(current_input)/1000
			suffix = "KHz"
		if current_input > 9999:
			a = float(current_input)/1000
			suffix = "KHz"

		# Filter out unnecessary ".0" from ladspa_inputs
		b=str(a)
		if b[-2:] == ".0":
			c = b[:-2]
		else:
			c = b

		# Add whitespace formatting to ensure text is centered
		if len(c) == 3 and len(suffix) == 2:
			whitespace2 = " "
		if len(c) < 4 and len(suffix) == 3:
			whitespace1 = " "
		if len(c) < 2 and len(suffix) == 3:
			whitespace1 = "  "

class Equalizer:
    def on_scale(self, widget, y):
	global ladspa_controls
	global preset
	global clearpreset
        newvalue = float(round(widget.get_value(),1))
	del ladspa_controls[y-1]
	ladspa_controls.insert(y-1, newvalue)
	if clearpreset == 1:
		preset = ''
		presetsbox.get_child().set_text(preset)
	for i in range(1,num_ladspa_controls+1):
		self.scalevalues[i].set_markup("<small>" + str(float(ladspa_controls[i-1])) + "\ndB</small>")

    def on_presetsbox(self, widget, x):
	global preset
	global presetmatch
	global clearpreset
	global ladspa_filename
	global ladspa_name
	global ladspa_label
	global preamp
	global num_ladspa_controls
	global ladspa_controls
	global ladspa_inputs
	global windowtitle
	preset = presetsbox.get_child().get_text()

	presetmatch = ''
	for i in range(len(rawpresets)):
		if rawpresets[i] == preset:
			print "Match!"
			presetmatch = 1

	if presetmatch == 1:
		if os.path.isfile(presetdir1 + "/" + preset + ".preset"):
			f = open(presetdir1 + "/" + preset + ".preset", "r")
			rawdata=f.read().split('\n')
			f.close
		elif os.path.isfile(presetdir2 + "/" + preset + ".preset"):
			f = open(presetdir2 + "/" + preset + ".preset", "r")
			rawdata=f.read().split('\n')
			f.close
		else:
			print "Can't find %s preset" % preset

		ladspa_filename = str(rawdata[0])
		ladspa_name = str(rawdata[1])
		ladspa_label = str(rawdata[2])
		#preamp = (rawdata[3])
		preset = str(rawdata[4])
		num_ladspa_controls = int(rawdata[5])
		ladspa_controls = rawdata[6:(6+num_ladspa_controls)]
		ladspa_inputs = rawdata[(6+num_ladspa_controls):(6+num_ladspa_controls)+(num_ladspa_controls)]

		preampscale.set_value(float(preamp))
		preampscalevalue.set_markup(str(preampscale.get_value()) + "x")
		windowtitle = "PulseAudio " + ladspa_label
		self.window.set_title(windowtitle + " [" + realstatus + "]")
		clearpreset = ''
		for i in range(1,num_ladspa_controls+1):
			self.scales[i].set_value(float(ladspa_controls[i-1]))
			FormatLabels(i)
			self.labels[i].set_markup("<small>" + whitespace1 + c + "\n" + whitespace2 + suffix + "</small>")
			self.scalevalues[i].set_markup("<small>" + str(float(ladspa_controls[i-1])) + "\ndB</small>")
		# Set preset again due to interference from scale modifications
		preset = str(rawdata[4])
		clearpreset = 1
		presetsbox.get_child().set_text(preset)
		ApplySettings()

    def on_applysettings(self, widget):
	ApplySettings()

    def on_resetsettings(self, widget):
	print "Resetting to defaults..."
	os.system('pulseaudio-equalizer interface.resetsettings')
	GetSettings()

	eqenabled.set_active(status)
	keepsettings.set_active(persistence)
	presetsbox.get_child().set_text(preset)
	preampscale.set_value(float(preamp))
	for i in range(1,num_ladspa_controls+1):
		self.scales[i].set_value(float(ladspa_controls[i-1]))
		FormatLabels(i)
		self.labels[i].set_markup("<small>" + whitespace1 + c + "\n" + whitespace2 + suffix + "</small>")
		self.scalevalues[i].set_markup("<small>" + str(float(ladspa_controls[i-1])) + "\ndB</small>")

    def on_savepreset(self, widget):
	global preset
	global presetmatch
	preset = presetsbox.get_child().get_text()
	if preset == '' or presetmatch == 1:
		print 'Invalid preset name'
	else:
	    	f = open(presetdir1 + "/" + preset + ".preset", "w")

		del rawdata[:]
		rawdata.append(str(ladspa_filename))
		rawdata.append(str(ladspa_name))
		rawdata.append(str(ladspa_label))
		rawdata.append(str(preamp))
		rawdata.append(str(preset))
		rawdata.append(str(num_ladspa_controls))
		for i in range(num_ladspa_controls):
			rawdata.append(str(ladspa_controls[i]))
		for i in range(num_ladspa_controls):
			rawdata.append(str(ladspa_inputs[i]))

		for i in rawdata:
			f.write(str(i)+'\n')
		f.close()

		# Clear preset list from ComboBox
		for i in range(len(rawpresets)):
			presetsbox.remove_text(0)

		# Apply settings (which will save new preset as default)
		ApplySettings()

		# Refresh (and therefore, sort) preset list
		GetSettings()

		# Repopulate preset list into ComboBox
		for i in range(len(rawpresets)):
			presetsbox.append_text(rawpresets[i])

    def on_preampscale(self, widget):
	global preamp
        preamp = float(round(widget.get_value(),1))
	preampscalevalue.set_markup(str(preamp) + "x")
	#preset = ''
	#presetsbox.get_child().set_text(preset)

    def on_eqenabled(self, widget):
	global status
        if widget.get_active():
		self.window.set_title(windowtitle + " [Enabled]")
		status = 1
        else:
		self.window.set_title(windowtitle + " [Disabled]")
		status = 0
	ApplySettings()

    def on_keepsettings(self, widget):
	global persistence
        if widget.get_active():
		persistence = 1
        else:
		persistence = 0
	ApplySettings()

    def on_removepreset(self,widget):
	global preset
        global presets
        dialog = gtk.FileChooserDialog("Choose preset to remove...",
                               None,
                               gtk.FILE_CHOOSER_ACTION_OPEN,
                               (gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL,
                                gtk.STOCK_OK, gtk.RESPONSE_OK))
        dialog.set_default_response(gtk.RESPONSE_OK)

        filter = gtk.FileFilter()
        filter.set_name("Preset files")
        filter.add_pattern("*.preset")
        dialog.add_filter(filter)
        dialog.set_current_folder(presetdir1)
        dialog.show()

        response = dialog.run()
        if response == gtk.RESPONSE_OK:
		filename = dialog.get_filename()
		path_and_name = os.path.split(filename)
		name = path_and_name[1]
		os.remove(filename)

		# Make a note of the current preset, then clear it temporarily
		preset = presetsbox.get_child().get_text()
		realpreset = preset
		preset = ''
		presetsbox.get_child().set_text('')

		# Clear preset list from ComboBox
		for i in range(len(rawpresets)):
			presetsbox.remove_text(0)

		# Refresh (and therefore, sort) preset list
		GetSettings()

		# Clear preset (if it is the same as removed preset), or restore preset
		if (presetdir1 + "/" + preset + ".preset") == filename:
			preset = ''
		else:
			preset = realpreset

		# Restore preset
		presetsbox.get_child().set_text(preset)

		# Repopulate preset list into ComboBox
		for i in range(len(rawpresets)):
			presetsbox.append_text(rawpresets[i])

		# Apply settings
		ApplySettings()

        dialog.destroy()

    def destroy_equalizer(self, widget, data=None):
        gtk.main_quit()

    def __init__(self):
	GetSettings()

        self.window = gtk.Window(gtk.WINDOW_TOPLEVEL)
        self.window.set_resizable(True)

        self.window.connect("destroy", self.destroy_equalizer)
        self.window.set_title(windowtitle + " [" + realstatus + "]")
        self.window.set_border_width(0)

        icon_theme = gtk.icon_theme_get_default()
        icon_theme = gtk.icon_theme_get_default()
        if icon_theme.has_icon("multimedia-volume-control"):
            icon = icon_theme.load_icon("multimedia-volume-control", 16, 0)
            self.window.set_icon(icon)
        elif icon_theme.has_icon("gnome-volume-control"):
            icon = icon_theme.load_icon("gnome-volume-control",16,0)
            self.window.set_icon(icon)
        elif icon_theme.has_icon("stock_volume"):
            icon = icon_theme.load_icon("stock_volume",16,0)
            self.window.set_icon(icon)
        else:
            print ("No icon found, window will be iconless")

        menu = gtk.Menu()

        menu_item = gtk.MenuItem('Reset to defaults')
        menu_item.connect("activate", self.on_resetsettings)
	menu.append(menu_item)
	menu_item.show()
	menu_item = gtk.MenuItem('Remove user preset...')
	menu_item.connect("activate", self.on_removepreset)
        menu.append(menu_item)
	menu_item.show()
        root_menu = gtk.MenuItem("Advanced")
        root_menu.show()
        root_menu.set_submenu(menu)

        vbox1 = gtk.VBox(False, 0)
        self.window.add(vbox1)
        vbox1.show()
        menu_bar = gtk.MenuBar()
        vbox1.pack_start(menu_bar, False, False, 2)
        menu_bar.show()
        menu_bar.append (root_menu)

        hbox1 = gtk.HBox(False, 1)
        #hbox1.set_border_width(10)
        vbox1.add(hbox1)
        hbox1.show()

        table = gtk.Table(3, 17, False)
        table.set_border_width(5)
        hbox1.add(table)

	# Preamp widget
	global preampscale
	global preampscalevalue
	preampscale = gtk.VScale()
	preampscale.set_draw_value(0)
	preampscale.set_inverted(1)
	preampscale.set_value_pos(gtk.POS_BOTTOM)
	preampscale.set_range(0.0,2.0)
	preampscale.set_increments(1, 0.1)
	preampscale.set_digits(1)
	preampscale.set_size_request(35,200)
	preampscale.set_value(float(preamp))
	preampscale.connect("value-changed", self.on_preampscale)
	label = gtk.Label()
	label.set_markup("<small>Preamp</small>")
	preampscalevalue = gtk.Label()
	preampscalevalue.set_markup(str(preampscale.get_value()) + "x")
	table.attach(label, 1, 2, 0, 1)
	table.attach(preampscale, 1, 2, 1, 2)
	table.attach(preampscalevalue, 1, 2, 2, 3)
	#label.show()
	#preampscale.show()
	#preampscalevalue.show()

	# Separator between preamp and bands
	separator = gtk.VSeparator()
	table.attach(separator, 2, 3, 1, 2)
	#separator.show()

	# Equalizer bands
	global scale
	self.scales = {}
	self.labels = {}
	self.scalevalues = {}
	for x in range(1,num_ladspa_controls+1):
		scale = gtk.VScale()
		self.scales[x] = scale
		scale.set_draw_value(0)
		scale.set_inverted(1)
		scale.set_value_pos(gtk.POS_BOTTOM)
		scale.set_range(float(ranges[0]), float(ranges[1]))
		scale.set_increments(1, 0.1)
		scale.set_digits(1)
		scale.set_size_request(35,200)
		scale.set_value(float(ladspa_controls[x-1]))
		scale.connect("value-changed", self.on_scale, x)
		FormatLabels(x)
		label = gtk.Label()
		self.labels[x] = label
		label.set_markup("<small>" + whitespace1 + c + "\n" + whitespace2 + suffix + "</small>")
		scalevalue = gtk.Label()
		self.scalevalues[x] = scalevalue
		scalevalue.set_markup("<small>" + str(scale.get_value()) + "\ndB</small>")
		table.attach(label, x+2, x+3, 0, 1)
		table.attach(scale, x+2, x+3, 1, 2)
		table.attach(scalevalue, x+2, x+3, 2, 3)
		label.show()
		scale.show()
		scalevalue.show()

	table.show()

        vbox2 = gtk.VBox(True, 1)
        vbox2.set_border_width(10)
        hbox1.add(vbox2)
        vbox2.show()

        presetslabel = gtk.Label()
	presetslabel.set_markup("<small>Preset:</small>")
	vbox2.pack_start(presetslabel, False, False, 0)
	presetslabel.show()

	global presetsbox
	presetsbox = gtk.combo_box_entry_new_text()
	vbox2.pack_start(presetsbox, False, False, 0)
	presetsbox.get_child().set_text(preset)
	for i in range(len(rawpresets)):
		presetsbox.append_text(rawpresets[i])
        presetsbox.connect("changed", self.on_presetsbox, x)
	presetsbox.show()

	savepreset = gtk.Button('Save Preset')
	vbox2.pack_start(savepreset, False, False, 0)
        savepreset.connect("clicked", self.on_savepreset)
	savepreset.show()

	global eqenabled
        eqenabled = gtk.CheckButton("EQ Enabled")
        eqenabled.set_active(status)
        eqenabled.unset_flags(gtk.CAN_FOCUS)
        eqenabled.connect("clicked", self.on_eqenabled)
	vbox2.pack_start(eqenabled, False, False, 0)
	eqenabled.show()

	global keepsettings
        keepsettings = gtk.CheckButton('Keep Settings')
	keepsettings.set_active(persistence)
        keepsettings.unset_flags(gtk.CAN_FOCUS)
        keepsettings.connect("clicked", self.on_keepsettings)
	vbox2.pack_start(keepsettings, False, False, 0)
	keepsettings.show()

	applysettings = gtk.Button('Apply Settings')
	vbox2.pack_start(applysettings, False, False, 0)
        applysettings.connect("clicked", self.on_applysettings)
	applysettings.show()

	quitbutton = gtk.Button('Quit')
	vbox2.pack_start(quitbutton, False, False, 0)
	quitbutton.connect("clicked", lambda w: gtk.main_quit())
	quitbutton.show()

	separator = gtk.HSeparator()
	vbox2.pack_start(separator, False, False, 0)
	separator.set_size_request(100, 10)
	#separator.show()

        self.window.show()

def main():
    gtk.main()
    return 0

if __name__ == "__main__":
    Equalizer()
    main()
Просто звуковая не совсем из дешевых, хочется от нее получить большее.
In Tux We Trust
Haron_Prime
1 - меняем настройки эквалайзера (к примеру, выбираем там другой пресет), сохраняем
2 - открываем default.pa и видим..... 65536 вместо тех цифр, что мы устанавливали
А если попробовать запретить измения в этот файл??? ............ через chattr + i
Ошибки не исчезают с опытом - они просто умнеют
vasek, а смысл?
захотелось мне изменить пресет или свой создать, а изменения не сохраняются (((
Gnome 2 >> Unity >> KDE 4 >> Openbox >> Awesome >> Xmonad
GitHub , BitBuket
 
Зарегистрироваться или войдите чтобы оставить сообщение.