// Path: core/src/com/chiptunetracker/model/Pattern.java
// public class Pattern {
// 	@Attribute(required=false)
// 	public Integer sample1;
// 	
// 	@Attribute(required=false)
// 	public Integer sample2;
// 	
// 	@Attribute(required=false)
// 	public Integer sample3;
// 	
// 	@Attribute(required=false)
// 	public Integer sample4;
// 	
// 	public LinkedList<Integer> getList() {
// 		return new LinkedList<Integer>(){{
// 			add(sample1);
// 			add(sample2);
// 			add(sample3);
// 			add(sample4);
// 		}};
// 	}
// }
// 
// Path: core/src/com/chiptunetracker/model/Sound.java
// public class Sound {
// 	@Attribute
// 	public Note note;
// 	
// 	@Attribute
// 	public Integer octave;
// 	
// 	@Attribute
// 	public Integer instrument;
// 	
// 	@Attribute
// 	public Integer volume;
// 
// 	@Attribute
// 	public Integer effect;
// 	
// 	public Sound() {
// 		octave = null;
// 		note = null;
// 		instrument = null;
// 		volume = null;
// 		effect = null;
// 	}
// 
// 	public Sound(Note note, Integer octave, Integer instrument, Integer volume, Integer effect) {
// 		this.note = note;
// 		this.octave = octave;
// 		this.instrument = instrument;
// 		this.volume = volume;
// 		this.effect = effect;
// 	}
// }


import com.chiptunetracker.model.Pattern;
import com.chiptunetracker.model.Sound;
import com.jsyn.JSyn;
import com.jsyn.Synthesizer;
import com.jsyn.unitgen.LineOut;
package com.chiptunetracker.core;


public class Chanels {
	public final static int CHANELS = 4;
	private Chanel[] chanels;
	private Synthesizer synth;
	private LineOut lineOut;
	
	private boolean playSample = false;
	
	private boolean playPattern = false;
	private boolean start = false;
	private int currentPattern;
	
	public Chanels() {
		synth = JSyn.createSynthesizer();
		
		lineOut = new LineOut();
		synth.add(lineOut);
		
		chanels = new Chanel[CHANELS];
		
		for(int i = 0; i < CHANELS; i++) {
			chanels[i] = new Chanel(this);
		}
		
		synth.start();
		lineOut.start();
	}
	
	/**
	 * ----------
	 * Sound
	 * ---------- 
	 */
	
// Path: core/src/com/chiptunetracker/model/Pattern.java
// public class Pattern {
// 	@Attribute(required=false)
// 	public Integer sample1;
// 	
// 	@Attribute(required=false)
// 	public Integer sample2;
// 	
// 	@Attribute(required=false)
// 	public Integer sample3;
// 	
// 	@Attribute(required=false)
// 	public Integer sample4;
// 	
// 	public LinkedList<Integer> getList() {
// 		return new LinkedList<Integer>(){{
// 			add(sample1);
// 			add(sample2);
// 			add(sample3);
// 			add(sample4);
// 		}};
// 	}
// }
// 
// Path: core/src/com/chiptunetracker/model/Sound.java
// public class Sound {
// 	@Attribute
// 	public Note note;
// 	
// 	@Attribute
// 	public Integer octave;
// 	
// 	@Attribute
// 	public Integer instrument;
// 	
// 	@Attribute
// 	public Integer volume;
// 
// 	@Attribute
// 	public Integer effect;
// 	
// 	public Sound() {
// 		octave = null;
// 		note = null;
// 		instrument = null;
// 		volume = null;
// 		effect = null;
// 	}
// 
// 	public Sound(Note note, Integer octave, Integer instrument, Integer volume, Integer effect) {
// 		this.note = note;
// 		this.octave = octave;
// 		this.instrument = instrument;
// 		this.volume = volume;
// 		this.effect = effect;
// 	}
// }


// Path: core/src/com/chiptunetracker/core/Chanels.java
import com.chiptunetracker.model.Pattern;
import com.chiptunetracker.model.Sound;
import com.jsyn.JSyn;
import com.jsyn.Synthesizer;
import com.jsyn.unitgen.LineOut;

package com.chiptunetracker.core;


public class Chanels {
	public final static int CHANELS = 4;
	private Chanel[] chanels;
	private Synthesizer synth;
	private LineOut lineOut;
	
	private boolean playSample = false;
	
	private boolean playPattern = false;
	private boolean start = false;
	private int currentPattern;
	
	public Chanels() {
		synth = JSyn.createSynthesizer();
		
		lineOut = new LineOut();
		synth.add(lineOut);
		
		chanels = new Chanel[CHANELS];
		
		for(int i = 0; i < CHANELS; i++) {
			chanels[i] = new Chanel(this);
		}
		
		synth.start();
		lineOut.start();
	}
	
	/**
	 * ----------
	 * Sound
	 * ---------- 
	 */
	
	public void playSound(Sound sound, int position) {