mirror of
https://github.com/vale981/openAV-Luppp
synced 2025-03-05 09:01:39 -05:00
-Added error checking in Jack, added config #define DEBUG_TRACKS
This commit is contained in:
parent
e72fc9dd44
commit
294610e87d
4 changed files with 47 additions and 8 deletions
2
TODO
2
TODO
|
@ -1,5 +1,7 @@
|
|||
|
||||
=== NEW
|
||||
-Update SIDE control to blue button
|
||||
-Add track recordArm functionality to record over loaded loops
|
||||
|
||||
- Remove TimeObserver obligation from Looper, not needed as GridLogic handles Time now
|
||||
|
||||
|
|
|
@ -3,13 +3,16 @@
|
|||
#define LUPPP_CONFIG_H
|
||||
|
||||
/// DEBUG OPTIONS
|
||||
// Track operations
|
||||
#define DEBUG_TRACKS 1
|
||||
|
||||
// Clip selection / queueing
|
||||
#define DEBUG_CLIP 1
|
||||
|
||||
// Buffer loading / resizing
|
||||
#define DEBUG_BUFFER 1
|
||||
|
||||
|
||||
|
||||
/// General Options
|
||||
#define NTRACKS 8
|
||||
#define NSCENES 10
|
||||
|
|
36
src/jack.cxx
36
src/jack.cxx
|
@ -144,6 +144,42 @@ void Jack::activate()
|
|||
}
|
||||
|
||||
|
||||
TrackOutput* Jack::getTrackOutput(int t)
|
||||
{
|
||||
if ( t >= 0 && t < NTRACKS )
|
||||
return trackOutputs.at(t);
|
||||
#ifdef DEBUG_TRACKS
|
||||
else
|
||||
{
|
||||
printf( "Jack::getTrackOutput() returning 0x0: invalid track requested!\n" );
|
||||
}
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Looper* Jack::getLooper(int t)
|
||||
{
|
||||
if ( t >= 0 && t < NTRACKS )
|
||||
return loopers.at(t);
|
||||
#ifdef DEBUG_TRACKS
|
||||
else
|
||||
{
|
||||
printf( "Jack::getLooper() returning 0x0: invalid track requested!\n" );
|
||||
}
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
void Jack::registerMidiObserver( MidiObserver* mo )
|
||||
{
|
||||
midiObservers.push_back( mo );
|
||||
}
|
||||
|
||||
|
||||
int Jack::process (jack_nframes_t nframes)
|
||||
{
|
||||
|
||||
|
|
12
src/jack.hxx
12
src/jack.hxx
|
@ -38,20 +38,18 @@ class Jack
|
|||
int getSamplerate();
|
||||
|
||||
/// get functions for components owned by Jack
|
||||
Looper* getLooper(int t) {return loopers.at(t); }
|
||||
Metronome* getMetronome(){return metronome;}
|
||||
Looper* getLooper(int t);
|
||||
TrackOutput* getTrackOutput(int t);
|
||||
|
||||
Logic* getLogic(){return logic;}
|
||||
Metronome* getMetronome(){return metronome;}
|
||||
GridLogic* getGridLogic(){return gridLogic;}
|
||||
TrackOutput* getTrackOutput(int t){return trackOutputs.at(t);}
|
||||
TimeManager* getTimeManager(){return &timeManager;}
|
||||
ControllerUpdater* getControllerUpdater(){return controllerUpdater;}
|
||||
|
||||
/// register MIDI observers: they're called when a MIDI message arrives on
|
||||
/// a port they're watching
|
||||
void registerMidiObserver( MidiObserver* mo )
|
||||
{
|
||||
midiObservers.push_back( mo );
|
||||
}
|
||||
void registerMidiObserver( MidiObserver* mo );
|
||||
|
||||
void masterVolume( float vol ){masterVol = vol;}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue