Skip to content

Commit 5889221

Browse files
committed
Merge remote-tracking branch 'refs/remotes/origin/development'
2 parents b662df5 + e72d57f commit 5889221

7 files changed

Lines changed: 28 additions & 5 deletions

File tree

Builds/VisualStudio2013/open-ephys.sln

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@ VisualStudioVersion = 12.0.31101.0
44
MinimumVisualStudioVersion = 10.0.40219.1
55
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "open-ephys", "open-ephys.vcxproj", "{9C924D66-7DEC-1AEF-B375-DB8666BFB909}"
66
EndProject
7+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{DE917D74-FAF2-41E9-BE61-CD40C62EB7D0}"
8+
ProjectSection(SolutionItems) = preProject
9+
Performance1.psess = Performance1.psess
10+
EndProjectSection
11+
EndProject
712
Global
813
GlobalSection(SolutionConfigurationPlatforms) = preSolution
914
Debug|Win32 = Debug|Win32

JuceLibraryCode/modules/juce_audio_processors/processors/juce_AudioProcessorGraph.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
==============================================================================
2323
*/
2424

25-
const int AudioProcessorGraph::midiChannelIndex = 0x1000;
25+
const int AudioProcessorGraph::midiChannelIndex = 0x8000;
2626

2727
//==============================================================================
2828
template <typename FloatType, typename Impl> struct FloatDoubleUtil {};
@@ -767,7 +767,9 @@ struct RenderingOpSequenceCalculator
767767
}
768768
else
769769
{
770-
for (int i = 0; i < node->getProcessor()->getTotalNumInputChannels(); ++i)
770+
//Open ephys modification
771+
unsigned int numInputChannels = node->getProcessor()->getTotalNumInputChannels();
772+
for (int i = 0; i < numInputChannels; ++i)
771773
if (i != inputChannelOfIndexToIgnore
772774
&& graph.getConnectionBetween (nodeId, outputChanIndex,
773775
node->nodeId, i) != nullptr)

Source/Plugins/LfpDisplayNode/LfpDisplayCanvas.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3033,6 +3033,11 @@ bool LfpDisplay::getSingleChannelState()
30333033

30343034
void LfpDisplay::mouseDown(const MouseEvent& event)
30353035
{
3036+
if (drawableChannels.isEmpty())
3037+
{
3038+
return;
3039+
}
3040+
30363041
//int y = event.getMouseDownY(); //relative to each channel pos
30373042
MouseEvent canvasevent = event.getEventRelativeTo(viewport);
30383043
int y = canvasevent.getMouseDownY() + viewport->getViewPositionY(); // need to account for scrolling

Source/Processors/AudioNode/AudioNode.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ void AudioNode::addInputChannel(GenericProcessor* sourceNode, int chan)
111111

112112
int channelIndex = getNextChannel(false);
113113

114-
setPlayConfigDetails(channelIndex+1,0,44100.0,128);
114+
//setPlayConfigDetails(channelIndex+1,0,44100.0,128);
115115

116116
auto dataChannel = sourceNode->getDataChannel(chan);
117117
auto dataChannelCopy = new DataChannel(*dataChannel);
@@ -121,6 +121,11 @@ void AudioNode::addInputChannel(GenericProcessor* sourceNode, int chan)
121121

122122
}
123123

124+
void AudioNode::updatePlaybackBuffer()
125+
{
126+
setPlayConfigDetails(dataChannelArray.size(), 0, 44100.0, 128);
127+
}
128+
124129
void AudioNode::setParameter(int parameterIndex, float newValue)
125130
{
126131
// change left channel, right channel, or volume

Source/Processors/AudioNode/AudioNode.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,9 @@ class AudioNode : public GenericProcessor
112112
/** Establishes a connection between a channel of a GenericProcessor and the AudioNode. */
113113
void addInputChannel(GenericProcessor* source, int chan);
114114

115+
/** Updates the audio buffer size*/
116+
void updatePlaybackBuffer();
117+
115118
/** A pointer to the AudioNode's editor. */
116119
ScopedPointer<AudioEditor> audioEditor;
117120

Source/Processors/ProcessorGraph/ProcessorGraph.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,7 @@ void ProcessorGraph::updateConnections(Array<SignalChainTabButton*, CriticalSect
375375
} // end while source != 0
376376
} // end "tabs" for loop
377377

378+
getAudioNode()->updatePlaybackBuffer();
378379
//Update RecordNode internal channel mappings
379380
Array<EventChannel*> extraChannels;
380381
getMessageCenter()->addSpecialProcessorChannels(extraChannels);

Source/Processors/RecordNode/RecordNode.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ RecordNode::RecordNode()
4242
isRecording = false;
4343
setFirstBlock = false;
4444

45-
settings.numInputs = 2048;
45+
settings.numInputs = 8;
4646
settings.numOutputs = 0;
4747

4848
recordingNumber = -1;
@@ -580,4 +580,6 @@ void RecordNode::updateRecordChannelIndexes()
580580
void RecordNode::addSpecialProcessorChannels(Array<EventChannel*>& channels)
581581
{
582582
eventChannelArray.addArray(channels);
583-
}
583+
settings.numInputs = dataChannelArray.size();
584+
setPlayConfigDetails(getNumInputs(), getNumOutputs(), 44100.0, 1024);
585+
}

0 commit comments

Comments
 (0)