All Classes Namespaces Functions Variables Enumerations Enumerator Modules Pages
Public Member Functions | Protected Member Functions | List of all members
SampleRaster Class Reference
Inheritance diagram for SampleRaster:
MidiProcessor Processor SafeChangeBroadcaster RestorableObject ControlledObject

Public Member Functions

 SampleRaster (MainController *mc, const String &id)
 
void setRaster (int newStepSize) noexcept
 
- Public Member Functions inherited from MidiProcessor
 MidiProcessor (MainController *m, const String &id)
 
virtual ProcessorgetChildProcessor (int) override
 
virtual int getNumChildProcessors () const override
 
virtual ProcessorEditorBodycreateEditor (ProcessorEditor *parentEditor) override
 
void ignoreEvent ()
 
- Public Member Functions inherited from Processor
 Processor (MainController *m, const String &id_)
 
virtual ~Processor ()
 
virtual ValueTree exportAsValueTree () const override
 
virtual void restoreFromValueTree (const ValueTree &previouslyExportedProcessorState) override
 
virtual const Identifier getType () const =0
 
const Path getSymbol () const
 
void setSymbol (Path newSymbol)
 
void setAttribute (int parameterIndex, float newValue, juce::NotificationType notifyEditor)
 
virtual float getDefaultValue (int) const
 
virtual int getNumInternalChains () const
 
void enableConsoleOutput (bool shouldBeEnabled)
 
const String & getId () const
 
virtual const String getName () const
 
virtual void setBypassed (bool shouldBeBypassed, NotificationType notifyChangeHandler=dontSendNotification) noexcept
 
bool isBypassed () const noexcept
 
virtual void prepareToPlay (double sampleRate_, int samplesPerBlock_)
 
double getSampleRate () const
 
int getBlockSize () const
 
float getOutputValue () const
 
float getInputValue () const
 
void setEditorState (int state, bool isOn, NotificationType notifyView=sendNotification)
 
bool getEditorState (int state) const
 
void restoreCompleteEditorState (const XmlElement *storedState)
 
const Identifier getIdentifierForParameterIndex (int parameterIndex) const
 
int getNumParameters () const
 
void setIsOnAir (bool isBeingProcessedInAudioThread)
 
const CriticalSection & getDummyLockWhenNotOnAir () const
 
- Public Member Functions inherited from SafeChangeBroadcaster
void sendSynchronousChangeMessage ()
 
void addChangeListener (SafeChangeListener *listener)
 
void removeChangeListener (SafeChangeListener *listener)
 
void removeAllChangeListeners ()
 
void sendChangeMessage (const String &=String())
 
void sendAllocationFreeChangeMessage ()
 
- Public Member Functions inherited from ControlledObject
 ControlledObject (MainController *m)
 
const MainControllergetMainController () const noexcept
 
MainControllergetMainController () noexcept
 

Protected Member Functions

void processHiseEvent (HiseEvent &m) override
 
- Protected Member Functions inherited from Processor
void setOutputValue (float newValue)
 
void setInputValue (float newValue, NotificationType notify=sendNotification)
 

Additional Inherited Members

- Public Types inherited from Processor
enum  SpecialParameters
 
enum  InternalChains
 
- Protected Attributes inherited from MidiProcessor
int samplePos
 

Detailed Description

The SampleRaster is a small utility processor that quantisizes timestamps of midi data to a specific step size.

If a midi message has the timestamp '15', and the step size is 4, the new timestamp will be '12'.

This allows assumptions about buffersizes for later calculations (which can be useful for eg. SIMD acceleration).

Constructor & Destructor Documentation

SampleRaster ( MainController mc,
const String &  id 
)
inline

Creates a SampleRaster. The initial step size is 4.

Member Function Documentation

void processHiseEvent ( HiseEvent m)
inlineoverrideprotectedvirtual

Applies the raster to the timestamp.

Implements MidiProcessor.

void setRaster ( int  newStepSize)
inlinenoexcept

This sets the quantisation size. It is supposed to be a power of two and smaller than the buffer size.

©2017 HISE. This documentation is autogenerated from the HISE source code using Doxygen.