• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • libtdemid
 

libtdemid

  • libtdemid
gusout.h
1/* gusout.h - class gusOut which implements support for Gravis
2 Ultrasound cards through a /dev/sequencer device
3 This file is part of LibKMid 0.9.5
4 Copyright (C) 1998,99,2000 Antonio Larrosa Jimenez
5 LibKMid's homepage : http://www.arrakis.es/~rlarrosa/libtdemid.html
6
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with this library; see the file COPYING.LIB. If not, write to
19 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21
22 Send comments and bug fixes to Antonio Larrosa <larrosa@kde.org>
23
24***************************************************************************/
25#ifndef _GUSOUT_H
26#define _GUSOUT_H
27
28#include <libtdemid/midiout.h>
29#include <libtdemid/voiceman.h>
30
45class GUSOut : public MidiOut
46{
47 private:
48 class GUSOutPrivate;
49 GUSOutPrivate *di;
50
51 int patchloaded[256];
52 int nvoices;
53
54 int use8bit; // Use 8 bit patches, instead of 16 bits to use less memory
55 VoiceManager *vm;
56
57 int totalmemory; // Total memory in soundcard
58 int freememory; // Free memory
59
60
61 void patchesLoadingOrder(int *patchesused,int *patchesordered);
62 const char *patchName(int pgm);
63
64 public:
68 GUSOut(int d=0,int total =12);
69
73 ~GUSOut();
74
78 virtual void openDev (int sqfd);
79
83 virtual void closeDev (void);
84
88 virtual void initDev (void);
89
93 virtual void noteOn ( uchar chn, uchar note, uchar vel );
94
98 virtual void noteOff ( uchar chn, uchar note, uchar vel );
99
103 virtual void keyPressure ( uchar chn, uchar note, uchar vel );
104
108 virtual void chnPatchChange ( uchar chn, uchar patch );
109
113 virtual void chnPressure ( uchar chn, uchar vel );
114
118 virtual void chnPitchBender ( uchar chn, uchar lsb, uchar msb );
119
123 virtual void chnController ( uchar chn, uchar ctl , uchar v );
124
129 virtual void sysex ( uchar *data,ulong size);
130
140 void setPatchesToUse(int *patchesused);
141
152 int loadPatch (int pgm);
153
162 int patch(int p);
163
164 private:
165 static const char *GUS_patches_directory;
166 static int delete_GUS_patches_directory;
167
168 public:
176 static void setGUSPatchesDirectory(const char *dir);
177
178};
179
180#endif
GUSOut
Gravis Ultrasound synthesizer output class .
Definition: gusout.h:46
GUSOut::openDev
virtual void openDev(int sqfd)
See MidiOut::openDev()
Definition: gusout.cpp:137
GUSOut::noteOff
virtual void noteOff(uchar chn, uchar note, uchar vel)
See MidiOut::noteOff()
Definition: gusout.cpp:247
GUSOut::setGUSPatchesDirectory
static void setGUSPatchesDirectory(const char *dir)
Sets the directory where the GUS patches are stored, that is, where the acpiano.pat,...
Definition: gusout.cpp:322
GUSOut::noteOn
virtual void noteOn(uchar chn, uchar note, uchar vel)
See MidiOut::noteOn()
Definition: gusout.cpp:217
GUSOut::chnController
virtual void chnController(uchar chn, uchar ctl, uchar v)
See MidiOut::chnController()
Definition: gusout.cpp:301
GUSOut::keyPressure
virtual void keyPressure(uchar chn, uchar note, uchar vel)
See MidiOut::keyPressure()
Definition: gusout.cpp:262
GUSOut::patch
int patch(int p)
Returns p if the patch with number p has been correctly loaded.
Definition: gusout.cpp:208
GUSOut::loadPatch
int loadPatch(int pgm)
Loads a single patch on the synthesizer memory.
Definition: gusout.cpp:338
GUSOut::~GUSOut
~GUSOut()
Destructor.
Definition: gusout.cpp:124
GUSOut::chnPressure
virtual void chnPressure(uchar chn, uchar vel)
See MidiOut::chnPressure()
Definition: gusout.cpp:281
GUSOut::initDev
virtual void initDev(void)
See MidiOut::initDev()
Definition: gusout.cpp:178
GUSOut::setPatchesToUse
void setPatchesToUse(int *patchesused)
See DeviceManager::setPatchesToUse() .
Definition: gusout.cpp:525
GUSOut::closeDev
virtual void closeDev(void)
See MidiOut::closeDev()
Definition: gusout.cpp:169
GUSOut::chnPatchChange
virtual void chnPatchChange(uchar chn, uchar patch)
See MidiOut::chnPatchChange()
Definition: gusout.cpp:270
GUSOut::GUSOut
GUSOut(int d=0, int total=12)
Constructor.
Definition: gusout.cpp:112
GUSOut::chnPitchBender
virtual void chnPitchBender(uchar chn, uchar lsb, uchar msb)
See MidiOut::chnPitchBender()
Definition: gusout.cpp:291
GUSOut::sysex
virtual void sysex(uchar *data, ulong size)
It's an empty function, as GUS synths don't support System Exclusive messages.
Definition: gusout.cpp:317
MidiOut
External MIDI port output class .
Definition: midiout.h:52

libtdemid

Skip menu "libtdemid"
  • Main Page
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

libtdemid

Skip menu "libtdemid"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for libtdemid by doxygen 1.9.4
This website is maintained by Timothy Pearson.