-
Rostislav Pehlivanov authored
This commit reorders the coding tools such that they're doing what the decoder does in reverse order. The very first thing the decoder does is to decode M/S stereo if that's signalled, then prediction, IS, and finally TNS and PNS in another function. adjust_frame_information()'s application of IS and M/S was taken out into two separate functions since prediction doesn't expect to get the raw coefficients but rathe the coefficients at that part of the encoding process. The results show a much better PSNR when any combination of Intensity Stereo, Mid/Side stereo and Prediction is used, which is a sign of an increased encoder efficiency as well as the fact that the decoder gets what it expects. Otherwise, with only IS, PNS or prediction there are neither regressions nor improvements except in the case of IS, which now by itself (or with PNS) is less prone to artifacts. Enabling M/S (using stereo_mode) as well will also reduce stereo artifacts induced by IS, so in the very near future M/S may be enabled by default. Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
20dc5271