Code example for AudioRecord

Methods: releasestop

0
	} 
	 
	@Override 
	public void appStop(){ 
		threadRunning = false;
		 
		if(iTrack!=null){
			iTrack.stop();
		} 
		 
		try { 
			thread.join();
		} catch (InterruptedException e) {
			Log.e("OF", "error finishing audio thread ", e);
		} 
		thread = null;
		 
 
		if(oTrack!=null){
			oTrack.stop();
			oTrack.release();
			oTrack = null;
		} 
		if(iTrack!=null){
			iTrack.release();
			iTrack = null;
		} 
		 
	}