/[svn]/linuxsampler/trunk/src/engines/sfz/Engine.h
ViewVC logotype

Contents of /linuxsampler/trunk/src/engines/sfz/Engine.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2500 - (show annotations) (download) (as text)
Fri Jan 10 12:20:05 2014 UTC (10 years, 3 months ago) by schoenebeck
File MIME type: text/x-c++hdr
File size: 4051 byte(s)
* Added support for multiple MIDI input ports per sampler channel (added
  various new C++ API methods for this new feature/design, old C++ API
  methods are now marked as deprecated but should still provide full
  behavior backward compatibility).
* LSCP Network interface: Added the following new LSCP commands for the new
  feature mentioned above: "ADD CHANNEL MIDI_INPUT",
  "REMOVE CHANNEL MIDI_INPUT" and "LIST CHANNEL MIDI_INPUTS". As with the
  C++ API changes, the old LSCP commands for MIDI input management are now
  marked as deprecated, but are still there and should provide full behavior
  backward compatibility.
* New LSCP specification document (LSCP v1.6).
* AbstractEngine::GSCheckSum(): don't allocate memory on the stack (was
  unsafe and caused compilation error with old clang 2.x).
* Bumped version (1.0.0.svn25).

1 /***************************************************************************
2 * *
3 * LinuxSampler - modular, streaming capable sampler *
4 * *
5 * Copyright (C) 2003,2004 by Benno Senoner and Christian Schoenebeck *
6 * Copyright (C) 2005-2009 Christian Schoenebeck *
7 * Copyright (C) 2009-2010 Grigor Iliev *
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 * This program is distributed in the hope that it will be useful, *
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
17 * GNU General Public License for more details. *
18 * *
19 * You should have received a copy of the GNU General Public License *
20 * along with this program; if not, write to the Free Software *
21 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, *
22 * MA 02111-1307 USA *
23 ***************************************************************************/
24
25 #ifndef __LS_SFZ_ENGINE_H__
26 #define __LS_SFZ_ENGINE_H__
27
28 #include "DiskThread.h"
29 #include "../EngineBase.h"
30 #include "Voice.h"
31 #include "sfz.h"
32 #include "EngineChannel.h" // prevents compile errors with clang 2.x
33
34 namespace LinuxSampler { namespace sfz {
35 const int MaxCCPerVoice = 128; // FIXME: too much?
36
37 class Engine: public LinuxSampler::EngineBase<Voice, ::sfz::Region, ::sfz::Region, DiskThread, InstrumentResourceManager, ::sfz::Instrument> {
38 public:
39 Engine();
40 virtual ~Engine();
41 // implementation of abstract methods derived from class 'LinuxSampler::Engine'
42 virtual bool DiskStreamSupported();
43 virtual String Description();
44 virtual String Version();
45
46 virtual Format GetEngineFormat();
47
48 virtual void ProcessControlChange (
49 LinuxSampler::EngineChannel* pEngineChannel,
50 Pool<Event>::Iterator& itControlChangeEvent
51 );
52
53 virtual void PostSetMaxVoices(int iVoices);
54
55 friend class Voice;
56 friend class SfzSignalUnitRack;
57
58 protected:
59 Pool<CCSignalUnit::CC>* pCCPool;
60 Pool<Smoother>* pSmootherPool;
61
62 virtual DiskThread* CreateDiskThread();
63
64 virtual Pool<Voice>::Iterator LaunchVoice (
65 LinuxSampler::EngineChannel* pEngineChannel,
66 Pool<Event>::Iterator& itNoteOnEvent,
67 int iLayer,
68 bool ReleaseTriggerVoice,
69 bool VoiceStealing,
70 bool HandleKeyGroupConflicts
71 );
72
73 virtual void TriggerNewVoices (
74 LinuxSampler::EngineChannel* pEngineChannel,
75 RTList<Event>::Iterator& itNoteOnEvent,
76 bool HandleKeyGroupConflicts
77 );
78
79 void TriggerReleaseVoices (
80 LinuxSampler::EngineChannel* pEngineChannel,
81 RTList<Event>::Iterator& itNoteOffEvent
82 );
83 };
84
85 }} // namespace LinuxSampler::sfz
86
87 #endif /* __LS_SFZ_ENGINE_H__ */
88

  ViewVC Help
Powered by ViewVC