Patent ID: 8326619

Claim:
A method of encoding a signal comprising: inputting the signal to a perceptual model; generating a masking threshold for the signal based on the signal and a signal to mask ratio parameter; quantizing and encoding the signal based on the masking threshold; and tuning the signal to mask ratio parameter, wherein tuning the signal to mask ratio parameter comprises: calculating an average bitrate of the encoded portion; and adjusting the signal to mask ratio parameters, wherein adjusting the signal to mask ratio parameter comprises: SMR ⁡ ( adjusted ) = SMR ⁡ ( original ) + ( 1 + α ) ⁢ B T - b _ ⁡ ( n ) - α ⁢ ⁢ b ⁡ ( n ) αβ ⁡ ( n ) where B T is the target bitrate, b (n) is the average bitrate, b(n) is a short-term average bitrate calculated over a part of the encoded portion, β(n) is a tuning parameter and α is a predefined parameter.