void Arpege::ChangeCurPlaySong(int value) { if (value == CurPlaySong ) return; boolean mustDes=false; int pos = CurPlaySong - CurTrSong; while ( value < CurTrSong ) { CurTrSong--; mustDes=true; } while ( value >= CurTrSong + 5 ) { CurTrSong++; mustDes=true; } CurPlaySong = value; if ( ActiFunc==NumFunc ) { if (mustDes) { DessinPage(); } else { if ( pos > 0 ) lcd1.Carac(pos*8,0,6); else lcd1.Carac(0,0,32); pos = value - CurTrSong; lcd1.Carac(pos*8,0,2); } } }
void Arpege::DessinPage() { if (ActiFunc != NumFunc) return; int pos=CurArp; menuArp.Val_1 = ParamGlo.Tempo; menuArp.Val_2 = mesure; menuArp.Val_3 = CurArp+1; Menu->DessinPage(); if ( Menu->FirstPage ) { if (is_played==PLAYED) { lcdM.setCursor(8,3); lcdM.print("Stop"); } else { lcdM.setCursor(8,3); lcdM.print("Play"); } if (is_mode_write) { lcdM.setCursor(0,3); lcdM.print("Ply"); } else { lcdM.setCursor(0,3); lcdM.print("Drw"); } if (Mode==MODE_PATT) { lcdM.setCursor(4,3); lcdM.print("Sng"); } else { lcdM.setCursor(4,3); lcdM.print("Arp"); } if (is_echo) { lcdM.setCursor(13,3); lcdM.print("-In"); } else { lcdM.setCursor(13,3); lcdM.print("+In"); } } Z_Clear(); switch(Mode) { case MODE_PATT : sprintf(tmpCh,"\x02\Arpg %d",pos+1); Z_Titre(1,tmpCh); lcd_Liste(tmpVal,(char *)listDirection,Tracks[pos].Direction); Z_TextValue(2,"Evolu.",tmpVal); lcd_Num(tmpVal,Tracks[pos].Octave); Z_TextValue(3,"Octave",tmpVal); lcd_Liste(tmpVal,(char *)listNote,Tracks[pos].Note); Z_TextValue(4,"Note",tmpVal); lcd_Num(tmpVal,Tracks[pos].Duree); Z_TextValue(5,"Durati.",tmpVal); lcd_Liste(tmpVal,(char *)listVelmod,Tracks[pos].Velomod); Z_TextValue(6,"Vel Mod",tmpVal); lcd_Num(tmpVal,Tracks[pos].Veloci); Z_TextValue(7,"Velocit",tmpVal); lcd_Liste(tmpVal,(char *)listMotif,Tracks[pos].Motif); Z_TextValue(8,"Motif",tmpVal); lcd_Num(tmpVal,Tracks[pos].Lg); Z_TextValue(9,"Steps",tmpVal); lcd_Num(tmpVal,Tracks[pos].Div); Z_TextValue(10,"Divide",tmpVal); /* lcd_Num(tmpVal,Tracks[pos].NMin); Z_TextValue(11,"Not.Min",tmpVal); lcd_Num(tmpVal,Tracks[pos].NMax); Z_TextValue(12,"Not.Max",tmpVal); */ lcd_Liste(tmpVal,(char *)listOffOn,Tracks[pos].FillAuto); Z_TextValue(11,"AutoFil",tmpVal); lcd_NoteAbs(tmpVal,Tracks[pos].Tonale); Z_TextValue(12,"Dominan",tmpVal); lcd_Liste(tmpVal,(char *)listAccord,Tracks[pos].Accord); Z_TextValue(13,"Tonalit",tmpVal); lcd_Liste(tmpVal,(char *)listOffOnLock,Tracks[pos].Maintien); Z_TextValue(14,"Hold",tmpVal); lcd_Liste(tmpVal,(char *)listOffOn,Tracks[pos].Transpose); Z_TextValue(15,"Transpo",tmpVal); lcd_Liste(tmpVal,(char *)listMul,Tracks[pos].Modul); Z_TextValue(16,"Modula.",tmpVal); lcd_Num(tmpVal,Tracks[pos].Ampli); Z_TextValue(17,"M.Level",tmpVal); lcd_Liste(tmpVal,(char *)listDestin,Tracks[pos].Dest1); Z_TextValue(18,"Dest.1",tmpVal); lcd_Liste(tmpVal,(char *)listDestin,Tracks[pos].Dest2); Z_TextValue(19,"Dest.2",tmpVal); lcd_Num(tmpVal,Tracks[pos].Chanel); Z_TextValue(20,"Channel",tmpVal); break; case MODE_SONG : for (pos=0;pos<5;pos++) { if ( pos+CurTrSong == CurPlaySong ) lcd1.Carac(pos*8,0,2); else if ( pos > 0 ) lcd1.Carac(pos*8,0,6); else lcd1.Carac(0,0,32); sprintf(tmpCh,"Song %d",pos+CurTrSong+1); Z_Text(pos+1,tmpCh); lcd_Num(tmpVal,Songs[pos+CurTrSong].Track); Z_Value(pos+1,tmpVal); lcd_Num(tmpVal,Songs[pos+CurTrSong].Repeat); Z_TextValue(pos+6,"Repeat",tmpVal); lcd_Num(tmpVal,Songs[pos+CurTrSong].Transpose); Z_TextValue(pos+11,"Transp.",tmpVal); if ( Songs[pos+CurTrSong].Next == 0) sprintf(tmpVal,"Stop"); else lcd_Num(tmpVal,Songs[pos+CurTrSong].Next); Z_TextValue(pos+16,"Next",tmpVal); } break; } }