src/main/java/net/sourceforge/jaad/aac/sbr/SBR.java
private void sbr_header(IBitStream ld) throws AACException {
		boolean bs_header_extra_1, bs_header_extra_2;

		this.header_count++;

		this.bs_amp_res = ld.readBool();

		/* bs_start_freq and bs_stop_freq must define a fequency band that does
		 not exceed 48 channels */
		this.bs_start_freq = ld.readBits(4);
		this.bs_stop_freq = ld.readBits(4);
		this.bs_xover_band = ld.readBits(3);
		ld.readBits(2); //reserved
		bs_header_extra_1 = ld.readBool();
		bs_header_extra_2 = ld.readBool();

		if(bs_header_extra_1) {
			this.bs_freq_scale = ld.readBits(2);
			this.bs_alter_scale = ld.readBool();
			this.bs_noise_bands = ld.readBits(2);
		}
		else {
			/* Default values */
			this.bs_freq_scale = 2;
			this.bs_alter_scale = true;
			this.bs_noise_bands = 2;
		}

		if(bs_header_extra_2) {
			this.bs_limiter_bands = ld.readBits(2);
			this.bs_limiter_gains = ld.readBits(2);
			this.bs_interpol_freq = ld.readBool();
			this.bs_smoothing_mode = ld.readBool();
		}
		else {
			/* Default values */
			this.bs_limiter_bands = 2;
			this.bs_limiter_gains = 2;
			this.bs_interpol_freq = true;
			this.bs_smoothing_mode = true;
		}

	}
private void sbr_header(IBitStream ld) throws AACException {
		boolean bs_header_extra_1, bs_header_extra_2;

		this.header_count++;

		this.bs_amp_res = ld.readBool();

		/* bs_start_freq and bs_stop_freq must define a fequency band that does
		 not exceed 48 channels */
		this.bs_start_freq = ld.readBits(4);
		this.bs_stop_freq = ld.readBits(4);
		this.bs_xover_band = ld.readBits(3);
		ld.readBits(2); //reserved
		bs_header_extra_1 = ld.readBool();
		bs_header_extra_2 = ld.readBool();

		if(bs_header_extra_1) {
			this.bs_freq_scale = ld.readBits(2);
			this.bs_alter_scale = ld.readBool();
			this.bs_noise_bands = ld.readBits(2);
		}
		else {
			/* Default values */
			this.bs_freq_scale = 2;
			this.bs_alter_scale = true;
			this.bs_noise_bands = 2;
		}

		if(bs_header_extra_2) {
			this.bs_limiter_bands = ld.readBits(2);
			this.bs_limiter_gains = ld.readBits(2);
			this.bs_interpol_freq = ld.readBool();
			this.bs_smoothing_mode = ld.readBool();
		}
		else {
			/* Default values */
			this.bs_limiter_bands = 2;
			this.bs_limiter_gains = 2;
			this.bs_interpol_freq = true;
			this.bs_smoothing_mode = true;
		}

	}
private void sbr_header ( IBitStream ld ) throws AACException { boolean bs_header_extra_1 , bs_header_extra_2 ; this . header_count ++ ; this . bs_amp_res = ld . readBool ( ) ; /* bs_start_freq and bs_stop_freq must define a fequency band that does
		 not exceed 48 channels */ this . bs_start_freq = ld . readBits ( 4 ) ; this . bs_stop_freq = ld . readBits ( 4 ) ; this . bs_xover_band = ld . readBits ( 3 ) ; ld . readBits ( 2 ) ; //reserved bs_header_extra_1 = ld . readBool ( ) ; bs_header_extra_2 = ld . readBool ( ) ; if ( bs_header_extra_1 ) { this . bs_freq_scale = ld . readBits ( 2 ) ; this . bs_alter_scale = ld . readBool ( ) ; this . bs_noise_bands = ld . readBits ( 2 ) ; } else { /* Default values */ this . bs_freq_scale = 2 ; this . bs_alter_scale = true ; this . bs_noise_bands = 2 ; } if ( bs_header_extra_2 ) { this . bs_limiter_bands = ld . readBits ( 2 ) ; this . bs_limiter_gains = ld . readBits ( 2 ) ; this . bs_interpol_freq = ld . readBool ( ) ; this . bs_smoothing_mode = ld . readBool ( ) ; } else { /* Default values */ this . bs_limiter_bands = 2 ; this . bs_limiter_gains = 2 ; this . bs_interpol_freq = true ; this . bs_smoothing_mode = true ; } }
/* table 3
/ * table 3