Welcome Guest ( Log In | Register )

Musepack encoder, Modification to write MPEG Audio Layer 1/2
post Dec 5 2010, 21:54
Post #1

Group: Members
Posts: 296
Joined: 27-July 02
From: Germany
Member No.: 2821

several years ago it was said that changing the MusePack encoder to mp2 output wonīt take very long. But AFAIK nobody has ever released a musepack-based mp2-encoder so far.
Because I need a high-quality mp2-encoder (for authoring DVDs) I tried it myself:

I was able to modify the encoder in a way it outputs a 448kbit/s MP1 file, if the bitrate musepack wants to encode is higher, the last subbands are just cut off, otherwise the frame is padded with 0. The problem is now: After just one musepack frame (=three layer1 frames) the bitrate is decreased dramatically: Beginning from band 5 only 2 bits are assigned for each subband, the lower ones also have 8 bits max. It doesnīt matter at what quality I try, itīs the same for thumb to insane.
Otherwise the output file will play fine (very noticeable artifacts because of low effective bitrate (about 200kbps layer1, stereo, 44100khz), but otherwise it seems to work).
Is here anybody familiar with the MusePack encoder able to tell why there is this bitrate drop? I havenīt done anything special, just disabled MS coding, changed the scalefactors, created a function to write MPEG layer1 bitstream and modified the allocate function not to use unsupported quantizers (resolution is increased in that case) and that allocation is limited by maximum bitrate (thatīs not causing the problem). Thatīs it. Unfortunately the source code is not very structured/readable so I donīt see what Iīm missing.
Any ideas?
Go to the top of the page
+Quote Post
Start new topic
post Dec 17 2010, 02:40
Post #2

Winamp Developer

Group: Developer
Posts: 669
Joined: 17-July 05
From: Ashburn, VA
Member No.: 23375

I can't remember all the details of layer 2, but if there are any IIR filters in the signal path will eventually create denormals, regardless of value range, when there is digital silence at the input.

Yes, I'd you use the SSE2 extension you can disable special denormal processing. But it is only used for sse2 instructions (e.g. addpd) and not x87 instructions (e.g. fadd )

Yes denormals are super slow.
Go to the top of the page
+Quote Post
post Dec 19 2010, 12:12
Post #3

Group: Members
Posts: 412
Joined: 13-June 10
Member No.: 81467

QUOTE (benski @ Dec 17 2010, 03:40) *
Yes denormals are super slow.

By poor accident I just came across this:
Denormal numbers in floating point signal processing applications
Laurent de Soras

Go to the top of the page
+Quote Post

Posts in this topic

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:


RSS Lo-Fi Version Time is now: 21st April 2014 - 14:12