Help - Search - Members - Calendar
Full Version: How To Id Digitally Silent Mp3 Frames?
Hydrogenaudio Forums > Lossy Audio Compression > MP3 > MP3 - Tech
sheh
Hello.

How can digitally silent mpeg audio frames be identified? Can frames be empty otherwise? My focus is mainly mp3, but if the rest is close enough I'm interested in that too.

~sheh.
freakngoat
If one of the LAME VBR presets was used, silent and only silent MP3 frames are encoded at 32kbps. You could identify this from the frame header.
sheh
This is not useful mostly. Besides only being relevant to LAME and VBR, it also depends on your settings.

I'm just not sure what I should be looking for after the frame header.
Jojo
QUOTE (freakngoat @ Feb 14 2005, 03:58 PM)
If one of the LAME VBR presets was used, silent and only silent MP3 frames are encoded at 32kbps. You could identify this from the frame header.
*

nah, not really. I have a song that was perfectly silent for more than a minute and --preset standard encoded that silence using 128kbps...I'm not sure what went wrong...a few frames were encoded using 32kbps...
odious malefactor
QUOTE (Jojo @ Feb 15 2005, 12:32 PM)
nah, not really. I have a song that was perfectly silent for more than a minute and --preset standard encoded that silence using 128kbps...

But was it "digital silence"?
sheh
QUOTE (odious malefactor @ Feb 15 2005, 10:39 PM)
But was it "digital silence"?
*

I want to be able to tell if a frame is "empty" -- a frame that would decode to a bunch of 0 samples.

mp3trim has some sort of auto-detection for silence at song beginning and ends, which looks like what I need. (Although mp3trim appears to be wrong sometimes, or maybe it just decides to also include almost silent frames).
smack
QUOTE (sheh @ Feb 16 2005, 01:51 AM)
I want to be able to tell if a frame is "empty" -- a frame that would decode to a bunch of 0 samples.
*


Well, just decode the frames and look at the decoded samples. tongue.gif

A frame decodes to "silence" if it contains:
-no encoded samples (XING VBR header is usually embedded in such an empty frame)
-OR encoded scalefactors (zero values) that mute the output during decoding
-OR encoded samples (zero values) that mute the output during decoding

The first case (no samples) is easily detected while inspecting the frame's "side info". The other cases (samples decode to silence) are more difficult to detect, in fact the most reliable way would be to decode the frame and inspect the output.
sheh
QUOTE (smack @ Feb 16 2005, 11:39 AM)
The first case (no samples) is easily detected while inspecting the frame's "side info". The other cases (samples decode to silence) are more difficult to detect, in fact the most reliable way would be to decode the frame and inspect the output.
*

What exactly "no samples" means? For example, the LAME filler, is it somehow defined as 0 used samples in this frame, or as samples with volume 0?

Ideally I'd want to tell apart a muted framed from a 0/empty one. And without actual decoding, because:
1) This wouldn't require a decoder :), and is faster.
2) I suppose one decoder may decode a frame as 0, while another may produce some low values. Or perhaps not? Is there an absolute zero despite rounding?

The Xing header has the first 32-bytes after the header all 0 (for mp3). Is that a special case, or something legit? On the other hand, "normal" perfectly silent frames do have some bytes set, and even, the first byte after the header is changing (private_bits perhaps?).

Can you explain what needs to be checked in the SI part? Is it something that can be easily applied also to versions/layers other than MPEG 1 Layer 3?

~sheh
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.