| @@ -321,7 +321,7 @@ int Fl_Canvas::handle(int event) | |||||
| redraw(); | redraw(); | ||||
| } | } | ||||
| if (Fl::event_button()==3) | |||||
| if (Fl::event_button()==2) | |||||
| { | { | ||||
| if (event==FL_PUSH) | if (event==FL_PUSH) | ||||
| { | { | ||||
| @@ -333,7 +333,7 @@ int Fl_Canvas::handle(int event) | |||||
| if (event==FL_DRAG) redraw(); | if (event==FL_DRAG) redraw(); | ||||
| if (event==FL_RELEASE && Fl::event_button()==3) | |||||
| if (event==FL_RELEASE) | |||||
| { | { | ||||
| m_ToolMenu=false; | m_ToolMenu=false; | ||||
| if (m_Selected!=-1 && cb_AddDevice) | if (m_Selected!=-1 && cb_AddDevice) | ||||
| @@ -176,6 +176,7 @@ void Fl_DeviceGUI::Resize(int width, int height) | |||||
| } | } | ||||
| position(x()+(oldw-w())/2,y()+(oldh-h())/2); | position(x()+(oldw-w())/2,y()+(oldh-h())/2); | ||||
| m_Menu->resize(x(),y(),width,height); | |||||
| int Centx=x()+w()/2; | int Centx=x()+w()/2; | ||||
| int Centy=y()+h()/2; | int Centy=y()+h()/2; | ||||
| @@ -147,6 +147,19 @@ void JackPluginGUI::cb_Attach(Fl_Button* o, void* v) | |||||
| inline void JackPluginGUI::cb_Detach_i(Fl_Button* o, void* v) | inline void JackPluginGUI::cb_Detach_i(Fl_Button* o, void* v) | ||||
| { | { | ||||
| //m_GUICH->SetCommand(JackPlugin::DETACH); | //m_GUICH->SetCommand(JackPlugin::DETACH); | ||||
| for (int n=0; n<NUM_OUTPUTS; n++) | |||||
| { | |||||
| m_OutputButton[n]->value(false); | |||||
| m_OutputButton[n]->label("None"); | |||||
| } | |||||
| for (int n=0; n<NUM_INPUTS; n++) | |||||
| { | |||||
| m_InputButton[n]->value(false); | |||||
| m_InputButton[n]->label("None"); | |||||
| } | |||||
| JackClient::Get()->Detach(); | JackClient::Get()->Detach(); | ||||
| } | } | ||||
| void JackPluginGUI::cb_Detach(Fl_Button* o, void* v) | void JackPluginGUI::cb_Detach(Fl_Button* o, void* v) | ||||
| @@ -222,7 +222,7 @@ void SpiralLoopPlugin::ExecuteCommands() | |||||
| void SpiralLoopPlugin::StreamOut(ostream &s) | void SpiralLoopPlugin::StreamOut(ostream &s) | ||||
| { | { | ||||
| s<<m_Version; | |||||
| s<<m_Version<<" "; | |||||
| s<<m_LoopPoint<<" "<<m_Speed<<" "<<m_Volume<<" "<<m_TicksPerLoop<<" "; | s<<m_LoopPoint<<" "<<m_Speed<<" "<<m_Volume<<" "<<m_TicksPerLoop<<" "; | ||||
| s<<m_TriggerVec.size()<<" "; | s<<m_TriggerVec.size()<<" "; | ||||
| for (vector<TriggerInfo>::iterator i=m_TriggerVec.begin(); | for (vector<TriggerInfo>::iterator i=m_TriggerVec.begin(); | ||||
| @@ -269,7 +269,7 @@ void SpiralLoopPlugin::LoadWav(const char *Filename) | |||||
| WavFile wav; | WavFile wav; | ||||
| if (wav.Open(Filename, WavFile::READ)) | if (wav.Open(Filename, WavFile::READ)) | ||||
| { | { | ||||
| Clear(); | |||||
| //Clear(); | |||||
| AllocateMem(wav.GetSize()); | AllocateMem(wav.GetSize()); | ||||
| wav.Load(m_StoreBuffer); | wav.Load(m_StoreBuffer); | ||||
| } | } | ||||
| @@ -323,7 +323,7 @@ bool SpiralLoopPlugin::GetOutput(Sample &data) | |||||
| // brute force fix | // brute force fix | ||||
| if (Pos>0 && Pos<m_LoopPoint) | if (Pos>0 && Pos<m_LoopPoint) | ||||
| { | { | ||||
| data.Set(n,m_StoreBuffer[m_Pos]+m_DubBuffer[m_Pos]*m_Volume); | |||||
| data.Set(n,(m_StoreBuffer[m_Pos]+m_DubBuffer[m_Pos])*m_Volume); | |||||
| } | } | ||||
| else data.Set(n,0); | else data.Set(n,0); | ||||
| @@ -230,6 +230,7 @@ void SpiralLoopPluginGUI::UpdateValues(SpiralPlugin *o) | |||||
| m_Volume->value(Plugin->GetVolume()); | m_Volume->value(Plugin->GetVolume()); | ||||
| m_Speed->value(Plugin->GetSpeed()); | m_Speed->value(Plugin->GetSpeed()); | ||||
| m_Length->value(Plugin->GetLoopLength()/m_SampleSize); | m_Length->value(Plugin->GetLoopLength()/m_SampleSize); | ||||
| m_LoopGUI->SetLength(Plugin->GetLoopLength()); | |||||
| } | } | ||||
| void SpiralLoopPluginGUI::Update() | void SpiralLoopPluginGUI::Update() | ||||
| @@ -34,14 +34,16 @@ string SpiralInfo::MIDIFILE = "/dev/midi"; | |||||
| int SpiralInfo::POLY = 1; | int SpiralInfo::POLY = 1; | ||||
| bool SpiralInfo::USEPLUGINLIST = false; | bool SpiralInfo::USEPLUGINLIST = false; | ||||
| //int SpiralInfo::GUI_COLOUR = 139; | |||||
| //int SpiralInfo::GUIBG_COLOUR = 0; | |||||
| //int SpiralInfo::GUIBG2_COLOUR = 49;//45; | |||||
| int SpiralSynthModularInfo::GUICOL_Tool=179; | |||||
| /*int SpiralSynthModularInfo::GUICOL_Tool=179; | |||||
| int SpiralSynthModularInfo::GUICOL_Button=181; | int SpiralSynthModularInfo::GUICOL_Button=181; | ||||
| int SpiralSynthModularInfo::GUICOL_Canvas=181; | int SpiralSynthModularInfo::GUICOL_Canvas=181; | ||||
| int SpiralSynthModularInfo::GUICOL_Device=181; | int SpiralSynthModularInfo::GUICOL_Device=181; | ||||
| int SpiralSynthModularInfo::GUIDEVICE_Box=30;*/ | |||||
| int SpiralSynthModularInfo::GUICOL_Tool=48; | |||||
| int SpiralSynthModularInfo::GUICOL_Button=42; | |||||
| int SpiralSynthModularInfo::GUICOL_Canvas=50; | |||||
| int SpiralSynthModularInfo::GUICOL_Device=52; | |||||
| int SpiralSynthModularInfo::GUIDEVICE_Box=30; | int SpiralSynthModularInfo::GUIDEVICE_Box=30; | ||||
| vector<string> SpiralSynthModularInfo::PLUGINVEC; | vector<string> SpiralSynthModularInfo::PLUGINVEC; | ||||