diff options
author | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
---|---|---|
committer | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
commit | 00bb99ac80741fc50ef8a289719373032f2391eb (patch) | |
tree | 3a5a9bf72f942784b38bf77dd66c534662fab5f2 /ksayit/Freeverb_plugin | |
download | tdeaccessibility-00bb99ac80741fc50ef8a289719373032f2391eb.tar.gz tdeaccessibility-00bb99ac80741fc50ef8a289719373032f2391eb.zip |
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeaccessibility@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksayit/Freeverb_plugin')
-rw-r--r-- | ksayit/Freeverb_plugin/Makefile.am | 13 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/configure.in.in | 17 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/freeverb_setup.ui | 668 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/freeverbsetupimpl.cpp | 116 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/freeverbsetupimpl.h | 62 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/kdeexportfix.h | 22 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/ksayit_libFreeverb.desktop | 52 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/ksayit_libFreeverb_service.desktop | 48 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/ksayitfreeverblib.cpp | 164 | ||||
-rw-r--r-- | ksayit/Freeverb_plugin/ksayitfreeverblib.h | 96 |
10 files changed, 1258 insertions, 0 deletions
diff --git a/ksayit/Freeverb_plugin/Makefile.am b/ksayit/Freeverb_plugin/Makefile.am new file mode 100644 index 0000000..0db4104 --- /dev/null +++ b/ksayit/Freeverb_plugin/Makefile.am @@ -0,0 +1,13 @@ +INCLUDES = -I$(top_srcdir)/ksayit/src $(all_includes) +METASOURCES = AUTO +kde_servicetypes_DATA = ksayit_libFreeverb_service.desktop +kde_services_DATA = ksayit_libFreeverb.desktop +fxpluginsdir = $(kde_libraries)/kde3 +fxplugins_LTLIBRARIES = libFreeverb_plugin.la +libFreeverb_plugin_la_LDFLAGS = -avoid-version -module -no-undefined \ + $(all_libraries) +libFreeverb_plugin_la_LIBADD = $(LIB_KDECORE) $(LIB_KDEUI) -lartskde\ + -lartsmodules +noinst_HEADERS = freeverbsetupimpl.h ksayitfreeverblib.h kdeexportfix.h +libFreeverb_plugin_la_SOURCES = freeverbsetupimpl.cpp freeverb_setup.ui \ + ksayitfreeverblib.cpp diff --git a/ksayit/Freeverb_plugin/configure.in.in b/ksayit/Freeverb_plugin/configure.in.in new file mode 100644 index 0000000..adc474e --- /dev/null +++ b/ksayit/Freeverb_plugin/configure.in.in @@ -0,0 +1,17 @@ +dnl ========================== +dnl checks for Hadifix plug in +dnl ========================== + +AC_ARG_ENABLE(ksayit-audio-plugins, + AC_HELP_STRING([--enable-ksayit-audio-plugins], + [build audio plugins for KSayIt [default=no]]), + ksayit_audio_plugins=$enableval, + ksayit_audio_plugins=no) + +compile_ksayit_audio_plugins="no" + +if test "x$ksayit_audio_plugins" = "xyes"; then + compile_ksayit_audio_plugins="yes" +fi + +AM_CONDITIONAL(include_ksayit_audio_plugins, test "x$compile_ksayit_audio_plugins" = "xyes")
\ No newline at end of file diff --git a/ksayit/Freeverb_plugin/freeverb_setup.ui b/ksayit/Freeverb_plugin/freeverb_setup.ui new file mode 100644 index 0000000..ab3808a --- /dev/null +++ b/ksayit/Freeverb_plugin/freeverb_setup.ui @@ -0,0 +1,668 @@ +<!DOCTYPE UI><UI version="3.1" stdsetdef="1"> +<class>Freeverb_Setup</class> +<widget class="QDialog"> + <property name="name"> + <cstring>Freeverb_Setup</cstring> + </property> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>360</width> + <height>325</height> + </rect> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>1</hsizetype> + <vsizetype>1</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>360</width> + <height>300</height> + </size> + </property> + <property name="caption"> + <string>FreeVerb</string> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <property name="resizeMode"> + <enum>Minimum</enum> + </property> + <widget class="QLayoutWidget"> + <property name="name"> + <cstring>layout6</cstring> + </property> + <hbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QFrame"> + <property name="name"> + <cstring>frame_room</cstring> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>5</hsizetype> + <vsizetype>3</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>0</width> + <height>260</height> + </size> + </property> + <property name="frameShape"> + <enum>StyledPanel</enum> + </property> + <property name="frameShadow"> + <enum>Raised</enum> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QLabel"> + <property name="name"> + <cstring>textLabel_room</cstring> + </property> + <property name="text"> + <string><b>Room</b></string> + </property> + <property name="alignment"> + <set>WordBreak|AlignCenter</set> + </property> + </widget> + <widget class="QLCDNumber"> + <property name="name"> + <cstring>LCD_room</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>0</hsizetype> + <vsizetype>1</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="paletteBackgroundColor"> + <color> + <red>171</red> + <green>223</green> + <blue>171</blue> + </color> + </property> + <property name="frameShape"> + <enum>Panel</enum> + </property> + <property name="frameShadow"> + <enum>Sunken</enum> + </property> + <property name="lineWidth"> + <number>2</number> + </property> + <property name="numDigits"> + <number>2</number> + </property> + <property name="segmentStyle"> + <enum>Flat</enum> + </property> + </widget> + <widget class="QSlider"> + <property name="name"> + <cstring>slider_room</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="minValue"> + <number>0</number> + </property> + <property name="maxValue"> + <number>99</number> + </property> + <property name="lineStep"> + <number>5</number> + </property> + <property name="value"> + <number>99</number> + </property> + <property name="orientation"> + <enum>Vertical</enum> + </property> + <property name="tickmarks"> + <enum>Above</enum> + </property> + </widget> + </vbox> + </widget> + <widget class="QFrame"> + <property name="name"> + <cstring>frame_damp</cstring> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>5</hsizetype> + <vsizetype>3</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>0</width> + <height>260</height> + </size> + </property> + <property name="frameShape"> + <enum>StyledPanel</enum> + </property> + <property name="frameShadow"> + <enum>Raised</enum> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QLabel"> + <property name="name"> + <cstring>textLabel_damp</cstring> + </property> + <property name="text"> + <string><b>Damp</b></string> + </property> + <property name="alignment"> + <set>WordBreak|AlignCenter</set> + </property> + </widget> + <widget class="QLCDNumber"> + <property name="name"> + <cstring>LCD_damp</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>0</hsizetype> + <vsizetype>1</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="paletteBackgroundColor"> + <color> + <red>171</red> + <green>223</green> + <blue>171</blue> + </color> + </property> + <property name="frameShape"> + <enum>Panel</enum> + </property> + <property name="frameShadow"> + <enum>Sunken</enum> + </property> + <property name="lineWidth"> + <number>2</number> + </property> + <property name="numDigits"> + <number>2</number> + </property> + <property name="segmentStyle"> + <enum>Flat</enum> + </property> + </widget> + <widget class="QSlider"> + <property name="name"> + <cstring>slider_damp</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="lineStep"> + <number>5</number> + </property> + <property name="value"> + <number>99</number> + </property> + <property name="orientation"> + <enum>Vertical</enum> + </property> + <property name="tickmarks"> + <enum>Above</enum> + </property> + </widget> + </vbox> + </widget> + <widget class="QFrame"> + <property name="name"> + <cstring>frame_wet</cstring> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>5</hsizetype> + <vsizetype>3</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>0</width> + <height>260</height> + </size> + </property> + <property name="frameShape"> + <enum>StyledPanel</enum> + </property> + <property name="frameShadow"> + <enum>Raised</enum> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QLabel"> + <property name="name"> + <cstring>textLabel_wet</cstring> + </property> + <property name="text"> + <string><b>Wet</b></string> + </property> + <property name="alignment"> + <set>WordBreak|AlignCenter</set> + </property> + </widget> + <widget class="QLCDNumber"> + <property name="name"> + <cstring>LCD_wet</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>0</hsizetype> + <vsizetype>1</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="paletteBackgroundColor"> + <color> + <red>171</red> + <green>223</green> + <blue>171</blue> + </color> + </property> + <property name="frameShape"> + <enum>Panel</enum> + </property> + <property name="frameShadow"> + <enum>Sunken</enum> + </property> + <property name="lineWidth"> + <number>2</number> + </property> + <property name="numDigits"> + <number>2</number> + </property> + <property name="segmentStyle"> + <enum>Flat</enum> + </property> + </widget> + <widget class="QSlider"> + <property name="name"> + <cstring>slider_wet</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="lineStep"> + <number>5</number> + </property> + <property name="value"> + <number>99</number> + </property> + <property name="orientation"> + <enum>Vertical</enum> + </property> + <property name="tickmarks"> + <enum>Above</enum> + </property> + </widget> + </vbox> + </widget> + <widget class="QFrame"> + <property name="name"> + <cstring>frame_dry</cstring> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>5</hsizetype> + <vsizetype>3</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>0</width> + <height>260</height> + </size> + </property> + <property name="frameShape"> + <enum>StyledPanel</enum> + </property> + <property name="frameShadow"> + <enum>Raised</enum> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QLabel"> + <property name="name"> + <cstring>textLabel_dry</cstring> + </property> + <property name="text"> + <string><b>Dry</b></string> + </property> + <property name="alignment"> + <set>WordBreak|AlignCenter</set> + </property> + </widget> + <widget class="QLCDNumber"> + <property name="name"> + <cstring>LCD_dry</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>0</hsizetype> + <vsizetype>1</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="paletteBackgroundColor"> + <color> + <red>171</red> + <green>223</green> + <blue>171</blue> + </color> + </property> + <property name="frameShape"> + <enum>Panel</enum> + </property> + <property name="frameShadow"> + <enum>Sunken</enum> + </property> + <property name="lineWidth"> + <number>2</number> + </property> + <property name="numDigits"> + <number>2</number> + </property> + <property name="segmentStyle"> + <enum>Flat</enum> + </property> + </widget> + <widget class="QSlider"> + <property name="name"> + <cstring>slider_dry</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="lineStep"> + <number>5</number> + </property> + <property name="value"> + <number>99</number> + </property> + <property name="orientation"> + <enum>Vertical</enum> + </property> + <property name="tickmarks"> + <enum>Above</enum> + </property> + </widget> + </vbox> + </widget> + <widget class="QFrame"> + <property name="name"> + <cstring>frame_width</cstring> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>5</hsizetype> + <vsizetype>3</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>0</width> + <height>260</height> + </size> + </property> + <property name="frameShape"> + <enum>StyledPanel</enum> + </property> + <property name="frameShadow"> + <enum>Raised</enum> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QLabel"> + <property name="name"> + <cstring>textLabel_width</cstring> + </property> + <property name="text"> + <string><b>Width</b></string> + </property> + <property name="alignment"> + <set>WordBreak|AlignCenter</set> + </property> + </widget> + <widget class="QLCDNumber"> + <property name="name"> + <cstring>LCD_width</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>0</hsizetype> + <vsizetype>1</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="paletteBackgroundColor"> + <color> + <red>171</red> + <green>223</green> + <blue>171</blue> + </color> + </property> + <property name="frameShape"> + <enum>Panel</enum> + </property> + <property name="frameShadow"> + <enum>Sunken</enum> + </property> + <property name="lineWidth"> + <number>2</number> + </property> + <property name="numDigits"> + <number>2</number> + </property> + <property name="segmentStyle"> + <enum>Flat</enum> + </property> + </widget> + <widget class="QSlider"> + <property name="name"> + <cstring>slider_width</cstring> + </property> + <property name="enabled"> + <bool>true</bool> + </property> + <property name="lineStep"> + <number>5</number> + </property> + <property name="value"> + <number>99</number> + </property> + <property name="orientation"> + <enum>Vertical</enum> + </property> + <property name="tickmarks"> + <enum>Above</enum> + </property> + </widget> + </vbox> + </widget> + </hbox> + </widget> + <widget class="Line"> + <property name="name"> + <cstring>line5</cstring> + </property> + <property name="sizePolicy"> + <sizepolicy> + <hsizetype>3</hsizetype> + <vsizetype>0</vsizetype> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="frameShape"> + <enum>HLine</enum> + </property> + <property name="frameShadow"> + <enum>Sunken</enum> + </property> + <property name="orientation"> + <enum>Horizontal</enum> + </property> + </widget> + <widget class="QLayoutWidget"> + <property name="name"> + <cstring>layout12</cstring> + </property> + <hbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <spacer> + <property name="name"> + <cstring>spacer13</cstring> + </property> + <property name="orientation"> + <enum>Horizontal</enum> + </property> + <property name="sizeType"> + <enum>Expanding</enum> + </property> + <property name="sizeHint"> + <size> + <width>180</width> + <height>20</height> + </size> + </property> + </spacer> + <widget class="KPushButton"> + <property name="name"> + <cstring>OK_Button</cstring> + </property> + <property name="minimumSize"> + <size> + <width>60</width> + <height>0</height> + </size> + </property> + <property name="text"> + <string>&OK</string> + </property> + <property name="autoDefault"> + <bool>true</bool> + </property> + </widget> + </hbox> + </widget> + </vbox> +</widget> +<connections> + <connection> + <sender>slider_room</sender> + <signal>valueChanged(int)</signal> + <receiver>Freeverb_Setup</receiver> + <slot>sliderRoomChanged(int)</slot> + </connection> + <connection> + <sender>slider_damp</sender> + <signal>valueChanged(int)</signal> + <receiver>Freeverb_Setup</receiver> + <slot>sliderDampChanged(int)</slot> + </connection> + <connection> + <sender>slider_wet</sender> + <signal>valueChanged(int)</signal> + <receiver>Freeverb_Setup</receiver> + <slot>sliderWetChanged(int)</slot> + </connection> + <connection> + <sender>slider_dry</sender> + <signal>valueChanged(int)</signal> + <receiver>Freeverb_Setup</receiver> + <slot>sliderDryChanged(int)</slot> + </connection> + <connection> + <sender>slider_width</sender> + <signal>valueChanged(int)</signal> + <receiver>Freeverb_Setup</receiver> + <slot>sliderWidthChanged(int)</slot> + </connection> + <connection> + <sender>OK_Button</sender> + <signal>clicked()</signal> + <receiver>Freeverb_Setup</receiver> + <slot>slotOKwasClicked()</slot> + </connection> +</connections> +<slots> + <slot>sliderRoomChanged(int)</slot> + <slot>sliderDampChanged(int)</slot> + <slot>sliderWetChanged(int)</slot> + <slot>sliderDryChanged(int)</slot> + <slot>sliderWidthChanged(int)</slot> + <slot>slotOKwasClicked()</slot> +</slots> +<layoutdefaults spacing="6" margin="11"/> +<includehints> + <includehint>kpushbutton.h</includehint> +</includehints> +</UI> diff --git a/ksayit/Freeverb_plugin/freeverbsetupimpl.cpp b/ksayit/Freeverb_plugin/freeverbsetupimpl.cpp new file mode 100644 index 0000000..cf16c0d --- /dev/null +++ b/ksayit/Freeverb_plugin/freeverbsetupimpl.cpp @@ -0,0 +1,116 @@ +/*************************************************************************** + freeverbsetupimpl.cpp - description + ------------------- + begin : Son Nov 2 2003 + copyright : (C) 2003 by Robert Vogl + email : voglrobe@saphir + ***************************************************************************/ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ + +#include <iostream> +using namespace std; + +// QT includes +#include <qslider.h> +#include <qlcdnumber.h> + +// KDE includes +#include <kdebug.h> + +// App specific includes +#include "freeverbsetupimpl.h" + +FreeverbSetupImpl::FreeverbSetupImpl(QWidget *parent, const char *name, bool modal, KConfig *config ) + : Freeverb_Setup(parent,name,modal), m_config(config) { + + // initialize Widgets + Init(); + +} +FreeverbSetupImpl::~FreeverbSetupImpl(){ +} + + +void FreeverbSetupImpl::sliderRoomChanged(int value) +{ + LCD_room->display( 99-value ); +} + + +void FreeverbSetupImpl::sliderDampChanged(int value) +{ + LCD_damp->display( 99-value ); +} + + +void FreeverbSetupImpl::sliderWetChanged(int value) +{ + LCD_wet->display( 99-value ); +} + + +void FreeverbSetupImpl::sliderDryChanged(int value) +{ + LCD_dry->display( 99-value ); +} + + +void FreeverbSetupImpl::sliderWidthChanged(int value) +{ + LCD_width->display( 99-value ); +} + + +void FreeverbSetupImpl::saveWasClicked() +{ + kdDebug(100200) << "FreeverbSetupImpl::saveWasClicked()" << endl; + // Save freeverb configuration + m_config->setGroup("Synth_FREEVERB"); + m_config->writeEntry( "room", LCD_room->intValue() ); + m_config->writeEntry( "damp", LCD_damp->intValue() ); + m_config->writeEntry( "wet", LCD_wet->intValue() ); + m_config->writeEntry( "dry", LCD_dry->intValue() ); + m_config->writeEntry( "width", LCD_width->intValue() ); + m_config->sync(); +} + +void FreeverbSetupImpl::Init() +{ + // Read freeverb configuration + m_config->setGroup("Synth_FREEVERB"); + LCD_room->display( m_config->readNumEntry("room", 50) ); + slider_room->setValue( 99-LCD_room->intValue() ); + + LCD_damp->display( m_config->readNumEntry("damp", 50) ); + slider_damp->setValue( 99-LCD_damp->intValue() ); + + LCD_wet->display( m_config->readNumEntry("wet", 50) ); + slider_wet->setValue( 99-LCD_wet->intValue() ); + + LCD_dry->display( m_config->readNumEntry("dry", 50) ); + slider_dry->setValue( 99-LCD_dry->intValue() ); + + LCD_width->display( m_config->readNumEntry("width", 50) ); + slider_width->setValue( 99-LCD_width->intValue() ); +} + + +void FreeverbSetupImpl::slotOKwasClicked() +{ + // save configuration + saveWasClicked(); + // simply close the dialog + this->accept(); +} + + + +#include "freeverbsetupimpl.moc" diff --git a/ksayit/Freeverb_plugin/freeverbsetupimpl.h b/ksayit/Freeverb_plugin/freeverbsetupimpl.h new file mode 100644 index 0000000..8bee5bb --- /dev/null +++ b/ksayit/Freeverb_plugin/freeverbsetupimpl.h @@ -0,0 +1,62 @@ +/*************************************************************************** + freeverbsetupimpl.h - description + ------------------- + begin : Son Nov 2 2003 + copyright : (C) 2003 by Robert Vogl + email : voglrobe@saphir + ***************************************************************************/ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ + +#ifndef FREEVERBSETUPIMPL_H +#define FREEVERBSETUPIMPL_H + +// QT includes +#include <qwidget.h> + +// KDE includes +#include <kconfig.h> + +// App specific includes +#include <freeverb_setup.h> + +/** + *@author Robert Vogl + */ + +class FreeverbSetupImpl : public Freeverb_Setup { + Q_OBJECT +public: + FreeverbSetupImpl(QWidget *parent=0, const char *name=0, bool modal=true, KConfig *config=0); + ~FreeverbSetupImpl(); + +public slots: + /** saves the configuration */ + void saveWasClicked(); + +protected slots: + void sliderRoomChanged(int value); + void sliderDampChanged(int value); + void sliderWetChanged(int value); + void sliderDryChanged(int value); + void sliderWidthChanged(int value); + void slotOKwasClicked(); + +private: // Methods + void Init(); + + +private: + KConfig *m_config; + + +}; + +#endif diff --git a/ksayit/Freeverb_plugin/kdeexportfix.h b/ksayit/Freeverb_plugin/kdeexportfix.h new file mode 100644 index 0000000..172dd94 --- /dev/null +++ b/ksayit/Freeverb_plugin/kdeexportfix.h @@ -0,0 +1,22 @@ +/***************************************************** vim:set ts=4 sw=4 sts=4: + kdelibs < 3.3.2 had a bug in the KDE_EXPORT macro. This file fixes this + by undefining it. + ------------------- + Copyright : (C) 2005 by Gary Cramblitt <garycramblitt@comcast.net> + ------------------- + Original author: Gary Cramblitt <garycramblitt@comcast.net> + ******************************************************************************/ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; version 2 of the License. * + * * + ***************************************************************************/ + +#include <kdeversion.h> +#if KDE_VERSION < KDE_MAKE_VERSION (3,3,2) +#undef KDE_EXPORT +#define KDE_EXPORT +#endif diff --git a/ksayit/Freeverb_plugin/ksayit_libFreeverb.desktop b/ksayit/Freeverb_plugin/ksayit_libFreeverb.desktop new file mode 100644 index 0000000..410c23a --- /dev/null +++ b/ksayit/Freeverb_plugin/ksayit_libFreeverb.desktop @@ -0,0 +1,52 @@ +[Desktop Entry] +Name=Freeverb +Name[ne]=फ्रीभर्व +Name[vi]=Động từ tự do +Comment=A Freeverb Plugin for KSayIt +Comment[bg]=Приставка Freeverb за KTTSD +Comment[br]=Lugent Freeverb evit KSayIt +Comment[ca]=Un connector de Freeverb pel KSayit +Comment[cs]=Freeverb modul pro KSayIt +Comment[da]=Et Freeverb plugin for KSayIt +Comment[de]=Ein Freeverb-Modul für KSayIt +Comment[el]=Ένα πρόσθετο Freeverb για το KTTSD +Comment[es]=Complemento Freeverb para KSayIt +Comment[et]=KSayIt'i Freeverbi plugin +Comment[eu]=KSayIt-en Freeverb plugina +Comment[fa]=وصلۀ Freever برای KSaylt +Comment[fi]=Freeverb-liitännäinen KSayIt--ohjelmalle +Comment[fr]=Un module Freeverb pour KSayIt +Comment[ga]=Breiseán Freeverb le haghaidh KSayIt +Comment[gl]=Un Plugin de Freeverb para KSayIt +Comment[he]=תוסף Freeverb עבור KSayIt +Comment[hu]=Freeverb modul a KSayIt programhoz +Comment[is]=Freeverb íforrit fyrir KSayIt +Comment[it]=Un plugin per Freeverb per KTTSD +Comment[ja]=KSayIt 用 Freeverb プラグイン +Comment[ka]=KSayIt Freeverb მოდული +Comment[km]= កម្មវិធីជំនួយ Freeverb សម្រាប់ KSayIt +Comment[lt]=Freeverb priedas skirtas KSayIt +Comment[mk]=Freeverb-приклучок за Ksaylt +Comment[nb]=Et Freeverb programtillegg for KSayIt +Comment[nds]=En Freeverb-Moduul för KSayIt +Comment[ne]=के से इटका लागि एउटा फ्रिभर्व प्लगइन +Comment[nl]=Een Freeverb-plugin vor KSayIt +Comment[pa]=KSayIt ਲਈ ਮੁਕਤ-ਵਰਬ ਪਲੱਗਿੰਨ +Comment[pl]=Wtyczka Freeverb dla KSayIt +Comment[pt]='Plugin' de Reverberação para o KTTSD +Comment[pt_BR]=Plug-in do Freeverb para o KSayIt +Comment[ru]=Модуль Freeverb для KSayIt +Comment[sk]=Modul Freeverb pre PovedzTo +Comment[sl]=Vstavek Freeverb za KSayIt +Comment[sr]=Freeverb прикључак за KSayIt +Comment[sr@Latn]=Freeverb priključak za KSayIt +Comment[sv]=Freeverb-insticksprogram för Ksayit +Comment[tg]=Модули Freeverb барои KSayIt +Comment[tr]=Ksayit için Freeverb Eklentisi +Comment[uk]=Втулок Freeverb для KSayIt +Comment[vi]=Trình bổ sung "Động từ tự do" cho "Nói K" +Comment[zh_CN]=KSayIt 的 Freeverb 插件 +Comment[zh_TW]=KSayIt 的 Freeverb 外掛程式 +ServiceTypes=KSayIt/FXPlugin +Type=Service +X-KDE-Library=libFreeverb_plugin diff --git a/ksayit/Freeverb_plugin/ksayit_libFreeverb_service.desktop b/ksayit/Freeverb_plugin/ksayit_libFreeverb_service.desktop new file mode 100644 index 0000000..dbb02d7 --- /dev/null +++ b/ksayit/Freeverb_plugin/ksayit_libFreeverb_service.desktop @@ -0,0 +1,48 @@ +[Desktop Entry] +Type=ServiceType +X-KDE-ServiceType=KSayIt/FXPlugin +Comment=A Freeverb Plugin for KSayIt +Comment[bg]=Приставка Freeverb за KTTSD +Comment[br]=Lugent Freeverb evit KSayIt +Comment[ca]=Un connector de Freeverb pel KSayit +Comment[cs]=Freeverb modul pro KSayIt +Comment[da]=Et Freeverb plugin for KSayIt +Comment[de]=Ein Freeverb-Modul für KSayIt +Comment[el]=Ένα πρόσθετο Freeverb για το KTTSD +Comment[es]=Complemento Freeverb para KSayIt +Comment[et]=KSayIt'i Freeverbi plugin +Comment[eu]=KSayIt-en Freeverb plugina +Comment[fa]=وصلۀ Freever برای KSaylt +Comment[fi]=Freeverb-liitännäinen KSayIt--ohjelmalle +Comment[fr]=Un module Freeverb pour KSayIt +Comment[ga]=Breiseán Freeverb le haghaidh KSayIt +Comment[gl]=Un Plugin de Freeverb para KSayIt +Comment[he]=תוסף Freeverb עבור KSayIt +Comment[hu]=Freeverb modul a KSayIt programhoz +Comment[is]=Freeverb íforrit fyrir KSayIt +Comment[it]=Un plugin per Freeverb per KTTSD +Comment[ja]=KSayIt 用 Freeverb プラグイン +Comment[ka]=KSayIt Freeverb მოდული +Comment[km]= កម្មវិធីជំនួយ Freeverb សម្រាប់ KSayIt +Comment[lt]=Freeverb priedas skirtas KSayIt +Comment[mk]=Freeverb-приклучок за Ksaylt +Comment[nb]=Et Freeverb programtillegg for KSayIt +Comment[nds]=En Freeverb-Moduul för KSayIt +Comment[ne]=के से इटका लागि एउटा फ्रिभर्व प्लगइन +Comment[nl]=Een Freeverb-plugin vor KSayIt +Comment[pa]=KSayIt ਲਈ ਮੁਕਤ-ਵਰਬ ਪਲੱਗਿੰਨ +Comment[pl]=Wtyczka Freeverb dla KSayIt +Comment[pt]='Plugin' de Reverberação para o KTTSD +Comment[pt_BR]=Plug-in do Freeverb para o KSayIt +Comment[ru]=Модуль Freeverb для KSayIt +Comment[sk]=Modul Freeverb pre PovedzTo +Comment[sl]=Vstavek Freeverb za KSayIt +Comment[sr]=Freeverb прикључак за KSayIt +Comment[sr@Latn]=Freeverb priključak za KSayIt +Comment[sv]=Freeverb-insticksprogram för Ksayit +Comment[tg]=Модули Freeverb барои KSayIt +Comment[tr]=Ksayit için Freeverb Eklentisi +Comment[uk]=Втулок Freeverb для KSayIt +Comment[vi]=Trình bổ sung "Động từ tự do" cho "Nói K" +Comment[zh_CN]=KSayIt 的 Freeverb 插件 +Comment[zh_TW]=KSayIt 的 Freeverb 外掛程式 diff --git a/ksayit/Freeverb_plugin/ksayitfreeverblib.cpp b/ksayit/Freeverb_plugin/ksayitfreeverblib.cpp new file mode 100644 index 0000000..1edf874 --- /dev/null +++ b/ksayit/Freeverb_plugin/ksayitfreeverblib.cpp @@ -0,0 +1,164 @@ +// +// C++ Implementation: KSayItFXPlugin +// +// Description: +// +// +// Author: Robert Vogl <voglrobe@lapislazuli>, (C) 2004 +// +// Copyright: See COPYING file that comes with this distribution +// +// + +// QT includes +// #include <qtextcodec.h> +#include <qstringlist.h> + +// KDE includes +#include <kdebug.h> +#include <klocale.h> +#include <kdemacros.h> +#include <arts/artsmodules.h> + +// App specific includes +#include "ksayitfreeverblib.h" +#include "freeverbsetupimpl.h" + + +// The class factory +K_EXPORT_COMPONENT_FACTORY( libFreeverb_plugin, FreeverbPluginFactory ) +/** replaced by macro +extern "C" +{ + void* init_libFreeverb_plugin() + { + return new FreeverbPluginFactory; + } +}; +*/ + +KInstance *FreeverbPluginFactory::p_instance = 0L; + + +// Factory Constructor +FreeverbPluginFactory::FreeverbPluginFactory(QObject *parent, const char* name) +{ + p_instance = new KInstance("FreeverbPluginFactory"); +} + + +QObject* FreeverbPluginFactory::createObject(QObject *parent, const char* name, + const char*, + const QStringList &) +{ + kdDebug(100200) << "FreeverbPluginFactory::createObject()" << endl; + + QObject* obj = new FreeverbPlugin( parent, name ); + emit objectCreated( obj ); + return obj; +} + + + + +// Plugin Constructor +FreeverbPlugin::FreeverbPlugin(QObject *parent, const char* name) //, KApplication *Appl) + : FXPlugin(parent, name) //, m_Appl(Appl) +{ + m_config = new KSimpleConfig("ksayit_freeverbrc"); + +} + +FreeverbPlugin::~FreeverbPlugin() +{ + delete m_config; +} + +/** sets the Main application object +*/ +void FreeverbPlugin::setApplication(KApplication *Appl) +{ + m_Appl = Appl; +} + + +/** returns the Name of the Plugin +*/ +QString FreeverbPlugin::getName_KS() const +{ + return "Synth_FREEVERB"; +} + +/** returns a description of the plugin +*/ +QString FreeverbPlugin::getDescription_KS() const +{ + return i18n("This is a freeverb effect."); +} + +/** shows the GUI to configure the plugin +*/ +bool FreeverbPlugin::showGUI_KS() +{ + FreeverbSetupImpl *dlg = new FreeverbSetupImpl(0, "Freeverb", true, m_config); + if ( !dlg ){ + delete dlg; + return false; + } + dlg->exec(); + delete dlg; + + return true; +} + +/** activate the effect +*/ +long FreeverbPlugin::activate_KS(KArtsServer *server, + StereoEffectStack *fx_stack) const +{ + // kdDebug(100200) << "Aktiviere Synth_FREEVERB-Effekt" << endl; + Synth_FREEVERB fv = DynamicCast( server->server().createObject("Arts::Synth_FREEVERB") ); + if ( !fv.isNull() ){ + // kdDebug(100200) << "Filter angelegt" << endl; + // get filter parameter + m_config->setGroup("Synth_FREEVERB"); + fv.roomsize( m_config->readDoubleNumEntry("roomsize", 50.0)/100.0 ); + fv.damp ( m_config->readDoubleNumEntry("damp", 50.0 )/100.0 ); + fv.wet ( m_config->readDoubleNumEntry("wet", 50.0 )/100.0 ); + fv.dry ( m_config->readDoubleNumEntry("dry", 50.0 )/100.0 ); + fv.width ( m_config->readDoubleNumEntry("width", 50.0 )/100.0 ); + + fv.start(); + return fx_stack->insertBottom( fv, "Freeverb" ); + } + return 0; +} + +/** deactivates the effect +*/ +bool FreeverbPlugin::deactivate_KS(StereoEffectStack *fx_stack, + long EffectID ) const +{ + // kdDebug(100200) << "Deaktiviere Synth_FREEVERB-Effekt" << endl; + if (EffectID!=0){ + fx_stack->remove(EffectID); + } + return true; +} + + + + + + + + + + + + + + + + +#include "ksayitfreeverblib.moc" diff --git a/ksayit/Freeverb_plugin/ksayitfreeverblib.h b/ksayit/Freeverb_plugin/ksayitfreeverblib.h new file mode 100644 index 0000000..50bfa62 --- /dev/null +++ b/ksayit/Freeverb_plugin/ksayitfreeverblib.h @@ -0,0 +1,96 @@ +// +// C++ Interface: ksayitfreeverblib +// +// Description: +// +// +// Author: Robert Vogl <voglrobe@lapislazuli>, (C) 2004 +// +// Copyright: See COPYING file that comes with this distribution +// +// +#ifndef KSAYITFREEVERBLIB_H +#define KSAYITFREEVERBLIB_H + +// QT includes +#include <qobject.h> +#include <qstringlist.h> + +// KDE includes +#include <ksimpleconfig.h> +#include <kapplication.h> +#include <klibloader.h> +#include <kinstance.h> + +#include "ksayit_fxplugin.h" + +class FreeverbPluginFactory : public KLibFactory +{ +Q_OBJECT +public: + // Consturctor + FreeverbPluginFactory(QObject *parent=0, const char* name=0); + + // Destructor + virtual ~FreeverbPluginFactory(){ delete p_instance; }; + + QObject* createObject(QObject *parent=0, const char* name=0, + const char* className="QObject", + const QStringList &args=QStringList()); + +private: + static KInstance* p_instance; + +}; + + + + + +class FreeverbPlugin : public FXPlugin +{ +Q_OBJECT +public: + // Constructor + FreeverbPlugin(QObject *parent=0, const char* name=0); //, KApplication *Appl=0); + + // Destructor + ~FreeverbPlugin(); + + /** sets the Main application object + */ + void setApplication(KApplication *Appl); + + /** returns the Name of the Plugin + */ + QString getName_KS() const; + + /** returns a description of the plugin + */ + QString getDescription_KS() const; + + /** shows the GUI to configure the plugin + */ + bool showGUI_KS(); + + /** activate the effect + */ + long activate_KS(KArtsServer *server, + StereoEffectStack *fx_stack) const; + + /** deactivates the effect + */ + bool deactivate_KS(StereoEffectStack *fx_stack, + long EffectID ) const; + + +private: + KApplication *m_Appl; + KSimpleConfig *m_config; + +}; + + + +#endif + |