@@ -128,13 +128,12 @@ public: | |||||
else if (arg.isBlob()) | else if (arg.isBlob()) | ||||
{ | { | ||||
typeAsString = "blob"; | typeAsString = "blob"; | ||||
const MemoryBlock& blob = arg.getBlob(); | |||||
valueAsString = String::fromUTF8( (const char*)blob.getData(), blob.getSize()); | |||||
auto& blob = arg.getBlob(); | |||||
valueAsString = String::fromUTF8 ((const char*) blob.getData(), (int) blob.getSize()); | |||||
} | } | ||||
else | else | ||||
{ | { | ||||
typeAsString = "(unknown)"; | typeAsString = "(unknown)"; | ||||
valueAsString = ""; | |||||
} | } | ||||
oscLogList.add (getIndentationString (level + 1) + "- " + typeAsString.paddedRight(' ', 12) + valueAsString); | oscLogList.add (getIndentationString (level + 1) + "- " + typeAsString.paddedRight(' ', 12) + valueAsString); | ||||
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -151,3 +151,5 @@ public: | |||||
/** Rewinds the audio. */ | /** Rewinds the audio. */ | ||||
virtual void transportRewind() {} | virtual void transportRewind() {} | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
AudioChannelSet::AudioChannelSet (uint32 c) : channels (c) {} | AudioChannelSet::AudioChannelSet (uint32 c) : channels (c) {} | ||||
AudioChannelSet::AudioChannelSet (const Array<ChannelType>& c) | AudioChannelSet::AudioChannelSet (const Array<ChannelType>& c) | ||||
{ | { | ||||
@@ -414,3 +417,5 @@ int32 AudioChannelSet::getWaveChannelMask() const noexcept | |||||
return (channels.toInteger() >> 1); | return (channels.toInteger() >> 1); | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -388,3 +388,5 @@ private: | |||||
explicit AudioChannelSet (uint32); | explicit AudioChannelSet (uint32); | ||||
explicit AudioChannelSet (const Array<ChannelType>&); | explicit AudioChannelSet (const Array<ChannelType>&); | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
void AudioDataConverters::convertFloatToInt16LE (const float* source, void* dest, int numSamples, const int destBytesPerSample) | void AudioDataConverters::convertFloatToInt16LE (const float* source, void* dest, int numSamples, const int destBytesPerSample) | ||||
{ | { | ||||
const double maxVal = (double) 0x7fff; | const double maxVal = (double) 0x7fff; | ||||
@@ -596,3 +599,5 @@ public: | |||||
static AudioConversionTests audioConversionUnitTests; | static AudioConversionTests audioConversionUnitTests; | ||||
#endif | #endif | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -708,3 +708,5 @@ private: | |||||
AudioDataConverters(); | AudioDataConverters(); | ||||
JUCE_DECLARE_NON_COPYABLE (AudioDataConverters) | JUCE_DECLARE_NON_COPYABLE (AudioDataConverters) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -1122,3 +1122,5 @@ private: | |||||
@see AudioBuffer | @see AudioBuffer | ||||
*/ | */ | ||||
typedef AudioBuffer<float> AudioSampleBuffer; | typedef AudioBuffer<float> AudioSampleBuffer; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace FloatVectorHelpers | namespace FloatVectorHelpers | ||||
{ | { | ||||
#define JUCE_INCREMENT_SRC_DEST dest += (16 / sizeof (*dest)); src += (16 / sizeof (*dest)); | #define JUCE_INCREMENT_SRC_DEST dest += (16 / sizeof (*dest)); src += (16 / sizeof (*dest)); | ||||
@@ -1200,3 +1203,5 @@ public: | |||||
static FloatVectorOperationsTests vectorOpTests; | static FloatVectorOperationsTests vectorOpTests; | ||||
#endif | #endif | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
#if JUCE_INTEL | #if JUCE_INTEL | ||||
#define JUCE_SNAP_TO_ZERO(n) if (! (n < -1.0e-8f || n > 1.0e-8f)) n = 0; | #define JUCE_SNAP_TO_ZERO(n) if (! (n < -1.0e-8f || n > 1.0e-8f)) n = 0; | ||||
@@ -219,3 +220,5 @@ public: | |||||
*/ | */ | ||||
static void JUCE_CALLTYPE disableDenormalisedNumberSupport() noexcept; | static void JUCE_CALLTYPE disableDenormalisedNumberSupport() noexcept; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
struct CatmullRomAlgorithm | struct CatmullRomAlgorithm | ||||
{ | { | ||||
static forcedinline float valueAtOffset (const float* const inputs, const float offset) noexcept | static forcedinline float valueAtOffset (const float* const inputs, const float offset) noexcept | ||||
@@ -58,3 +61,5 @@ int CatmullRomInterpolator::processAdding (double actualRatio, const float* in, | |||||
{ | { | ||||
return interpolateAdding<CatmullRomAlgorithm> (lastInputSamples, subSamplePos, actualRatio, in, out, numOut, gain); | return interpolateAdding<CatmullRomAlgorithm> (lastInputSamples, subSamplePos, actualRatio, in, out, numOut, gain); | ||||
} | } | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
/** | /** | ||||
Interpolator for resampling a stream of floats using Catmull-Rom interpolation. | Interpolator for resampling a stream of floats using Catmull-Rom interpolation. | ||||
@@ -84,3 +87,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (CatmullRomInterpolator) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (CatmullRomInterpolator) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -96,3 +96,5 @@ private: | |||||
Decibels(); // This class can't be instantiated, it's just a holder for static methods.. | Decibels(); // This class can't be instantiated, it's just a holder for static methods.. | ||||
JUCE_DECLARE_NON_COPYABLE (Decibels) | JUCE_DECLARE_NON_COPYABLE (Decibels) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,7 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
//============================================================================== | |||||
namespace juce | |||||
{ | |||||
IIRCoefficients::IIRCoefficients() noexcept | IIRCoefficients::IIRCoefficients() noexcept | ||||
{ | { | ||||
zeromem (coefficients, sizeof (coefficients)); | zeromem (coefficients, sizeof (coefficients)); | ||||
@@ -335,3 +337,5 @@ void IIRFilter::processSamples (float* const samples, const int numSamples) noex | |||||
} | } | ||||
#undef JUCE_SNAP_TO_ZERO | #undef JUCE_SNAP_TO_ZERO | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
class IIRFilter; | class IIRFilter; | ||||
@@ -205,3 +206,5 @@ protected: | |||||
IIRFilter& operator= (const IIRFilter&); | IIRFilter& operator= (const IIRFilter&); | ||||
JUCE_LEAK_DETECTOR (IIRFilter) | JUCE_LEAK_DETECTOR (IIRFilter) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace | namespace | ||||
{ | { | ||||
static forcedinline void pushInterpolationSample (float* lastInputSamples, const float newValue) noexcept | static forcedinline void pushInterpolationSample (float* lastInputSamples, const float newValue) noexcept | ||||
@@ -196,3 +199,5 @@ int LagrangeInterpolator::processAdding (double actualRatio, const float* in, fl | |||||
{ | { | ||||
return interpolateAdding<LagrangeAlgorithm> (lastInputSamples, subSamplePos, actualRatio, in, out, numOut, gain); | return interpolateAdding<LagrangeAlgorithm> (lastInputSamples, subSamplePos, actualRatio, in, out, numOut, gain); | ||||
} | } | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
/** | /** | ||||
Interpolator for resampling a stream of floats using 4-point lagrange interpolation. | Interpolator for resampling a stream of floats using 4-point lagrange interpolation. | ||||
@@ -84,3 +87,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (LagrangeInterpolator) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (LagrangeInterpolator) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -182,3 +182,5 @@ private: | |||||
FloatType currentValue = 0, target = 0, step = 0; | FloatType currentValue = 0, target = 0, step = 0; | ||||
int countdown = 0, stepsToTarget = 0; | int countdown = 0, stepsToTarget = 0; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -316,3 +316,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Reverb) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Reverb) | ||||
}; | }; | ||||
} // namespace juce |
@@ -76,9 +76,6 @@ | |||||
#include <arm_neon.h> | #include <arm_neon.h> | ||||
#endif | #endif | ||||
namespace juce | |||||
{ | |||||
#include "buffers/juce_AudioDataConverters.cpp" | #include "buffers/juce_AudioDataConverters.cpp" | ||||
#include "buffers/juce_FloatVectorOperations.cpp" | #include "buffers/juce_FloatVectorOperations.cpp" | ||||
#include "buffers/juce_AudioChannelSet.cpp" | #include "buffers/juce_AudioChannelSet.cpp" | ||||
@@ -109,5 +106,3 @@ namespace juce | |||||
#include "sources/juce_ReverbAudioSource.cpp" | #include "sources/juce_ReverbAudioSource.cpp" | ||||
#include "sources/juce_ToneGeneratorAudioSource.cpp" | #include "sources/juce_ToneGeneratorAudioSource.cpp" | ||||
#include "synthesisers/juce_Synthesiser.cpp" | #include "synthesisers/juce_Synthesiser.cpp" | ||||
} |
@@ -51,9 +51,6 @@ | |||||
#include <juce_core/juce_core.h> | #include <juce_core/juce_core.h> | ||||
namespace juce | |||||
{ | |||||
#undef Complex // apparently some C libraries actually define these symbols (!) | #undef Complex // apparently some C libraries actually define these symbols (!) | ||||
#undef Factor | #undef Factor | ||||
@@ -94,5 +91,3 @@ namespace juce | |||||
#include "sources/juce_ToneGeneratorAudioSource.h" | #include "sources/juce_ToneGeneratorAudioSource.h" | ||||
#include "synthesisers/juce_Synthesiser.h" | #include "synthesisers/juce_Synthesiser.h" | ||||
#include "audio_play_head/juce_AudioPlayHead.h" | #include "audio_play_head/juce_AudioPlayHead.h" | ||||
} |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace MidiBufferHelpers | namespace MidiBufferHelpers | ||||
{ | { | ||||
inline int getEventTime (const void* const d) noexcept | inline int getEventTime (const void* const d) noexcept | ||||
@@ -225,3 +228,5 @@ bool MidiBuffer::Iterator::getNextEvent (MidiMessage& result, int& samplePositio | |||||
return true; | return true; | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -227,3 +227,5 @@ public: | |||||
private: | private: | ||||
JUCE_LEAK_DETECTOR (MidiBuffer) | JUCE_LEAK_DETECTOR (MidiBuffer) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace MidiFileHelpers | namespace MidiFileHelpers | ||||
{ | { | ||||
static void writeVariableLengthInt (OutputStream& out, unsigned int v) | static void writeVariableLengthInt (OutputStream& out, unsigned int v) | ||||
@@ -443,3 +446,5 @@ bool MidiFile::writeTrack (OutputStream& mainOut, const int trackNum) | |||||
return true; | return true; | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -178,3 +178,5 @@ private: | |||||
JUCE_LEAK_DETECTOR (MidiFile) | JUCE_LEAK_DETECTOR (MidiFile) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MidiKeyboardState::MidiKeyboardState() | MidiKeyboardState::MidiKeyboardState() | ||||
{ | { | ||||
zerostruct (noteStates); | zerostruct (noteStates); | ||||
@@ -179,3 +182,5 @@ void MidiKeyboardState::removeListener (MidiKeyboardStateListener* const listene | |||||
const ScopedLock sl (lock); | const ScopedLock sl (lock); | ||||
listeners.removeFirstMatchingValue (listener); | listeners.removeFirstMatchingValue (listener); | ||||
} | } | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
class MidiKeyboardState; | class MidiKeyboardState; | ||||
@@ -197,3 +198,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiKeyboardState) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiKeyboardState) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace MidiHelpers | namespace MidiHelpers | ||||
{ | { | ||||
inline uint8 initialByte (const int type, const int channel) noexcept | inline uint8 initialByte (const int type, const int channel) noexcept | ||||
@@ -1119,3 +1122,5 @@ const char* MidiMessage::getControllerName (const int n) | |||||
return isPositiveAndBelow (n, numElementsInArray (names)) ? names[n] : nullptr; | return isPositiveAndBelow (n, numElementsInArray (names)) ? names[n] : nullptr; | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -936,3 +936,5 @@ private: | |||||
inline uint8* getData() const noexcept { return isHeapAllocated() ? packedData.allocatedData : (uint8*) packedData.asBytes; } | inline uint8* getData() const noexcept { return isHeapAllocated() ? packedData.allocatedData : (uint8*) packedData.asBytes; } | ||||
uint8* allocateSpace (int); | uint8* allocateSpace (int); | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MidiMessageSequence::MidiEventHolder::MidiEventHolder (const MidiMessage& mm) : message (mm) {} | MidiMessageSequence::MidiEventHolder::MidiEventHolder (const MidiMessage& mm) : message (mm) {} | ||||
MidiMessageSequence::MidiEventHolder::MidiEventHolder (MidiMessage&& mm) : message (static_cast<MidiMessage&&> (mm)) {} | MidiMessageSequence::MidiEventHolder::MidiEventHolder (MidiMessage&& mm) : message (static_cast<MidiMessage&&> (mm)) {} | ||||
@@ -334,3 +336,5 @@ void MidiMessageSequence::createControllerUpdatesForTime (int channelNumber, dou | |||||
} | } | ||||
} | } | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -294,3 +294,5 @@ private: | |||||
JUCE_LEAK_DETECTOR (MidiMessageSequence) | JUCE_LEAK_DETECTOR (MidiMessageSequence) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MidiRPNDetector::MidiRPNDetector() noexcept | MidiRPNDetector::MidiRPNDetector() noexcept | ||||
{ | { | ||||
} | } | ||||
@@ -369,3 +372,5 @@ private: | |||||
static MidiRPNGeneratorTests MidiRPNGeneratorUnitTests; | static MidiRPNGeneratorTests MidiRPNGeneratorUnitTests; | ||||
#endif // JUCE_UNIT_TESTS | #endif // JUCE_UNIT_TESTS | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** Represents a MIDI RPN (registered parameter number) or NRPN (non-registered | /** Represents a MIDI RPN (registered parameter number) or NRPN (non-registered | ||||
@@ -144,3 +144,5 @@ public: | |||||
bool isNRPN = false, | bool isNRPN = false, | ||||
bool use14BitValue = true); | bool use14BitValue = true); | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace | namespace | ||||
{ | { | ||||
const uint8 noLSBValueReceived = 0xff; | const uint8 noLSBValueReceived = 0xff; | ||||
@@ -2148,3 +2151,5 @@ private: | |||||
static MPEInstrumentTests MPEInstrumentUnitTests; | static MPEInstrumentTests MPEInstrumentUnitTests; | ||||
#endif // JUCE_UNIT_TESTS | #endif // JUCE_UNIT_TESTS | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/* | /* | ||||
@@ -374,3 +374,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPEInstrument) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPEInstrument) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MidiBuffer MPEMessages::addZone (MPEZone zone) | MidiBuffer MPEMessages::addZone (MPEZone zone) | ||||
{ | { | ||||
MidiBuffer buffer (MidiRPNGenerator::generate (zone.getFirstNoteChannel(), | MidiBuffer buffer (MidiRPNGenerator::generate (zone.getFirstNoteChannel(), | ||||
@@ -193,3 +196,5 @@ private: | |||||
static MPEMessagesTests MPEMessagesUnitTests; | static MPEMessagesTests MPEMessagesUnitTests; | ||||
#endif // JUCE_UNIT_TESTS | #endif // JUCE_UNIT_TESTS | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -87,3 +87,5 @@ public: | |||||
*/ | */ | ||||
static const int zoneLayoutMessagesRpnNumber = 6; | static const int zoneLayoutMessagesRpnNumber = 6; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace | namespace | ||||
{ | { | ||||
uint16 generateNoteID (int midiChannel, int midiNoteNumber) noexcept | uint16 generateNoteID (int midiChannel, int midiNoteNumber) noexcept | ||||
@@ -128,3 +131,5 @@ private: | |||||
static MPENoteTests MPENoteUnitTests; | static MPENoteTests MPENoteUnitTests; | ||||
#endif // JUCE_UNIT_TESTS | #endif // JUCE_UNIT_TESTS | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -172,3 +172,5 @@ struct JUCE_API MPENote | |||||
/** Returns true if two notes are different notes, determined by their unique ID. */ | /** Returns true if two notes are different notes, determined by their unique ID. */ | ||||
bool operator!= (const MPENote& other) const noexcept; | bool operator!= (const MPENote& other) const noexcept; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MPESynthesiser::MPESynthesiser() | MPESynthesiser::MPESynthesiser() | ||||
{ | { | ||||
} | } | ||||
@@ -352,3 +355,5 @@ void MPESynthesiser::renderNextSubBlock (AudioBuffer<double>& buffer, int startS | |||||
voice->renderNextBlock (buffer, startSample, numSamples); | voice->renderNextBlock (buffer, startSample, numSamples); | ||||
} | } | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -305,3 +305,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPESynthesiser) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPESynthesiser) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MPESynthesiserBase::MPESynthesiserBase() | MPESynthesiserBase::MPESynthesiserBase() | ||||
: instrument (new MPEInstrument), | : instrument (new MPEInstrument), | ||||
sampleRate (0), | sampleRate (0), | ||||
@@ -178,3 +181,5 @@ void MPESynthesiserBase::setMinimumRenderingSubdivisionSize (int numSamples, boo | |||||
minimumSubBlockSize = numSamples; | minimumSubBlockSize = numSamples; | ||||
subBlockSubdivisionIsStrict = shouldBeStrict; | subBlockSubdivisionIsStrict = shouldBeStrict; | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -204,3 +204,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPESynthesiserBase) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPESynthesiserBase) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MPESynthesiserVoice::MPESynthesiserVoice() | MPESynthesiserVoice::MPESynthesiserVoice() | ||||
: currentSampleRate (0), noteStartTime (0) | : currentSampleRate (0), noteStartTime (0) | ||||
{ | { | ||||
@@ -49,3 +52,5 @@ void MPESynthesiserVoice::clearCurrentNote() noexcept | |||||
{ | { | ||||
currentlyPlayingNote = MPENote(); | currentlyPlayingNote = MPENote(); | ||||
} | } | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -183,3 +184,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPESynthesiserVoice) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MPESynthesiserVoice) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MPEValue::MPEValue() noexcept : normalisedValue (8192) | MPEValue::MPEValue() noexcept : normalisedValue (8192) | ||||
{ | { | ||||
} | } | ||||
@@ -166,3 +169,5 @@ private: | |||||
static MPEValueTests MPEValueUnitTests; | static MPEValueTests MPEValueUnitTests; | ||||
#endif // JUCE_UNIT_TESTS | #endif // JUCE_UNIT_TESTS | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -88,3 +88,5 @@ private: | |||||
MPEValue (int normalisedValue); | MPEValue (int normalisedValue); | ||||
int normalisedValue; | int normalisedValue; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace | namespace | ||||
{ | { | ||||
void checkAndLimitZoneParameters (int minValue, | void checkAndLimitZoneParameters (int minValue, | ||||
@@ -312,3 +315,5 @@ private: | |||||
static MPEZoneTests MPEZoneUnitTests; | static MPEZoneTests MPEZoneUnitTests; | ||||
#endif // JUCE_UNIT_TESTS | #endif // JUCE_UNIT_TESTS | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -138,3 +138,5 @@ private: | |||||
int perNotePitchbendRange; | int perNotePitchbendRange; | ||||
int masterPitchbendRange; | int masterPitchbendRange; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MPEZoneLayout::MPEZoneLayout() noexcept | MPEZoneLayout::MPEZoneLayout() noexcept | ||||
{ | { | ||||
} | } | ||||
@@ -378,3 +381,5 @@ static MPEZoneLayoutTests MPEZoneLayoutUnitTests; | |||||
#endif // JUCE_UNIT_TESTS | #endif // JUCE_UNIT_TESTS | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -157,3 +157,5 @@ private: | |||||
void processZoneLayoutRpnMessage (MidiRPNMessage); | void processZoneLayoutRpnMessage (MidiRPNMessage); | ||||
void processPitchbendRangeRpnMessage (MidiRPNMessage); | void processPitchbendRangeRpnMessage (MidiRPNMessage); | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
#if JUCE_MAC || JUCE_IOS | #if JUCE_MAC || JUCE_IOS | ||||
@@ -304,3 +305,5 @@ private: | |||||
}; | }; | ||||
#endif | #endif | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -173,3 +173,5 @@ public: | |||||
*/ | */ | ||||
virtual void getNextAudioBlock (const AudioSourceChannelInfo& bufferToFill) = 0; | virtual void getNextAudioBlock (const AudioSourceChannelInfo& bufferToFill) = 0; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
BufferingAudioSource::BufferingAudioSource (PositionableAudioSource* s, | BufferingAudioSource::BufferingAudioSource (PositionableAudioSource* s, | ||||
TimeSliceThread& thread, | TimeSliceThread& thread, | ||||
const bool deleteSourceWhenDeleted, | const bool deleteSourceWhenDeleted, | ||||
@@ -307,3 +310,5 @@ int BufferingAudioSource::useTimeSlice() | |||||
{ | { | ||||
return readNextBufferChunk() ? 1 : 100; | return readNextBufferChunk() ? 1 : 100; | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -113,3 +113,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (BufferingAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (BufferingAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
ChannelRemappingAudioSource::ChannelRemappingAudioSource (AudioSource* const source_, | ChannelRemappingAudioSource::ChannelRemappingAudioSource (AudioSource* const source_, | ||||
const bool deleteSourceWhenDeleted) | const bool deleteSourceWhenDeleted) | ||||
: source (source_, deleteSourceWhenDeleted), | : source (source_, deleteSourceWhenDeleted), | ||||
@@ -180,3 +183,5 @@ void ChannelRemappingAudioSource::restoreFromXml (const XmlElement& e) | |||||
remappedOutputs.add (outs[i].getIntValue()); | remappedOutputs.add (outs[i].getIntValue()); | ||||
} | } | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -135,3 +135,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ChannelRemappingAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ChannelRemappingAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
IIRFilterAudioSource::IIRFilterAudioSource (AudioSource* const inputSource, | IIRFilterAudioSource::IIRFilterAudioSource (AudioSource* const inputSource, | ||||
const bool deleteInputWhenDeleted) | const bool deleteInputWhenDeleted) | ||||
: input (inputSource, deleteInputWhenDeleted) | : input (inputSource, deleteInputWhenDeleted) | ||||
@@ -73,3 +76,5 @@ void IIRFilterAudioSource::getNextAudioBlock (const AudioSourceChannelInfo& buff | |||||
->processSamples (bufferToFill.buffer->getWritePointer (i, bufferToFill.startSample), | ->processSamples (bufferToFill.buffer->getWritePointer (i, bufferToFill.startSample), | ||||
bufferToFill.numSamples); | bufferToFill.numSamples); | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -62,3 +62,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (IIRFilterAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (IIRFilterAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,7 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
//============================================================================== | |||||
namespace juce | |||||
{ | |||||
MemoryAudioSource::MemoryAudioSource (AudioBuffer<float>& bufferToUse, bool copyMemory, bool shouldLoop) | MemoryAudioSource::MemoryAudioSource (AudioBuffer<float>& bufferToUse, bool copyMemory, bool shouldLoop) | ||||
: isLooping (shouldLoop) | : isLooping (shouldLoop) | ||||
{ | { | ||||
@@ -64,3 +66,5 @@ void MemoryAudioSource::getNextAudioBlock (const AudioSourceChannelInfo& bufferT | |||||
if (pos < m) | if (pos < m) | ||||
dst.clear (bufferToFill.startSample + pos, m - pos); | dst.clear (bufferToFill.startSample + pos, m - pos); | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -59,3 +59,5 @@ private: | |||||
//============================================================================== | //============================================================================== | ||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MemoryAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MemoryAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MixerAudioSource::MixerAudioSource() | MixerAudioSource::MixerAudioSource() | ||||
: currentSampleRate (0.0), bufferSizeExpected (0) | : currentSampleRate (0.0), bufferSizeExpected (0) | ||||
{ | { | ||||
@@ -151,3 +154,5 @@ void MixerAudioSource::getNextAudioBlock (const AudioSourceChannelInfo& info) | |||||
info.clearActiveBufferRegion(); | info.clearActiveBufferRegion(); | ||||
} | } | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -93,3 +93,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MixerAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MixerAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -70,3 +70,5 @@ public: | |||||
/** Tells the source whether you'd like it to play in a loop. */ | /** Tells the source whether you'd like it to play in a loop. */ | ||||
virtual void setLooping (bool shouldLoop) { ignoreUnused (shouldLoop); } | virtual void setLooping (bool shouldLoop) { ignoreUnused (shouldLoop); } | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
ResamplingAudioSource::ResamplingAudioSource (AudioSource* const inputSource, | ResamplingAudioSource::ResamplingAudioSource (AudioSource* const inputSource, | ||||
const bool deleteInputWhenDeleted, | const bool deleteInputWhenDeleted, | ||||
const int channels) | const int channels) | ||||
@@ -259,3 +262,5 @@ void ResamplingAudioSource::applyFilter (float* samples, int num, FilterState& f | |||||
*samples++ = (float) out; | *samples++ = (float) out; | ||||
} | } | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -99,3 +99,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ResamplingAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ResamplingAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
ReverbAudioSource::ReverbAudioSource (AudioSource* const inputSource, const bool deleteInputWhenDeleted) | ReverbAudioSource::ReverbAudioSource (AudioSource* const inputSource, const bool deleteInputWhenDeleted) | ||||
: input (inputSource, deleteInputWhenDeleted), | : input (inputSource, deleteInputWhenDeleted), | ||||
bypass (false) | bypass (false) | ||||
@@ -76,3 +79,5 @@ void ReverbAudioSource::setBypassed (bool b) noexcept | |||||
reverb.reset(); | reverb.reset(); | ||||
} | } | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -68,3 +68,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ReverbAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ReverbAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
ToneGeneratorAudioSource::ToneGeneratorAudioSource() | ToneGeneratorAudioSource::ToneGeneratorAudioSource() | ||||
: frequency (1000.0), | : frequency (1000.0), | ||||
sampleRate (44100.0), | sampleRate (44100.0), | ||||
@@ -71,3 +74,5 @@ void ToneGeneratorAudioSource::getNextAudioBlock (const AudioSourceChannelInfo& | |||||
info.buffer->setSample (j, info.startSample + i, sample); | info.buffer->setSample (j, info.startSample + i, sample); | ||||
} | } | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -65,3 +65,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ToneGeneratorAudioSource) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (ToneGeneratorAudioSource) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
SynthesiserSound::SynthesiserSound() {} | SynthesiserSound::SynthesiserSound() {} | ||||
SynthesiserSound::~SynthesiserSound() {} | SynthesiserSound::~SynthesiserSound() {} | ||||
@@ -567,3 +570,5 @@ SynthesiserVoice* Synthesiser::findVoiceToSteal (SynthesiserSound* soundToPlay, | |||||
return low; | return low; | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -645,3 +645,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Synthesiser) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Synthesiser) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
AudioDeviceManager::AudioDeviceSetup::AudioDeviceSetup() | AudioDeviceManager::AudioDeviceSetup::AudioDeviceSetup() | ||||
: sampleRate (0), | : sampleRate (0), | ||||
bufferSize (0), | bufferSize (0), | ||||
@@ -1000,3 +1003,5 @@ double AudioDeviceManager::getCurrentOutputLevel() const noexcept { return out | |||||
void AudioDeviceManager::enableInputLevelMeasurement (bool enable) noexcept { inputLevelMeter.setEnabled (enable); } | void AudioDeviceManager::enableInputLevelMeasurement (bool enable) noexcept { inputLevelMeter.setEnabled (enable); } | ||||
void AudioDeviceManager::enableOutputLevelMeasurement (bool enable) noexcept { outputLevelMeter.setEnabled (enable); } | void AudioDeviceManager::enableOutputLevelMeasurement (bool enable) noexcept { outputLevelMeter.setEnabled (enable); } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -518,3 +518,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (AudioDeviceManager) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (AudioDeviceManager) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
AudioIODevice::AudioIODevice (const String& deviceName, const String& deviceTypeName) | AudioIODevice::AudioIODevice (const String& deviceName, const String& deviceTypeName) | ||||
: name (deviceName), typeName (deviceTypeName) | : name (deviceName), typeName (deviceTypeName) | ||||
{ | { | ||||
@@ -37,3 +40,5 @@ bool AudioIODevice::showControlPanel() | |||||
// their hasControlPanel() method. | // their hasControlPanel() method. | ||||
return false; | return false; | ||||
} | } | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
class AudioIODevice; | class AudioIODevice; | ||||
@@ -301,3 +302,5 @@ protected: | |||||
/** @internal */ | /** @internal */ | ||||
String name, typeName; | String name, typeName; | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
AudioIODeviceType::AudioIODeviceType (const String& name) | AudioIODeviceType::AudioIODeviceType (const String& name) | ||||
: typeName (name) | : typeName (name) | ||||
{ | { | ||||
@@ -74,3 +77,5 @@ AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_Android() | |||||
#if ! (JUCE_ANDROID && JUCE_USE_ANDROID_OPENSLES) | #if ! (JUCE_ANDROID && JUCE_USE_ANDROID_OPENSLES) | ||||
AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_OpenSLES() { return nullptr; } | AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_OpenSLES() { return nullptr; } | ||||
#endif | #endif | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -174,3 +174,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE (AudioIODeviceType) | JUCE_DECLARE_NON_COPYABLE (AudioIODeviceType) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -53,3 +53,5 @@ private: | |||||
SystemAudioVolume(); // Don't instantiate this class, just call its static fns. | SystemAudioVolume(); // Don't instantiate this class, just call its static fns. | ||||
JUCE_DECLARE_NON_COPYABLE (SystemAudioVolume) | JUCE_DECLARE_NON_COPYABLE (SystemAudioVolume) | ||||
}; | }; | ||||
} // namespace juce |
@@ -155,9 +155,6 @@ | |||||
#endif | #endif | ||||
namespace juce | |||||
{ | |||||
#include "audio_io/juce_AudioDeviceManager.cpp" | #include "audio_io/juce_AudioDeviceManager.cpp" | ||||
#include "audio_io/juce_AudioIODevice.cpp" | #include "audio_io/juce_AudioIODevice.cpp" | ||||
#include "audio_io/juce_AudioIODeviceType.cpp" | #include "audio_io/juce_AudioIODeviceType.cpp" | ||||
@@ -214,14 +211,15 @@ namespace juce | |||||
#if JUCE_USE_ANDROID_OPENSLES | #if JUCE_USE_ANDROID_OPENSLES | ||||
#include "native/juce_android_OpenSL.cpp" | #include "native/juce_android_OpenSL.cpp" | ||||
#endif | #endif | ||||
#endif | #endif | ||||
#if ! JUCE_SYSTEMAUDIOVOL_IMPLEMENTED | #if ! JUCE_SYSTEMAUDIOVOL_IMPLEMENTED | ||||
// None of these methods are available. (On Windows you might need to enable WASAPI for this) | |||||
float JUCE_CALLTYPE SystemAudioVolume::getGain() { jassertfalse; return 0.0f; } | |||||
bool JUCE_CALLTYPE SystemAudioVolume::setGain (float) { jassertfalse; return false; } | |||||
bool JUCE_CALLTYPE SystemAudioVolume::isMuted() { jassertfalse; return false; } | |||||
bool JUCE_CALLTYPE SystemAudioVolume::setMuted (bool) { jassertfalse; return false; } | |||||
#endif | |||||
namespace juce | |||||
{ | |||||
// None of these methods are available. (On Windows you might need to enable WASAPI for this) | |||||
float JUCE_CALLTYPE SystemAudioVolume::getGain() { jassertfalse; return 0.0f; } | |||||
bool JUCE_CALLTYPE SystemAudioVolume::setGain (float) { jassertfalse; return false; } | |||||
bool JUCE_CALLTYPE SystemAudioVolume::isMuted() { jassertfalse; return false; } | |||||
bool JUCE_CALLTYPE SystemAudioVolume::setMuted (bool) { jassertfalse; return false; } | |||||
} | } | ||||
#endif |
@@ -140,9 +140,6 @@ | |||||
//============================================================================== | //============================================================================== | ||||
namespace juce | |||||
{ | |||||
#include "midi_io/juce_MidiInput.h" | #include "midi_io/juce_MidiInput.h" | ||||
#include "midi_io/juce_MidiMessageCollector.h" | #include "midi_io/juce_MidiMessageCollector.h" | ||||
#include "midi_io/juce_MidiOutput.h" | #include "midi_io/juce_MidiOutput.h" | ||||
@@ -156,5 +153,3 @@ namespace juce | |||||
#if JUCE_IOS | #if JUCE_IOS | ||||
#include "native/juce_ios_Audio.h" | #include "native/juce_ios_Audio.h" | ||||
#endif | #endif | ||||
} |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
class MidiInput; | class MidiInput; | ||||
@@ -171,3 +172,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiInput) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiInput) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
MidiMessageCollector::MidiMessageCollector() | MidiMessageCollector::MidiMessageCollector() | ||||
{ | { | ||||
} | } | ||||
@@ -151,3 +154,5 @@ void MidiMessageCollector::handleIncomingMidiMessage (MidiInput*, const MidiMess | |||||
{ | { | ||||
addMessageToQueue (message); | addMessageToQueue (message); | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -99,3 +99,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiMessageCollector) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiMessageCollector) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
struct MidiOutput::PendingMessage | struct MidiOutput::PendingMessage | ||||
{ | { | ||||
PendingMessage (const void* const data, const int len, const double timeStamp) | PendingMessage (const void* const data, const int len, const double timeStamp) | ||||
@@ -169,3 +172,5 @@ void MidiOutput::run() | |||||
clearAllPendingMessages(); | clearAllPendingMessages(); | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -139,3 +139,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiOutput) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiOutput) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
//============================================================================== | //============================================================================== | ||||
/** | /** | ||||
@@ -31,9 +32,8 @@ class MidiDataConcatenator | |||||
{ | { | ||||
public: | public: | ||||
//============================================================================== | //============================================================================== | ||||
MidiDataConcatenator (const int initialBufferSize) | |||||
: pendingData ((size_t) initialBufferSize), | |||||
pendingDataTime (0), pendingBytes (0), runningStatus (0) | |||||
MidiDataConcatenator (int initialBufferSize) | |||||
: pendingData ((size_t) initialBufferSize) | |||||
{ | { | ||||
} | } | ||||
@@ -181,9 +181,11 @@ private: | |||||
} | } | ||||
MemoryBlock pendingData; | MemoryBlock pendingData; | ||||
double pendingDataTime; | |||||
int pendingBytes; | |||||
uint8 runningStatus; | |||||
double pendingDataTime = 0; | |||||
int pendingBytes = 0; | |||||
uint8 runningStatus = 0; | |||||
JUCE_DECLARE_NON_COPYABLE (MidiDataConcatenator) | JUCE_DECLARE_NON_COPYABLE (MidiDataConcatenator) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,7 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
//============================================================================== | |||||
namespace juce | |||||
{ | |||||
#define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \ | #define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \ | ||||
STATICMETHOD (getMinBufferSize, "getMinBufferSize", "(III)I") \ | STATICMETHOD (getMinBufferSize, "getMinBufferSize", "(III)I") \ | ||||
STATICMETHOD (getNativeOutputSampleRate, "getNativeOutputSampleRate", "(I)I") \ | STATICMETHOD (getNativeOutputSampleRate, "getNativeOutputSampleRate", "(I)I") \ | ||||
@@ -472,3 +474,5 @@ AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_Android() | |||||
return new AndroidAudioIODeviceType(); | return new AndroidAudioIODeviceType(); | ||||
} | } | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
#define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \ | #define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \ | ||||
METHOD (getJuceAndroidMidiInputDevices, "getJuceAndroidMidiInputDevices", "()[Ljava/lang/String;") \ | METHOD (getJuceAndroidMidiInputDevices, "getJuceAndroidMidiInputDevices", "()[Ljava/lang/String;") \ | ||||
METHOD (getJuceAndroidMidiOutputDevices, "getJuceAndroidMidiOutputDevices", "()[Ljava/lang/String;") \ | METHOD (getJuceAndroidMidiOutputDevices, "getJuceAndroidMidiOutputDevices", "()[Ljava/lang/String;") \ | ||||
@@ -357,3 +360,5 @@ MidiInput::~MidiInput() | |||||
{ | { | ||||
delete reinterpret_cast<AndroidMidiInput*> (internal); | delete reinterpret_cast<AndroidMidiInput*> (internal); | ||||
} | } | ||||
} // namespace juce |
@@ -20,7 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
//============================================================================== | |||||
namespace juce | |||||
{ | |||||
#define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \ | #define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \ | ||||
STATICFIELD (SDK_INT, "SDK_INT", "I") \ | STATICFIELD (SDK_INT, "SDK_INT", "I") \ | ||||
@@ -1283,3 +1285,5 @@ pthread_t juce_createRealtimeAudioThread (void* (*entry) (void*), void* userPtr) | |||||
return threadID; | return threadID; | ||||
} | } | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
class iOSAudioIODevice; | class iOSAudioIODevice; | ||||
static const char* const iOSAudioDeviceName = "iOS Audio"; | static const char* const iOSAudioDeviceName = "iOS Audio"; | ||||
@@ -183,6 +186,10 @@ bool getNotificationValueForKey (NSNotification* notification, NSString* key, NS | |||||
@end | @end | ||||
//============================================================================== | //============================================================================== | ||||
#if JUCE_MODULE_AVAILABLE_juce_graphics | |||||
#include <juce_graphics/native/juce_mac_CoreGraphicsHelpers.h> | |||||
#endif | |||||
namespace juce { | namespace juce { | ||||
#ifndef JUCE_IOS_AUDIO_LOGGING | #ifndef JUCE_IOS_AUDIO_LOGGING | ||||
@@ -206,10 +213,6 @@ static void logNSError (NSError* e) | |||||
#define JUCE_NSERROR_CHECK(X) { NSError* error = nil; X; logNSError (error); } | #define JUCE_NSERROR_CHECK(X) { NSError* error = nil; X; logNSError (error); } | ||||
#if JUCE_MODULE_AVAILABLE_juce_graphics | |||||
#include <juce_graphics/native/juce_mac_CoreGraphicsHelpers.h> | |||||
#endif | |||||
//============================================================================== | //============================================================================== | ||||
struct iOSAudioIODevice::Pimpl : public AudioPlayHead, | struct iOSAudioIODevice::Pimpl : public AudioPlayHead, | ||||
public AsyncUpdater | public AsyncUpdater | ||||
@@ -1168,3 +1171,5 @@ void AudioSessionHolder::handleRouteChange (const char* reason) | |||||
} | } | ||||
#undef JUCE_NSERROR_CHECK | #undef JUCE_NSERROR_CHECK | ||||
} // namespace juce |
@@ -20,7 +20,8 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
#pragma once | |||||
namespace juce | |||||
{ | |||||
struct iOSAudioIODeviceType; | struct iOSAudioIODeviceType; | ||||
@@ -86,3 +87,5 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE (iOSAudioIODevice) | JUCE_DECLARE_NON_COPYABLE (iOSAudioIODevice) | ||||
}; | }; | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
namespace | namespace | ||||
{ | { | ||||
@@ -1272,3 +1275,5 @@ AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_ALSA() | |||||
{ | { | ||||
return createAudioIODeviceType_ALSA_PCMDevices(); | return createAudioIODeviceType_ALSA_PCMDevices(); | ||||
} | } | ||||
} // namespace juce |
@@ -20,7 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
//============================================================================== | |||||
namespace juce | |||||
{ | |||||
static void* juce_libjackHandle = nullptr; | static void* juce_libjackHandle = nullptr; | ||||
static void* juce_loadJackFunction (const char* const name) | static void* juce_loadJackFunction (const char* const name) | ||||
@@ -602,3 +604,5 @@ AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_JACK() | |||||
{ | { | ||||
return new JackAudioIODeviceType(); | return new JackAudioIODeviceType(); | ||||
} | } | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
#if JUCE_ALSA | #if JUCE_ALSA | ||||
// You can define these strings in your app if you want to override the default names: | // You can define these strings in your app if you want to override the default names: | ||||
@@ -610,3 +613,5 @@ MidiInput* MidiInput::openDevice (int, MidiInputCallback*) { re | |||||
MidiInput* MidiInput::createNewDevice (const String&, MidiInputCallback*) { return nullptr; } | MidiInput* MidiInput::createNewDevice (const String&, MidiInputCallback*) { return nullptr; } | ||||
#endif | #endif | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
#if JUCE_COREAUDIO_LOGGING_ENABLED | #if JUCE_COREAUDIO_LOGGING_ENABLED | ||||
#define JUCE_COREAUDIOLOG(a) { String camsg ("CoreAudio: "); camsg << a; Logger::writeToLog (camsg); } | #define JUCE_COREAUDIOLOG(a) { String camsg ("CoreAudio: "); camsg << a; Logger::writeToLog (camsg); } | ||||
#else | #else | ||||
@@ -2058,3 +2061,5 @@ AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_CoreAudio() | |||||
} | } | ||||
#undef JUCE_COREAUDIOLOG | #undef JUCE_COREAUDIOLOG | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
#ifndef JUCE_LOG_COREMIDI_ERRORS | #ifndef JUCE_LOG_COREMIDI_ERRORS | ||||
#define JUCE_LOG_COREMIDI_ERRORS 1 | #define JUCE_LOG_COREMIDI_ERRORS 1 | ||||
#endif | #endif | ||||
@@ -555,3 +558,5 @@ void MidiInput::stop() | |||||
} | } | ||||
#undef CHECK_ERROR | #undef CHECK_ERROR | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
#undef WINDOWS | #undef WINDOWS | ||||
/* The ASIO SDK *should* declare its callback functions as being __cdecl, but different versions seem | /* The ASIO SDK *should* declare its callback functions as being __cdecl, but different versions seem | ||||
@@ -1639,3 +1642,5 @@ AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_ASIO() | |||||
{ | { | ||||
return new ASIOAudioIODeviceType(); | return new ASIOAudioIODeviceType(); | ||||
} | } | ||||
} // namespace juce |
@@ -20,8 +20,6 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
} // (juce namespace) | |||||
extern "C" | extern "C" | ||||
{ | { | ||||
// Declare just the minimum number of interfaces for the DSound objects that we need.. | // Declare just the minimum number of interfaces for the DSound objects that we need.. | ||||
@@ -1271,3 +1269,5 @@ AudioIODeviceType* AudioIODeviceType::createAudioIODeviceType_DirectSound() | |||||
{ | { | ||||
return new DSoundAudioIODeviceType(); | return new DSoundAudioIODeviceType(); | ||||
} | } | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
struct MidiServiceType | struct MidiServiceType | ||||
{ | { | ||||
struct InputWrapper | struct InputWrapper | ||||
@@ -27,7 +30,6 @@ struct MidiServiceType | |||||
virtual ~InputWrapper() {} | virtual ~InputWrapper() {} | ||||
virtual String getDeviceName() = 0; | virtual String getDeviceName() = 0; | ||||
virtual void start() = 0; | virtual void start() = 0; | ||||
virtual void stop() = 0; | virtual void stop() = 0; | ||||
}; | }; | ||||
@@ -37,7 +39,6 @@ struct MidiServiceType | |||||
virtual ~OutputWrapper() {} | virtual ~OutputWrapper() {} | ||||
virtual String getDeviceName() = 0; | virtual String getDeviceName() = 0; | ||||
virtual void sendMessageNow (const MidiMessage&) = 0; | virtual void sendMessageNow (const MidiMessage&) = 0; | ||||
}; | }; | ||||
@@ -47,10 +48,8 @@ struct MidiServiceType | |||||
virtual StringArray getDevices (bool) = 0; | virtual StringArray getDevices (bool) = 0; | ||||
virtual int getDefaultDeviceIndex (bool) = 0; | virtual int getDefaultDeviceIndex (bool) = 0; | ||||
virtual InputWrapper* createInputWrapper (MidiInput* const, | |||||
const int, | |||||
MidiInputCallback* const callback) = 0; | |||||
virtual OutputWrapper* createOutputWrapper (const int) = 0; | |||||
virtual InputWrapper* createInputWrapper (MidiInput*, int, MidiInputCallback*) = 0; | |||||
virtual OutputWrapper* createOutputWrapper (int) = 0; | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiServiceType) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MidiServiceType) | ||||
}; | }; | ||||
@@ -510,14 +509,12 @@ public: | |||||
: WindowsOutputWrapper::getDefaultDeviceIndex(); | : WindowsOutputWrapper::getDefaultDeviceIndex(); | ||||
} | } | ||||
InputWrapper* createInputWrapper (MidiInput* const input, | |||||
const int index, | |||||
MidiInputCallback* const callback) override | |||||
InputWrapper* createInputWrapper (MidiInput* input, int index, MidiInputCallback* callback) override | |||||
{ | { | ||||
return new WindowsInputWrapper (*this, input, index, callback); | return new WindowsInputWrapper (*this, input, index, callback); | ||||
} | } | ||||
OutputWrapper* createOutputWrapper (const int index) override | |||||
OutputWrapper* createOutputWrapper (int index) override | |||||
{ | { | ||||
return new WindowsOutputWrapper (*this, index); | return new WindowsOutputWrapper (*this, index); | ||||
} | } | ||||
@@ -1081,14 +1078,12 @@ public: | |||||
: outputDeviceWatcher->getDefaultDeviceIndex(); | : outputDeviceWatcher->getDefaultDeviceIndex(); | ||||
} | } | ||||
InputWrapper* createInputWrapper (MidiInput* const input, | |||||
const int index, | |||||
MidiInputCallback* const callback) override | |||||
InputWrapper* createInputWrapper (MidiInput* input, int index, MidiInputCallback* callback) override | |||||
{ | { | ||||
return new WinRTInputWrapper (*this, input, index, *callback); | return new WinRTInputWrapper (*this, input, index, *callback); | ||||
} | } | ||||
OutputWrapper* createOutputWrapper (const int index) override | |||||
OutputWrapper* createOutputWrapper (int index) override | |||||
{ | { | ||||
return new WinRTOutputWrapper (*this, index); | return new WinRTOutputWrapper (*this, index); | ||||
} | } | ||||
@@ -1169,8 +1164,9 @@ MidiInput* MidiInput::openDevice (const int index, MidiInputCallback* const call | |||||
if (callback == nullptr) | if (callback == nullptr) | ||||
return nullptr; | return nullptr; | ||||
ScopedPointer<MidiInput> in (new MidiInput ("")); | |||||
ScopedPointer<MidiInput> in (new MidiInput ({})); | |||||
ScopedPointer<MidiServiceType::InputWrapper> wrapper; | ScopedPointer<MidiServiceType::InputWrapper> wrapper; | ||||
try | try | ||||
{ | { | ||||
wrapper = MidiService::getInstance()->getService()->createInputWrapper (in, index, callback); | wrapper = MidiService::getInstance()->getService()->createInputWrapper (in, index, callback); | ||||
@@ -1207,6 +1203,7 @@ int MidiOutput::getDefaultDeviceIndex() | |||||
MidiOutput* MidiOutput::openDevice (const int index) | MidiOutput* MidiOutput::openDevice (const int index) | ||||
{ | { | ||||
ScopedPointer<MidiServiceType::OutputWrapper> wrapper; | ScopedPointer<MidiServiceType::OutputWrapper> wrapper; | ||||
try | try | ||||
{ | { | ||||
wrapper = MidiService::getInstance()->getService()->createOutputWrapper (index); | wrapper = MidiService::getInstance()->getService()->createOutputWrapper (index); | ||||
@@ -1229,6 +1226,7 @@ MidiOutput::~MidiOutput() | |||||
void MidiOutput::sendMessageNow (const MidiMessage& message) | void MidiOutput::sendMessageNow (const MidiMessage& message) | ||||
{ | { | ||||
auto* const wrapper = static_cast<MidiServiceType::OutputWrapper*> (internal); | |||||
wrapper->sendMessageNow (message); | |||||
static_cast<MidiServiceType::OutputWrapper*> (internal)->sendMessageNow (message); | |||||
} | } | ||||
} // namespace juce |
@@ -20,6 +20,9 @@ | |||||
============================================================================== | ============================================================================== | ||||
*/ | */ | ||||
namespace juce | |||||
{ | |||||
#ifndef JUCE_WASAPI_LOGGING | #ifndef JUCE_WASAPI_LOGGING | ||||
#define JUCE_WASAPI_LOGGING 0 | #define JUCE_WASAPI_LOGGING 0 | ||||
#endif | #endif | ||||
@@ -1715,3 +1718,5 @@ float JUCE_CALLTYPE SystemAudioVolume::getGain() { return WasapiCla | |||||
bool JUCE_CALLTYPE SystemAudioVolume::setGain (float gain) { return WasapiClasses::MMDeviceMasterVolume().setGain (gain); } | bool JUCE_CALLTYPE SystemAudioVolume::setGain (float gain) { return WasapiClasses::MMDeviceMasterVolume().setGain (gain); } | ||||
bool JUCE_CALLTYPE SystemAudioVolume::isMuted() { return WasapiClasses::MMDeviceMasterVolume().isMuted(); } | bool JUCE_CALLTYPE SystemAudioVolume::isMuted() { return WasapiClasses::MMDeviceMasterVolume().isMuted(); } | ||||
bool JUCE_CALLTYPE SystemAudioVolume::setMuted (bool mute) { return WasapiClasses::MMDeviceMasterVolume().setMuted (mute); } | bool JUCE_CALLTYPE SystemAudioVolume::setMuted (bool mute) { return WasapiClasses::MMDeviceMasterVolume().setMuted (mute); } | ||||
} // namespace juce |