public File wavCombiner(File synthFile, File inputFile){
		
		Synthesizer synth = JSyn.createSynthesizer();
		LineOut lineOut;
		
		synth.add(lineOut = new LineOut());
		synth.start();
		FloatSample sample;
		FloatSample sample2;
		
		try {
			
//			AddUnit mixer = new AddUnit();
			
			sample = SampleLoader.loadFloatSample(synthFile);
			sample2 = SampleLoader.loadFloatSample(inputFile);
		
			VariableRateStereoReader samplePlayer = new VariableRateStereoReader();
			VariableRateMonoReader samplePlayer2 = new VariableRateMonoReader();
			
			synth.add(samplePlayer);
			synth.add(samplePlayer2);
			
			System.out.println(sample.getFrameRate());
			System.out.println(sample2.getFrameRate());
	
			samplePlayer.rate.set(sample.getFrameRate());
			samplePlayer2.rate.set(sample2.getFrameRate());
			
//			samplePlayer.output.connect(0, mixer.inputA, 0);
//			samplePlayer.output.connect(1, mixer.inputB, 1);
			
			samplePlayer2.dataQueue.queue(sample2);
			samplePlayer.dataQueue.queue(sample);
			
			samplePlayer.output.connect(0,lineOut.input, 0);
			samplePlayer2.output.connect(0,lineOut.input, 1);
			
			WaveRecorder recorder;
			String fileName = null;
	
			//removing the wav suffix before renaming the file
			for(int i = 0; i < inputFile.getName().length(); i++){
				if(inputFile.getName().charAt(i)=='.'){
					fileName = inputFile.getName().substring(0, i);
				}
			}
			
			synthFile = new File(AudioData.AUDIO_FOLDER + fileName + "C.wav");
			recorder = new WaveRecorder(synth, synthFile);
			
			samplePlayer.output.connect(0, recorder.getInput(), 0);
			samplePlayer.output.connect(0, recorder.getInput(), 1);
			
			//starting the input and accompaniment samples and the synth and recorder
			synth.startUnit(lineOut);
			samplePlayer.start();
			samplePlayer2.start();
			recorder.start();

			do
			{
				synth.sleepFor(1.0);
			} while(samplePlayer.dataQueue.hasMore());
			
			samplePlayer.stop();
			samplePlayer2.stop();
			recorder.stop();
			synth.stop();
			
		} catch (Exception ex){
			ex.printStackTrace();
		}
		return combinedFile;
	}