Browse Source

FIx build with new juce

tags/1.9.4
falkTX 11 years ago
parent
commit
4c7669f7a9
2 changed files with 10 additions and 10 deletions
  1. +9
    -9
      source/backend/engine/CarlaEngineInternal.cpp
  2. +1
    -1
      source/backend/plugin/JucePlugin.cpp

+ 9
- 9
source/backend/engine/CarlaEngineInternal.cpp View File

@@ -558,15 +558,15 @@ void CarlaEngineProtectedData::processRack(const float* inBufReal[2], float* out
EnginePluginData& pluginData(plugins[i]);

#ifdef HAVE_JUCE
float tmpMin, tmpMax;
juce::Range<float> range;

if (oldAudioInCount > 0)
{
FloatVectorOperations::findMinAndMax(inBuf0, static_cast<int>(frames), tmpMin, tmpMax);
pluginData.insPeak[0] = carla_max<float>(std::abs(tmpMin), std::abs(tmpMax), 1.0f);
range = FloatVectorOperations::findMinAndMax(inBuf0, static_cast<int>(frames));
pluginData.insPeak[0] = carla_max<float>(std::abs(range.getStart()), std::abs(range.getEnd()), 1.0f);

FloatVectorOperations::findMinAndMax(inBuf1, static_cast<int>(frames), tmpMin, tmpMax);
pluginData.insPeak[1] = carla_max<float>(std::abs(tmpMin), std::abs(tmpMax), 1.0f);
range = FloatVectorOperations::findMinAndMax(inBuf1, static_cast<int>(frames));
pluginData.insPeak[1] = carla_max<float>(std::abs(range.getStart()), std::abs(range.getEnd()), 1.0f);
}
else
{
@@ -576,11 +576,11 @@ void CarlaEngineProtectedData::processRack(const float* inBufReal[2], float* out

if (plugin->getAudioOutCount() > 0)
{
FloatVectorOperations::findMinAndMax(outBuf[0], static_cast<int>(frames), tmpMin, tmpMax);
pluginData.outsPeak[0] = carla_max<float>(std::abs(tmpMin), std::abs(tmpMax), 1.0f);
range = FloatVectorOperations::findMinAndMax(outBuf[0], static_cast<int>(frames));
pluginData.outsPeak[0] = carla_max<float>(std::abs(range.getStart()), std::abs(range.getEnd()), 1.0f);

FloatVectorOperations::findMinAndMax(outBuf[1], static_cast<int>(frames), tmpMin, tmpMax);
pluginData.outsPeak[1] = carla_max<float>(std::abs(tmpMin), std::abs(tmpMax), 1.0f);
range = FloatVectorOperations::findMinAndMax(outBuf[1], static_cast<int>(frames));
pluginData.outsPeak[1] = carla_max<float>(std::abs(range.getStart()), std::abs(range.getEnd()), 1.0f);
}
else
{


+ 1
- 1
source/backend/plugin/JucePlugin.cpp View File

@@ -914,7 +914,7 @@ public:
// Set audio out buffers

for (uint32_t i=0; i < pData->audioOut.count; ++i)
FloatVectorOperations::copy(outBuffer[i], fAudioBuffer.getSampleData(static_cast<int>(i)), static_cast<int>(frames));
FloatVectorOperations::copy(outBuffer[i], fAudioBuffer.getReadPointer(static_cast<int>(i)), static_cast<int>(frames));

// --------------------------------------------------------------------------------------------------------
// Midi out


Loading…
Cancel
Save