An initial operation is one of obtaining metadata (azimuth values, elevation values, energy ratios) as shown in Figure 3 by step 301 . 

Having obtained the metadata for each sub-band (i=1 :N) prepare an initial distribution or allocation and as shown by Figure 3 by step 303: use 3 bits to encode the corresponding energy ratio value and then set the quantization resolution for the azimuth and the elevation for all the time-frequency blocks of the current subband. The quantization resolution is set by allowing a predefined number of bits given by the value of the energy ratio, bits_dir0[0:N-1][0:M-1] 

Having generated an initial allocation reduce the allocated number of bits, bits_dir1 [0:N-1][0:M-1] (the sum of the allocated bits = number of available bits left after encoding the energy ratios) as shown in Figure 3 by step 305. 

Then implement the reduced bit allocation by implementing for sub-bands upto the penultimate (or if there are zero bits allocated for the last subband, then the “bitpassing”procedure may be implemented only up to the subband before the penultimate subband (1 :N-2)) sub-band (in other words For each subband i=1 :N-1 ): calculate the allowed bits for current subband: bits_allowed= sum(bits_dir1 [i][0:M- 1]). Encode the direction parameter indexes with the reduced allocated number of bits (using fixed rate encoding or entropy coding whichever uses fewer bits) and indicate encoding selection. If there are bits available with respect to the allowed bits: Redistribute the difference to the following subbands (by updating bits_dir1 [i+1 :N-1][0_M-1]) else subtract one bit from bits_dir1 [i+1][0]. This is shown in Figure 3 by step 307. 

Then for the final sub-band encode the direction parameter indexes for the last subband with the fixed rate approach using bits_dir1 [N-1 ][0:M-1 ] bits as shown in Figure 3 by step 309. 

With respect to Figure 4 is shown an example metadata extractor 137 as part of the decoder 133. 

In some embodiments the encoded datastream is passed to a demultiplexer 401 . The demultiplexer 401 is shown extracting the encoded energy ratios and the encoded direction indices and may also in some embodiments extract the other metadata and transport audio signals (not shown). 

