This is a open discussion for @icbaker after the revert of #3200 (and maybe @microkatz after the recent other related changes) I can't find a way to apply that properly only in the ffmpegrenderer we need something to plumb it inside DecoderAudioRenderer. Maybe something like: `protected int getGaplessTrimOffsetSamples(Format inputFormat)` Its contract would be: - Default implementation returns 0. - Returns an adjustment in PCM audio frames. - When deriving the sink’s trim counts, add it to encoderDelay and subtract it from encoderPadding, clamping padding to zero. - FfmpegAudioRenderer owns the MP3 eligibility check and the 529 constant. The name makes clear that this adjusts gapless metadata rather than reporting general decoder latency. Or anything else that you might think of. That would allow me to upstream the fix in ffmpeg renderer and not maintain another local patch.
Activity