Commit Graph

2 Commits

Author SHA1 Message Date
Martin Storsjo 5ccb648586 Saturate additions in getEnvSfbEnergy in SBR encoding
This avoids wraparounds, which can trigger failed asserts with
some inputs. This fixes
https://github.com/mstorsjo/fdk-aac/issues/158.

The implementation of saturated addition loses the contents of the
lowest bit though, thus this change affects the output - but the
change is said to be acceptable.
2023-12-21 13:33:13 +02:00
Martin Storsjo 3d67acd6f2 Add a script for doing very rudimentary regression testing
This is expected to fail if the encoder is updated in a way
that changes its output; in such cases, the test references need
to be updated.
2023-12-21 13:33:10 +02:00