Cog/Plugins/MIDI/MIDI/MIDIDecoder.h
Christopher Snowhill 9480bc742c MIDI: Move sample buffer from stack to class
Move the stack-based buffer, which is rather large, to the player class
instance, where it will be allocated on the heap.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2025-03-28 16:17:56 -07:00

43 lines
660 B
Objective-C

//
// MIDIDecoder.h
// MIDI
//
// Created by Christopher Snowhill on 10/15/13.
// Copyright 2013 __NoWork, Inc__. All rights reserved.
//
#import <Cocoa/Cocoa.h>
#import "MIDIPlayer.h"
#import "Plugin.h"
class AUPlayer;
class BMPlayer;
@interface MIDIDecoder : NSObject <CogDecoder> {
id<CogSource> source;
int track_num;
BMPlayer* bmplayer;
AUPlayer* auplayer;
MIDIPlayer* player;
midi_container midi_file;
const void* sbHandle;
NSString* globalSoundFontPath;
BOOL soundFontsAssigned;
BOOL isLooped;
double sampleRate;
long totalFrames;
long framesLength;
long framesFade;
long framesRead;
float outputBuffer[1024 * 2];
}
@end