#434 --clipdetect scale suggestion unaware of --scale input value

open
nobody
1
2013-12-11
2013-02-22
tester
No

lame --scale 0.76 input.wav output.mp3 --clipdetect --replaygain-accurate (...)

output:

LAME 3.99.5 32bits (http://lame.sf.net)
CPU features: MMX (ASM used), SSE (ASM used), SSE2
Autoconverting from stereo to mono. Setting encoding to mono mode.
Using polyphase lowpass filter, transition band: 20094 Hz - 20627 Hz
Encoding input.wav to output.mp3
Encoding as 44.1 kHz single-ch MPEG-1 Layer III (7.3x) 96 kbps qval=0
Frame | CPU time/estim | REAL time/estim | play/CPU | ETA
8358/8358 (100%)| 0:58/ 0:58| 0:58/ 0:58| 3.7341x| 0:00
-------------------------------------------------------------------------------
kbps mono % long switch short %
96.0 100.0 92.3 4.4 3.3
Writing LAME Tag...done
ReplayGain: -8.0dB
WARNING: clipping occurs at the current gain. Set your decoder to decrease
the gain by at least 0.1dB or encode again using --scale 0.99
or less (the value under --scale is approximate).

but this is obviously wrong , correct suggestion should be --scale 0.75 (or 0.99*0.76) or NO suggestion

Discussion

  • tester
    tester
    2013-02-22

    • priority: 5 --> 1
     
  • Critter
    Critter
    2013-07-13

    Hmm... I tried, but didn't manage to emulate noted bug.
    Possibly, any special, specific entrance file was used?
    I took the decoded song and passed it via the compressor in similar conditions.
    Result I put (apparently, any problems it isn't observed).

    E:\Projects\lame-3.99.5\test_workplace>lame --scale 0.76 input.wav output.mp3 --
    clipdetect --replaygain-accurate -a -q0 -b96
    LAME 3.99.5 32bits (http://lame.sf.net)
    Autoconverting from stereo to mono. Setting encoding to mono mode.
    Using polyphase lowpass filter, transition band: 20094 Hz - 20627 Hz
    Encoding input.wav to output.mp3
    Encoding as 44.1 kHz single-ch MPEG-1 Layer III (7.3x) 96 kbps qval=0
    Frame | CPU time/estim | REAL time/estim | play/CPU | ETA
    10582/10582 (100%)| 4:21/ 4:21| 4:21/ 4:21| 1.0587x| 0:00


    kbps mono % long switch short %
    96.0 100.0 96.6 1.9 1.5
    Writing LAME Tag...done
    ReplayGain: -7.3dB

    The waveform does not clip and is at least 1.2dB away from full scale.

    E:\Projects\lame-3.99.5\test_workplace>

     
    Attachments
  • tester
    tester
    2013-12-11

    this problem is NOT about ENCODING or OUTPUT file,
    it is about WRONG --scale RECOMENDATIONS

    my situation:
    input.wav = still have clipping at --scale 0.76 (and probably no clipping at 0.75)
    problem = wrong --scale suggestion (0.99 instead of 0.75)
    ( recomendation to use "--scale 0.99" to avoid clipping is obviously wrong )

    your situation:
    input.wav = do not have clipping at --scale 0.76
    no problem, because it didn't suggest/recommend wrong --scale settings
    (it didn't suggest any scale settings at all)

    /lame/frontend/lame_main.c
    noclipScale = lame_get_noclipScale(gf);
    here we can see that current --scale value is not considered

     
    Last edit: tester 2013-12-11