HydrogenAudio

Hydrogenaudio Forum => Validated News => Topic started by: MoSPDude on 2006-07-24 14:51:08

Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 14:51:08
Hi, i've just finished updating the Winamp MAD input plugin 0.14.1b with,
* libmad 0.15.1b
* libid3tag 0.15.1b
* zlib 1.23
* Gaussian dither and noise shaping routines from SSRC 1.30
* Working ID3v2 editor
* APEv2 editor
* LAME gapless playback support
* Non-LAME tagged gap skip/removal feature
* ReplayGain support
* Winamp 5 advanced formatting support
* Shoutcast streaming title support

I'd like some other people to try it, and possible fix any remaining bugs etc. that I've probably missed.
I've included source code, it was compiled in Dev-C++ using the MinGW tools. Thanks for any and all feedback in advance.

*** The LATEST bugfixed DLL can be download from http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip) ***
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Garf on 2006-07-24 14:57:27
* Gaussian dither and noise shaping routines from SSRC 1.30


What's the point of gaussian dither? In which circumstances would it have any advantages over triangular dither?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 15:08:16
Perhaps so, I might make it so you can choose between rectangular, triangular or gaussian.

It turns out in AB listening tests, that most my family prefer no dither or noise shaping on the output at all.
Thats why there is an option to turn off dither and noise shaping.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Garf on 2006-07-24 15:24:28
It's extremely interesting they can hear a difference at all. (Is it statistically significant?)

AFAIK, this has so far only been accomplished under extreme circumstances.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 15:37:38
I thought it odd too, though I did agree - without the extra processing, the sound was clearer.

It was being pumped from winamp at 44.1kHz 24bit, via kernel streaming output plugin, digitally to a Marantz surround sound receiver in Source Direct stereo mode, to Eltax front speakers with mounted super tweeters.

Perhaps it has something to do with 'noiseamp' setting from SSRC, its fixed to 0.18 . Is that too much?

Thanks,
Craig
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: adamjk on 2006-07-24 18:00:25
So, at first I should compile it? Thank you very much!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 18:44:39
There is a ready compiled DLL in there called "in_mad.dll" - place that in your Winamp plugins folder.

It shouldn't depend on anything other than windows C runtime libraries, that you'd more than likely already have.

The source code was provided so anyone can see and improve on it as needed.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: amano on 2006-07-24 19:41:00
Is there media library support now?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: adamjk on 2006-07-24 19:53:22
There is a ready compiled DLL in there called "in_mad.dll" - place that in your Winamp plugins folder.

It shouldn't depend on anything other than windows C runtime libraries, that you'd more than likely already have.

The source code was provided so anyone can see and improve on it as needed.

Sorry, obviously my mistake. The only one explanation is temperature, only 36 Celsius! I will try it!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-07-24 20:38:58
All running, but opening the file info box crashes winamp and then half my system with some files. I use Winamp 5.21, Windows XP home on a Celeron M 1400.
Here (http://people.freenet.de/chaossoft/hazard.mp3)'s a short file where this happens.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 21:15:07
Will try and track it down, initial tests point to a libid3tag problem.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 21:43:03
In the test file, do you know what the ID3v2 tag frames are supposed to contain? The reason it was crashing is the frame id says to expect text - but it only contains garbage. It was a problem in my routine blindly expecting an entry in a string list.

The fixed in_mad.dll and updated in_mad.c is below,

http://www.zen23652.zen.co.uk/in_mad.2.zip (http://www.zen23652.zen.co.uk/in_mad.2.zip)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 22:00:47
Media library support will be in the next build hopefully.

I might also get round to setting up a holding website.

Craig
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-24 22:52:00
I've added media library support, its probably not very good but its working.

Download from,
http://www.zen23652.zen.co.uk/in_mad.3.zip (http://www.zen23652.zen.co.uk/in_mad.3.zip)

(file updated again at 23:03 BST - I'd managed to put a non-working copy in zip earlier)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-07-24 23:42:02
In the test file, do you know what the ID3v2 tag frames are supposed to contain? The reason it was crashing is the frame id says to expect text - but it only contains garbage. It was a problem in my routine blindly expecting an entry in a string list.

The fixed in_mad.dll and updated in_mad.c is below,

http://www.zen23652.zen.co.uk/in_mad.2.zip (http://www.zen23652.zen.co.uk/in_mad.2.zip)


The problematic files were music from a game (Poke646) so I don't know how they were created or what the metadata should be. The crash happened with all those files so I guess the encoder used was buggy. Thanks for fixing.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: niktheblak on 2006-07-25 08:01:54
Holy dead decoder resurrection, Batman!

How many years it has been since the last MAD version, three? Now people can once more start claiming how MAD makes natural instruments sound more organic compared to Winamp decoder and mpg123!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-07-25 09:08:56
Wow, I LOVE the way you show the original tagfield-names. Can these be implemented in the Title Formatting pleeeeeaaase?   

Edit: Oh crap, it doesn't read recursive tags (from Helium). Only shows TXXX: #Helium Featured Artist. Can this be fixed in any way? I'd really like being able to format the title using my Helium tags
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-25 22:18:18
Making the ID3v2 editor friendly is on the to-do list. I left it pretty much as the (disabled) one from 0.14.1b.

As for Helium tags, I'll have a look into it for you.

I've been fixing some minor problems with tags and libid3tag, such as not reading comments properly.

The latest dll will always be available from,
http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip)

I've not included source updates in the above, I'm planning to move and reorganise it all.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-07-26 08:12:43
I've been fixing some minor problems with tags and libid3tag, such as not reading comments properly.

Yes, I think it's called comments the way they implement tags. Thanks  How about Title Formatting?

I like being able to see and edit *ALL* tags, and the real field-names, so don't make it too user friendly
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: john33 on 2006-07-26 08:37:44
@MoSPDude, we'd be happy to host this at Rarewares when you think it's ready, unless you prefer to host it yourself, of course.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-26 09:11:49
@MoSPDude, we'd be happy to host this at Rarewares when you think it's ready, unless you prefer to host it yourself, of course.


That'd be great, I don't think its too far off being ready. I've rearranged the source to make it more understandable when adding/upgrading sections, and fixed a few other things in the process, plus stripped the DLL properly down to size (thought it was set too, but wasn't).

I'm going away for the next 4-5 days, and won't get chance to work on it so I'll update http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip) with the rearranged source and smaller DLL a bit later.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: john33 on 2006-07-26 09:40:06
That'd be great, I don't think its too far off being ready. I've rearranged the source to make it more understandable when adding/upgrading sections, and fixed a few other things in the process, plus stripped the DLL properly down to size (thought it was set too, but wasn't).

I'm going away for the next 4-5 days, and won't get chance to work on it so I'll update http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip) with the rearranged source and smaller DLL a bit later.

I'm also just about to go away for about 7 days, so we can sort it out when we're both back.  (I'll be in the depths of Wales without any access to the Internet!!) Have a good trip.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-26 18:41:31
This is going to be that last update for next 5 days, before I finish packing!

I've fixed a new fault, where ID3v2 tags weren't delete properly because the ID3v1 tags weren't read properly, due to changes I made to make it read comments frame.

I've added to the basic title formatting, the ability to show any (text) frame. An example is to add "%#COMM" to make it show the comments field. You have to disable Winamp 5 advanced title formatting to use the plugins own basic formatting.

Download from the link given in my previous post.

@john33, I've only just come back from Wales!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Mr_Rabid_Teddybear on 2006-07-26 21:59:23
Sorry I can't test this myself (I'm in the process of moving house, computer in cardboard box); but have the annoying internet stream hijacking behavior of the previous in_mad been fixed? (Like if you tried to play a vorbis internet stream in _mad hijacked it from in_vorbis and made Winamp hang, as in_mad obviously can't decode a vorbis stream...)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-07-26 23:47:47
in _mad hijacked it from in_vorbis and made Winamp hang, as in_mad obviously can't decode a vorbis stream...)
... that I'm wondering the same thing, does in_mad.dll still break streaming? 

If not, here's my feature request: leave unknown BS to in_mp3.dll (ie http;//somestream:8000, as this could also be an aacplus stream or just a website on some other port, etc.), but have it capture a proper* stream url (ie http;//somestream:8000/mountpoint.mp3) (this scenerio is doable with in_mpg123)

Any plans to add APEv2 tag support? replaygain? gapless playback?

I'm very happy to see it finally get updated for ID3v2 tags though, thanks and keep up the great work.

*Why nullsoft used a url that could be anything, I'll never understand.  Oh well, icecast2 is better than shoutcast anyways.
[edit]can't read[/edit]
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Big_Berny on 2006-07-27 08:21:27
In the mediamonkey-forum someone posted a gapless mad-version: http://www.mediamonkey.com/forum/viewtopic.php?t=10051 (http://www.mediamonkey.com/forum/viewtopic.php?t=10051)

Maybe this feature can be ported?

Big_Berny

PS: I'm happy with otachan's often updated in_mpg123.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-07-27 11:31:41
In the mediamonkey-forum someone posted a gapless mad-version: http://www.mediamonkey.com/forum/viewtopic.php?t=10051 (http://www.mediamonkey.com/forum/viewtopic.php?t=10051)

Maybe this feature can be ported?


This plugin actually REMOVES silence, and does not benefit from the LAME tags actually containing the missing samples:

Quote
This version examines the beginning and the end of each track for silence, and can remove up to approximately 78ms of silence from each end (3 frames). The unwanted silence is typically 50ms or less. If more than 78ms of silence is found - as is the case with normal albums - then the track will not be altered in any way. Therefore, only continuous live or mix type albums are altered.


I'd really like to have gapless playback, and maybe it can be ported from the in_mpg123 plugin?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-31 16:06:15
Hi,
I'm back from my short holiday now, ready to do some more to the plugin.

I've fixed the unknown internet stream hogging problem after looking at in_mpg123. It all relies on the user specified default extension for unknown file types. Another way to cure the hogging problem would be to change this from "mp3" to "aac" (or another file type supported by in_mp3 and NOT in_mad) in winamp preferences.

I'd like to add ReplayGain and the LAME gapless playback features. As for APEv2 tags, I'll add once I've cleaned up the ID3v2 code and am happy with that.

An updated file will be available shortly, I'll post again once its up.

Cheers for all comments :-)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-07-31 16:25:19
I'd like to add ReplayGain and the LAME gapless playback features. As for APEv2 tags, I'll add once I've cleaned up the ID3v2 code and am happy with that.


Best news EVER! Thumbs up. I'm already very happy with my new Title Formatting options, even though i miss the "Featuring artist" Helium tag         
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-07-31 23:13:04
I've updated http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip) .

I've added preliminary support for ReplayGain, it attempts to read it from LAME tag first then foobar ID3v2 tags. It has to be enabled manually via regedit for now. Open and close the plugin configuration to write the defaults, then edit them - "rgenabled" to enable and "rgalbum" to select album gain (otherwise track gain).
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-07-31 23:35:30
YAY!

I do hope you leave access to the advanced ID3v2 tagging options that are there now, I kinda like it.

I'm very glad to hear that something was done about the stream hijacking issue.  It would hijack anything that started with 'http' regardless of anything else (extention didn't matter, not even the default extention).  When I get a chance I will certainly see if what you did fixed the problem in all cases I can come up with.

Your work is very very much appreciated.  Thank you MoSPDude.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-01 22:39:59
Another update,

I've added gapless playback for files with a LAME tag. ReplayGain options are also now fully working, its checks for foobar ID3v2 info first, then the LAME tag.

The LAME gapless playback needs more testing, so all feedback on that feature will be greatly appreciated. Download from the usual.

Thanks in advance!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-02 10:58:26
Great work MoSPDude!
Is this, then, the first player/plugin to support the LAME replaygain tag?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: haregoo on 2006-08-02 11:39:21
Great work MoSPDude!
Is this, then, the first player/plugin to support the LAME replaygain tag?

No. Otachan's in_!mpg123 (http://www.hydrogenaudio.org/forums/index.php?showtopic=18530) has supported LAME tag replaygain since 2004.
Keep in mind that LAME tag replaygain adjustment is crap when you play MP3Gained file.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-02 11:56:36
Quote
Keep in mind that LAME tag replaygain adjustment is crap when you play MP3Gained file.

How can this be fixed/removed? (Or better yet, recovered if MP3Gain values are trashed?)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-02 21:35:50
Good point, I hadn't thought of that. I could make it check for APEv2 tags (which I was going to do eventually anyway), where MP3Gain stores undo and analysis information - and make a decision about ReplayGain based on that. For where MP3Gain hasn't stored tags, you could create 0dB gain and 1.00 max amp foobar ID3v2 ReplayGain tags, or disable the ReplayGain.

Anyone tried the LAME gapless decoding yet? I'm going to have to properly test it, I keep thinking I'm a few samples out.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: haregoo on 2006-08-02 22:18:36
Anyone tried the LAME gapless decoding yet? I'm going to have to properly test it, I keep thinking I'm a few samples out.


in_mad outputs 1055 sample longer or shorter wav at 44100hz.
I've tried with latest in_mad + NullSoft Disk Writer Plugin.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-03 00:04:15
Ok, after reading through LAME source and a few headaches, I've got the LAME gapless working properly, well at least on the test tones I've created and the files I've got. If haregoo could check this new version again, please.

I've also added reading of ID3v2 RVA2 field, but its untested as I don't personally have anything that writes them, if someone could point me in the right direction for a tagger.

Thanks for all your help

(Download from the usual http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip) )
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: haregoo on 2006-08-03 00:29:29
Ok, after reading through LAME source and a few headaches, I've got the LAME gapless working properly, well at least on the test tones I've created and the files I've got. If haregoo could check this new version again, please.

It worked and gapless sample (http://guruboolez.free.fr/samples/gapless/gapless_WAVPACK_free_of_right.zip) sounds OK for me.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bladecgn on 2006-08-03 19:11:05
Hey MoSPDude!

I had been experimenting with various players / plugins and have to say yours is the best, most natural sounding! Keep up the good work!

One feature request: Can you add an option for files without replaygain info to be played some db quieter or louder (user configurable, maybe +/- 10 db)?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-03 19:15:37
Ok, after reading through LAME source and a few headaches, I've got the LAME gapless working properly

There seems to be a slighty problem with gapless files, splitted with pcutmp3 - It cuts off 3960 samples (at least in my quick test).
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: TrNSZ on 2006-08-03 19:35:09
I had been experimenting with various players / plugins and have to say yours is the best, most natural sounding!
TOS #8?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-03 19:57:22
I'll have a look into why pcutmp3 files aren't working gaplessly - 3960 is a big number!. I'll also add a preamp option for files without replaygain. I have made some more changes to the LAME tag reading - I've abandoned the LAME routines, and migrated to the already (partially) present madplay XING/LAME routines.

At the moment, I've been working on updating the Id3v2 tag editor to show all fields in a frame, and cleaning up the code.

I'll post when the next update is available.

(Actually, thinking about it, the old LAME routines take any gapless clipping value above 3000 as rubbish so maybe its only that - I'll get the next release up ASAP for you to test)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-04 10:11:28
Another update, download from the usual.

I've made some heavy changes to the ID3v2 editor, and need to make some finishing touches. I've also made the gapless buffer dynamic. odyssey, could you test the pcutmp3 files again please and post number of samples out.

Thanks in advance.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Big_Berny on 2006-08-04 11:05:30
Hi,
I just tried the the mad-plugin with MediaMonkey (winamp-compatible). But I have two problems:
First, the noise shaping adds really strange and loud noise/clicks. No need to ABX!
Second, somehow all the mad-settings get messed up after hearing a song.

Anyone else with this problems? I returned to otachans mpg123 for the moment.

Big_Berny
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-04 11:28:29
Hi,
I just tried the the mad-plugin with MediaMonkey (winamp-compatible). But I have two problems:
First, the noise shaping adds really strange and loud noise/clicks. No need to ABX!
Second, somehow all the mad-settings get messed up after hearing a song.

Anyone else with this problems? I returned to otachans mpg123 for the moment.

Big_Berny


I've just installed MediaMonkey and tried it, and your right - all the settings are screwed, I think thats the main problem. I'll look into it for the next release ASAP.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-04 11:31:42
Hi,
I just tried the the mad-plugin with MediaMonkey (winamp-compatible). But I have two problems:
First, the noise shaping adds really strange and loud noise/clicks. No need to ABX!
Second, somehow all the mad-settings get messed up after hearing a song.

Anyone else with this problems? I returned to otachans mpg123 for the moment.

Big_Berny


These problems happen here, too, but only when a DSP plugin is enabled.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Big_Berny on 2006-08-04 11:55:21
Thanks!

By the way, I have no DSP plugin activated.

Big_Berny
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hecatomber on 2006-08-04 12:08:09
After using this input plugin, I have some problems about the last.fm (http://last.fm) plugin.

All the tags are like "WM/MediaClassPrimaryID" .
Is this problem about the mad plugin or the last.fm plugin?

btw, i just heard of this plugin and loved it. nice work.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-04 16:32:25
I've also made the gapless buffer dynamic. odyssey, could you test the pcutmp3 files again please and post number of samples out.

I still get 3960 samples cut out

Edit 3: It seems that the cut out is from the beginning of a track. I measured 3336 samples cut out from the first track of the two i'm testing gaplessy, which would be needed if i included the previous track in my test.

It looks funny with the 9 columns of ID3v2 tags, but if that's the way it work...  Do you have any information on why (/how?) recursive tags work - just out of curiosity

Is it possible to put these recursive tags into Title Formatting? (Although I would need some Advanced formatting to replace the funky Helium chars )

I also experienced a crash once I opened the "View file info"-dialog. I'll try to find out what caused that.

Edit: This way of tagging opens up a whole lot of possebilities... If you can use recursive tagging like that, you could put multiple artists under TPE1, and not just a comment field (Like HMM). If just any nice tagging app would do that...

Edit 2: How come "Advanced Title Formatting" don't support these ID3v2 fields??? Actually Winamp reads any field in both JTF and ML, it just needs the correct way of displaying fully tagged files.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-04 17:46:29
My bad with the MediaMonkey / DSP problem, I'd updated all the other code for the new buffer except the DSP processing section! Sorry, I'll put it up ASAP, just going to look into the pcutmp3 problem more.

EDIT: I've kind of "patched" the pcutmp3 problem, but I'm not happy with it, if anyone knows more about the libmad decoding delays and why,

LAME mp3s have 3 * 576 + 529 samples off the start when the tag only specifies 576 (by default in LAME encoder.h) from the beginning.
pmp3cut mp3s have (tag value) + 1151 + 529 samples off the start where (tag value) is specified.

Thanks in advanced
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-04 19:07:00
Ok, I've uploaded an update to the usual.

Please if anyone has any extra information regarding the LAME gapless behaviour, I'd appreciate it.

Thanks
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Big_Berny on 2006-08-04 19:14:13
Well, I don't know the reason but 1151 is 576*2-1.

So:
Lame: 3*576+529
pmp3cut: tagvalue+2*576-1+529

It would be interesting to know what happens when you change the value in lame... Because maybe the "lame-formula" is tagvalue+2*576+529. Then we have only one sample left!

Just some stupid ideas of a mathematician withoud any mp3-delay-knowledge.
Big_Berny
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-04 19:20:18
Well, I don't know the reason but 1151 is 576*2-1.

So:
Lame: 3*576+529
pmp3cut: tagvalue+2*576-1+529

It would be interesting to know what happens when you change the value in lame... Because maybe the "lame-formula" is tagvalue+2*576+529. Then we have only one sample left!

Just some stupid ideas of a mathematician withoud any mp3-delay-knowledge.
Big_Berny


You know, I might just go for that.....
I think the 529 is purely a libmad delay... as you said, just that 1 sample!

I'll just do another build, and upload another copy with that for ppl to test. I'll post again once its up.
Big_Berny, have you tested MediaMonkey with the build thats up at the moment?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Big_Berny on 2006-08-04 19:27:11
Maybe a Lame developer can give more informations?

And yes, the MAD-plugin works with MediaMonkey now, thanks!

Big_Berny
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-04 19:32:26
I've put up the version, ignoring the 1 sample, and it sounds ok with pcutmp3 files - thanks Big_Berny for that fresh view, think I'd been looking at it for too long!! If odyssey could confirm its ok, that'd be great!

I'm going to get back finishing the ID3v2 tag editor now, then perhaps begin APEv2 tags.

Any other bugs etc, feel free to post and help!

Thanks 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-05 00:19:34
I've put up the version, ignoring the 1 sample, and it sounds ok with pcutmp3 files - thanks Big_Berny for that fresh view, think I'd been looking at it for too long!! If odyssey could confirm its ok, that'd be great!

It works great now  (Please disregard the PM i sent you, I appearently did not update to the latest release)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 01:38:25
Another update has been uploaded, I think I've finished the look and basic behaviour of the ID3v2 tag editor. Opinions wanted! 

I'll look into recursive tags, APEv2 tags and other suggestions now.

Thanks to all for your comments

EDIT: I've just had to re-upload, I'd left debug messages in still!

EDIT 2: Another minor update, fixed bug reading in ID3v1 to v2 tags in new editor
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 10:47:24
Another update uploaded, this time for odyssey to test

In Winamp advanced title formatting, you can now read Helium, any TXXX key/value and ID3v2 text frames! It also scans recursively through the tag for multiple frames.

Just add for example, %#Helium Featured Artist% or %COMM% to the winamp preferences.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-05 11:08:50
Wow, great work. Just another question:
What is the behaviour when LAME rg-Tags and other rg-tags are present together? Which one will be preferred?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 12:11:56
Wow, great work. Just another question:
What is the behaviour when LAME rg-Tags and other rg-tags are present together? Which one will be preferred?


The order of preference is foobar TXXX tags, the RVA2 tag, then the LAME tag.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 12:38:42
DON'T WRITE UPDATED ID3v2 TAGS!!

There appears to be a MAJOR bug that libid3tag written id3v2.4 tags, can't be read by anything else!!

I'll fix it ASAP. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-05 14:13:34
In Winamp advanced title formatting, you can now read Helium, any TXXX key/value and ID3v2 text frames! It also scans recursively through the tag for multiple frames.

Just add for example, %#Helium Featured Artist% or %COMM% to the winamp preferences.

Doesn't seem to work for me. Also I have not been able to find ANY information about this anywhere! I even tried the latest Beta 5.25
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 14:55:37

In Winamp advanced title formatting, you can now read Helium, any TXXX key/value and ID3v2 text frames! It also scans recursively through the tag for multiple frames.

Just add for example, %#Helium Featured Artist% or %COMM% to the winamp preferences.

Doesn't seem to work for me. Also I have not been able to find ANY information about this anywhere! I even tried the latest Beta 5.25


First, make sure you download the latest release, I've been putting up smaller minor releases.

You need to have Advanced Title Formatting enabled, the feature is a bit of hack. I'm using Winamp 5.24.
If you goto Winamp Preferences, under General Preferences select Titles. Then ensure, Use the advanced title formatting is checked on, and the format string I'm using is,

[%artist%$if2( %#Helium Featured Artist%,) - ]$if2(%title%,$filepart(%filename%))

and it seems to work on all the files I put the tags on.

Winamp passes all the tags contained within the %..% to in_mad, then in_mad finds the tag (artist, title, #Helium Featured Artist etc.) and reports if its there or not. If you can read C, look at "in_mad.c" and "tags.c" - for an idea of how to work it.

I'll add it eventually to the basic formatting.

I'm having a big problem with libid3tag writing tags that nothing else understands, so please bear with me.

Thanks for all help
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 15:09:06
The problem does appear to be a long libid3tag problem, and the common solution is to patch libid3tag so it writes ID3v2.3 tags instead of v2.4.

For now, I'll follow the same solution.

An update will be available shortly.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-05 15:36:00
Edit: I REALLY need to learn to read before posting
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 16:46:03
Does anyone use iTunes?? Can someone please see if iTunes reads the tags written by in_mad correctly?

The patch that audacity applied to write id3v2.3 tags, stops libid3tag reading the tags in. I have no idea why...
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bubka on 2006-08-05 16:48:30
anyway to fix the visualization so that it's not all maxed out?  I have both RG (radio) and clipping enabled.  Also have id3v1 show by default.  Thanks! i think the 24bit output adds quite a bit extra... keep up the work!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 20:41:46
I'm having a fair bit of trouble regarding ID3v2.3 and v2.4 tags, it seems like a lottery if they get read correctly by Winamp, Helium or a few others. Disabling CRC sometimes works, and it appears fields are getting scrambled.

I'll upload a new version once I've solved it.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-05 21:28:19
Eureka!! libid3tag breaks the rules. I'll fix it up, and get a new release up - I've got to undo all the work on adding id3v2.3 tags! Unless you want an option to write either id3v2.3 or id3v2.4 tags??
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-06 01:03:29
I've finally uploaded another update. ID3v2.4 tags are now written properly, on all files I tested - and can be read properly by other taggers too.

@bubka, what do you mean by visualisation maxed out? Please can I have details of what visualisation etc. I think I will add a tag select box - probably once I've looked into APE tags. I'm also thinking of adding a preamp option for mp3s without replaygain info as suggested by bladecgn.

@hecatomber, I don't know about last.fm but I'll look into it eventually.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-06 15:00:54
Yet another update, APEv2 tags are now read. If mp3gain undo information is detected, then replaygain is disabled. The preference for replaygain data is APE tag, id3 tag then the lame tag. APE tag writing is not yet supported.

Download from the usual http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-06 17:38:37
If mp3gain undo information is detected, then replaygain is disabled.


This is not necessary IMO, because mp3gain adjusts the replaygain information in the APE tags when it changes a file. So if the RG tags are present before mp3gain is run, they are adjusted, and if they were created after mp3gain changed the files they are correct as well. So as long as you make sure only APE-tags are read when mp3gain undo information is present, everything should work fine.

Since APE-tags are the preferred RG-source anyway you don't have to worry at all. If mp3gain doesn't adjust the RG info because tag writing is disabled, then there will be no undo info in the tags either.

Hope that made some kind of sense. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-06 18:01:03
Ah right, I'll make the necessary changes. I think the config box is in need of an overhaul, then I can add tag preference options etc.

Anyone found any bugs in the APE tag reading, or ID3v2 tag read/writing? The latter has been giving me some grief.

Thanks,
Craig 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-07 10:02:03
it seems like a lottery if they get read correctly by Winamp, Helium or a few others.

I suspect something in Winamp is correcting it... Maybe Nullsoft in_mp3? I tried playing a file i've updated, which was not recognized the first time, but afterwards I had no problems.

Btw, is this still an error or did you correct it by writing only ID3v2.3 tags ?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-07 10:35:13
Btw, is this still an error or did you correct it by writing only ID3v2.3 tags ?


Quote from: MoSPDude link=msg=0 date=
I've finally uploaded another update. ID3v2.4 tags are now written properly, on all files I tested - and can be read properly by other taggers too.


It seems that's fixed.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-08 00:45:44
The tags that are written are ID3v2.4 , there is still a bug in libid3tag when CRC is written in that no other taggers will accept it, so CRC is disabled.

I've made some extensive changes to the configuration box, implemented a gap skip option (similar behaviour to http://www.mediamonkey.com/forum/viewtopic.php?t=10051) (http://www.mediamonkey.com/forum/viewtopic.php?t=10051)) for those files without LAME tag, added a tag preference order, and am working on writing APEv2 tags.

I won't do a release until APEv2 tag writing is at least working properly.

I think the plugin is almost complete, I'd like to hear any more feature requests etc.

Thanks for all support 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-08 01:09:18
remember that crashing problem?  I haven't got the latest version, but it was never mentioned that the crashing thing was fixed...

It seems to crash if there is a sync error at the very beginning of an MP3, in_mad 1.14 plays it just fine.

I'll get right on those feature requests as soon as I test out the latest version

But one for starters:
Option to 'display live average bitrate' to display the bitrate like in_mpg123 does for vbr files.
Maybe some more info about the MP3 that is playing, like if it has gapless tags and such. (i havent seen the latest version yet, so if that's already there, awsome!)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-08 09:42:21
Ah right, do you have a test file that can reproduce the problem by any chance? If 1.14 plays it fine, it'll be related to the new tag features - probably the XING/LAME reader. To help me check that, can you please try it with madplay 0.15.2b. I doubt its to do with libid3tag - or rather I hope not!

I'll get a release up later today with APEv2 tag writing. At the moment, it shows what tags are present, but no more information on the LAME tag. The live average bitrate option, I think, is already there, but you need to disable "show average bitrate" to show the bitrate live as its decoded.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-08 09:48:12
I think the plugin is almost complete, I'd like to hear any more feature requests etc.

I think i have a small problem with the Advanced Title Formatting, it seems that I cannot use %artist% and %title% tags for mp3 files anymore. However, the TPE1 and TIT2 tags work fine, so I could just use these and may be a suitable option if it's possible to use $if2($if2(A,B),B)... ?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-08 18:00:17
Ok, I've done some more bug fixing. A new release is out. I hope I've fixed the advanced title formatting problem, and I've made some changes to the XING/LAME reading that was causing some files to falsely detect a LAME tag and screwing up.

Please can you test the 'gap removal' feature, and the APEv2 tag writing, and post your experiences.

Please update ASAP to this new version.

Thanks, 

EDIT: I left debug messages in again, please re-download if neccessary.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-08 18:21:50
I hope I've fixed the advanced title formatting problem

Seems to work for me  i'm only left with the dreaded | character which Helium leaves in the field.... Seems that ATF don't have a replace function

I appreciate you work really! It's cool finally to make efficient use of the ID3v2 field-set, and a great decoder too
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bladecgn on 2006-08-09 08:17:41
Hi Craig... I installed MiniLyrics yesterday (cool program) and included lyrics tags in some mp3s. On some of those Winamp crashes now. No crash if I use in_mp3.

If you want me to send you a sample file, please let me know.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-09 20:23:30
Hi Craig... I installed MiniLyrics yesterday (cool program) and included lyrics tags in some mp3s. On some of those Winamp crashes now. No crash if I use in_mp3.

If you want me to send you a sample file, please let me know.


If you could provide a sample that'd be a great help! I'm now just cleaning up areas I'd left messy code.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-09 22:15:17
I've uploaded a version that should work with long ID3v2 fields, it'll truncate them in the editor viewer though. This should fix the lyrics problem. I'm cleaning up some areas still.

Thanks for help 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-11 07:32:46
Ok, after another look, I've fixed a problem with long APEv2 fields, again truncating them, NOW the lyrics problem should be fixed. An update will be available later, special thanks to bladecgn for helping me on that one.

Any idea on what kind of extra information can be included in the statisitcs info box for currently playing file?

Thanks to all 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-11 10:00:11
Ok, after another look, I've fixed a problem with long APEv2 fields, again truncating them, NOW the lyrics problem should be fixed. An update will be available later, special thanks to bladecgn for helping me on that one.

Any idea on what kind of extra information can be included in the statisitcs info box for currently playing file?

Thanks to all 


Applied gain would be nice.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-11 20:53:10
Any idea on what kind of extra information can be included in the statisitcs info box for currently playing file?

Total MS frames, IS frames, stereo frames, mono frames.

Indicator that gapless playback is possible on that particular file, and maybe some info like padding etc.


...I'll get around to downloading a new version one of these days
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-11 22:06:30
Slight delay on the update, I don't want to leave half-finished code in.

@MedO, The applied gain level is shown on the Stats page in the Output box.

I'm adding a LAME tag info box (didn't feel the need for a page as it shouldn't really be edited), and will move some of the stats boxes to show the pie chart and an actual frame detail count at gameplaya15143 request.

My time on this project is becoming a bit tighter with work. gameplaya15143, does the last update (download from usual place) still crash on some of your files? could you PM me if it does. Thank you very much for help and support.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-11 23:36:13
Another update has been uploaded, download from the main usual link http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip) .

The "More" button on the stats page is mainly a placeholder at the moment. I'm going to work on adding more detail to it. As mention before, time is becoming tighter but I'm still working on it - just a bit more slowly.

Thanks again to all those who are using it and bug finding 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-12 01:10:25
@MedO, The applied gain level is shown on the Stats page in the Output box.


Ah, sorry, there was a bit of confusion on my side, because of a small problem (bug?)
If I set the Replaygain option to "Audiophile" or "Radio", everything behaves as I would expect. However, there is also the option "Standard" I can't make anything of. If I enable it without "clipping prevention", no gain seems to be applied. If "clipping prevention" is on, there is a gain on some files, but I don't know where the value comes from. 

Also, something is amiss with the save function in the file info box. Using it (from the Id3v1-tab, not sure with other tabs) causes random crashes. Also, when I add a field to the Id3v2-tag, hit "save" and then click on the id3v1-tab, the id3v2-tab is still shown, the only thing that changes is a blinking cursor where the Artist textbox in the id3v1-tab is. Well, just try it out, maybe you can see for yourself.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-12 05:42:43
MoSPDude 

I just downloaded the latest.. Absolutely amazing! and it doesn't crash anymore, reports the sync error and plays just fine.

I have 3 fun ideas:

1. Option to display live average bitrate (it can display the current frame size, but it would be nice to have it average those and display the average as say 117, 83, 175, etc. like how in_mpg123 displays the bitrate for vbr files)

2. Just a small bit of info on the main page "Gapless:" with a checkbox to indicate if gapless playback is possible with the file.  (or is that implied when it says "with, LAME tags"?)

3. The ID3v2 tag editor is great, but for those of us that don't know what those tags are, how about somehow including the 'common' names for the 'artist' 'title' etc.? (same for the ape tags)

Just my thoughts 

Keep up the great work, and I'll try to crash it for you

edit: what about VBRI (fhg vbr header)?

edit2: how about a menu for common ape tags, like the id3v2 editor has?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bladecgn on 2006-08-12 05:47:53
First off, thank you MoSPDude for correcting the lyrics bug. Everything's working fine now.

Quote from the replaygain website:
----
"Radio" Replay Gain adjustment

This will make all the tracks sound equally loud (as they do on the radio, hence the name!). If the ReplayGain is calculated on a track-by-track basis (i.e. an individual ReplayGain calculation is carried out for each track), this will be the result. This is something that ReplayGain does very well. Take a listen.
"Audiophile" Replay Gain adjustment

The problem with the "Radio" setting is that tracks which should be quiet will be brought up to the level of all the rest. For casual listening, or in a noisy background, this can be a good thing. For serious listening, it would be a nuisance. You don't want a solo flute track blasting at the same loudness as Iron Maiden!

To solve this problem, the "Audiophile"
setting represents the ideal listening gain for each track. ReplayGain can have a good guess at this too, by reading the entire CD, and calculating a single gain adjustment for the whole disc. This works because quiet tracks then stay quiter than the rest, since the gain won't be changed for each track. It still solves the basic problem (annoying, unwanted level differences between discs) because quiet or loud discs are still adjusted overall - so the pop CD that's 20 dB louder than the classical CD will be brought into line.
----

I think the designations "Radio" and "audiophile" are misleading, as you could think quality is affected by the setting but only volume level is. I'd rather be calling it "track gain" and "album gain".
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-12 09:49:58
Yeah, the thought had crossed my mind to call it "Radio / Track" and "Audiophile / Album" as the vorbis decoder does. The standard setting I thought of calling "0 dB" - it disables the gain only. Basically, the gain you see when set to Standard comes from the clipping prevention ( 20 log( 1 / peak_value ) ) where peak_value is specified on the replaygain specs as full range at 1.
Shall I change the options then to None, Track and Album so as to make them clearer?

@gameplaya15143, I see, rather a running average display than a current frame rate display. I'll look into that. The gapless playback is implied when it specifies LAME tag, though again I will make it clearer, and your definately right about the ID3v2 editor needing the descriptions - also thinking of making the APEv2 field box a combo-dropdown so know what is generally available.

@MedO, I'll have a look into that one. I have a feeling I know whats causing it.

Thanks for all comments, keep up the good testing work 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-12 20:20:32
Did a feature get lost?  I thought that previously there was an option to set the preamp for files without replaygain, now there is only the preamp for files with replaygain.

I found quite an annoyance yesterday involving mp3s that have no tags.  I have it set to display the filename (which worked with the last version I used).  Now when it plays a tagless mp3, it displays the title - song from either the last song played (be it mp3, ogg, etc. it doesn't matter) or some other song that is visible on the playlist at the time.  It does this for any tagless mp3 in the playlist, even if it's not being played.

Just ran into another problem just now.
Song transition from mp3 to ogg, when the ogg starts playing I get nothing but white noise.  If I disable 'remove gaps' the problem goes away.  It only seems to occur with waveout using prebuffer on track change (outds is uneffected).  The file causing this most likely has some errors at the end of the file.

And another... Tag editor causes winamp to crash when the song is not playing.  Crashes on all tag types. 
I noticed that even after I hit stop, then view file info, the stats tab is still there.  IIRC it wasn't in in_mad 1.14.  Is it possible that things aren't being reset when they should be?
edit: Crash occurs when the song is played, then stoped, then tags edited.  It doesn't crash if the song hasn't been played and stopped.

Using winamp 2.95 by the way.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-13 00:06:37
I haven't properly got round to adding the preamp gain for files without RG yet. I promise I'll do it as soon as I can. 

Hopefully, I can say that all your above problems have been cured if you download new release from the usual place. If you could please check, test and confirm.

I don't know what I'd do if hadn't got you guys to help me test this thing! Your help is very much appreciated, and thanks for bearing with me while I fix these problems. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-13 12:10:56
I've fixed some more problems relating to the ReplayGain options and implemented a preamp option when no RG tag is found, as well as a 83dB reference level option as a -6.0dB preamp option.

I've added descriptive text to the ID3v2 editor, and a combobox for APE value names. I've change the VBR average display to show a running playback average at gameplaya15143 request.

I'm not too sure about implementing the VBRI header info. It doesn't seem too well supported in general, and I can't seem to find consistent details on it, other than possibly borrowing in_mpg123 implementation.

My next task currently is to display more information on the LAME tag.

Download from the usual, http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip) .
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bladecgn on 2006-08-13 13:17:57
Hi... got another idea:

In the Preferences, you can select the order in which Winamp uses the tags to disply filenames.

It would be nice that if you open the file info box, automatically the tab opens up that ist selected first in the preferences, i.e. if ID3v1 is selected in the preferences, ID3v1 Tab is displayed automatically when you open the file info box.

Hope I made myself clear here... 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-13 15:18:51
Another update, I've fixed ID3 to APE tag reading and made the change suggested by bladecgn with a slight difference. The opening page order is the same as specified in configuration. If no matching tag, then it'll open the General page.

Download from the usual place.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-14 23:05:59
For the next update, I've added streaming title support, made changes to how streams are detected and finished the LAME tag info box. I'm going to add a streaming info box, then I'll upload it.

Please bear with me, my time is a bit short.

Cheers 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-15 01:44:13
I've added descriptive text to the ID3v2 editor, and a combobox for APE value names. I've change the VBR average display to show a running playback average at gameplaya15143 request.

I'm not too sure about implementing the VBRI header info. It doesn't seem too well supported in general, and I can't seem to find consistent details on it, other than possibly borrowing in_mpg123 implementation.

I'll be sure to get the latest version when I get the chance and see if there are any remaining problems.

I hope you made the average live bitrate thing an OPTION, as both ways can be informative.

I'm not sure, but I'm not even sure if in_mpg123 supports VBRI 
Out of curiosity, what encoders can we get gapless playback from? just lame? xing/helix too?

And did I read correctly... streaming support?  You have to be careful with that, shoutcast streams can be either mp3 or aacplus and there is no difference in the url. My suggestion in such case would be to only handle proper* mp3 streams which have an mp3 extention, and leave the rest to in_mp3.

*[opinion]proper= url/stream.mp3[/opinion]
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-15 07:32:05
And did I read correctly... streaming support?  You have to be careful with that, shoutcast streams can be either mp3 or aacplus and there is no difference in the url. My suggestion in such case would be to only handle proper* mp3 streams which have an mp3 extention, and leave the rest to in_mp3.

*[opinion]proper= url/stream.mp3[/opinion]


Thats why the changes to how streams are detect were made. Shoutcast sends a header detailing the type of stream, and this is detected and stream abandoned by in_mad if neccessary. There is an option to turn off this new 'detect unknown streams' as I've called it - as the detection does require setting up a connection and reading header, before returning to winamp if we want the file or not. In my tests though, it works fine, unless there is trouble connecting, but I'm probably going to make it fail silently.

The in_mpg123 source I've got (the regularly updated code) does contain code to read the VBRI tags. If I was to implement it, I'd probably have to borrow the specification from this.

Proper gapless playback info is only found in the LAME tag, XING tag only contains VBR info. I don't know how other encoders store the padding information, if they do. Otherwise the gap skip option removes a definite amount of silence if it can find it to reduce/remove the gap.

The live bitrate option did take place of display the file average option - I think it does look better with it changing, and the file average only gets reported in the info box. I'll put it so can display "per frame", "live average" and "file average" bitrates, if you'd like that.

Cheers,
Craig 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-15 07:34:35
Is it just me having problems adding files to the ML? For me it seemed to crash after like 10 seconds, or it could be certain tags it can't handle. I disabled in_mad, and everything was fine.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-15 07:37:03
I'll have a look into that, what kind of tags does the files that you are adding have?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-15 07:57:11
I'll have a look into that, what kind of tags does the files that you are adding have?

They would all have MP3Gain APE tags...
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: benski on 2006-08-15 15:06:09
The in_mpg123 source I've got (the regularly updated code) does contain code to read the VBRI tags. If I was to implement it, I'd probably have to borrow the specification from this.


Information about FHG's VBRI header is available here:
http://www.iis.fraunhofer.de/amm/download/...ware/index.html (http://www.iis.fraunhofer.de/amm/download/software/index.html)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Big_Berny on 2006-08-15 15:22:03
Just a little question: Is there any advantage to use in_mad instead of otachans in_mpg123? Missing features?

Big_Berny
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-15 15:30:54
Just a little question: Is there any advantage to use in_mad instead of otachans in_mpg123? Missing features?

Big_Berny

Lame freeformat
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-15 15:52:56
Cheers benski! You know if you just Googled that I'll be very upset - I must have looked for over half an hour, only to find dead links....

I'm going to look into that ML problem now.

Cheers all! 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-15 16:28:09
I think I've sorted the ML problem, small mistake on my part, I'll have an update available later after I've finished the streaming info box.

I'll also start to look into VBRI tag support.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-18 12:41:45
Finally I've uploaded another update.

This has title streaming, stream info box and 'better' internet stream detection. If it gives you problems, please tell me with what internet stream and then uncheck 'detect unknown streams' to go back to the old behaviour.

Cheers 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bladecgn on 2006-08-18 15:17:34
Streaming works well!!     

This plugin gets better and better, thank you MoSPDude.

Another suggestion would be to rename the file based on the tag infomation.

Mayber in every Tag tab you could include a button "rename file" and an option which pattern to use (e.g. "(%1)-%2" would rename a file to "(Prince)-Diamonds and Pearls".

That would be a killer extension for me, as I often listen, tag files with winamp and would like to have them renamed based on my entries.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-18 19:47:14
Streaming works well!!     

This plugin gets better and better, thank you MoSPDude.

Another suggestion would be to rename the file based on the tag infomation.

Mayber in every Tag tab you could include a button "rename file" and an option which pattern to use (e.g. "(%1)-%2" would rename a file to "(Prince)-Diamonds and Pearls".

That would be a killer extension for me, as I often listen, tag files with winamp and would like to have them renamed based on my entries.


I think this is outside the scope of an input plugin. Besides, if you wrote a general purpose plugin for this, you could use it on files of any type, the input plugin just has to report the proper tags. I'm not into developing winamp plugins though, so I don't know if this is possible/easy.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-19 17:02:34
Proper gapless playback info is only found in the LAME tag, XING tag only contains VBR info. I don't know how other encoders store the padding information, if they do. Otherwise the gap skip option removes a definite amount of silence if it can find it to reduce/remove the gap.

The live bitrate option did take place of display the file average option - I think it does look better with it changing, and the file average only gets reported in the info box. I'll put it so can display "per frame", "live average" and "file average" bitrates, if you'd like that.

  I was under the impression that xing headers had gapless info, I guess I should read up on that.

The remove gaps option is still causing problems for me, track after the problem mp3 ends up being white noise.  IMO it shouldn't try to remove gaps unless gapless info is found.  Perhaps an extra option is in order? (ie checkbox: 'only when gapless playback info is present')

The bitrate display optons rule! .. but, live average is pointless the way it is done right now.  It should show the average bitrate over the last few frames (like in_mpg123) instead of showing the average bitrate of the mp3 so far.

It crashes winamp when writing the ID3v2 tag, after the mp3 has the tag, it can be edited without winamp crashing.  This does not happen if I add/edit the tags while the mp3 is playing.

Another small annoyance, if a higher tag is present (ie id3v2) but does not contain the info to be displayed (ie artist - title) then the filename is being shown even when the id3v1 tag contains the artist and title meta data.  It would be nice to have it check the 'lower' tags for metadata when the 'higher' tag doesn't have what is needed.

I'll test streaming later.

How about allowing the preamp to be set even when replaygain is disabled?

As always, thank you, and keep up the great work!

ps. I think the tag issues should be highest priority.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bladecgn on 2006-08-19 17:50:26
I think this is outside the scope of an input plugin. Besides, if you wrote a general purpose plugin for this, you could use it on files of any type, the input plugin just has to report the proper tags. I'm not into developing winamp plugins though, so I don't know if this is possible/easy.


I agree that a filename tagging function goes beyond a simple imput plugin.

Nevertheless, as this plugin has one of the best tag editors, the filename rename would be the cherry on top of the cream. :-)

I don't know if this is hard to do or not, but if you use the tag editor to change the tag why not use it as a file rename tool in this context?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-19 20:59:19
I'll definitely have a deeper look into the tag issues and the gap removal, might have to try and make some awkward mp3 files. I should probably make the options more clearer, but gapless playback is always enabled if a LAME tag is present, the option in the preferences attempts to remove some of the gap if there is NO gapless information available - subject to some rules.

@gameplaya15143, how many frames do you think I should make it average out across? and I'll change the higher priority tag display for basic formatting - I don't think it suffers that problem on advanced title formatting. Will also make it so that preamp is aways available.

@bladecgn, I'll have a look into it for you, though it probably is going a bit far for an input plugin.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-20 15:46:12
I've uploaded another update, hopefully addressing all the tag issues and the gap removal problem, if gameplaya15143 could test please  . I'm going to change the RG preamp and look into file renaming in a bit. At the moment, I'm finishing options and status for buffer length to aid streaming.

Download from the usual place 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-21 04:28:49
but gapless playback is always enabled if a LAME tag is present, the option in the preferences attempts to remove some of the gap if there is NO gapless information available - subject to some rules.

Well why didn't you say so  I guess leaving it unchecked is still pretty safe then (I haven't actually done any gapless tests).
The white noise problem I had seems to be gone though

What about tooltips to explain what the options do?

I tested streaming, sync errors galore! (icecast2 server on localhost vbr mp3), but I love the info display for the stream!  How about an option to not use in_mad for streaming at all?

If the option to use 'none' for replay gain was in the last version, never mind my request for the preamp when RG is disabled. If it's new, then thanks.  Turning on RG, setting it to none, then setting both preamps to the same thing gets the functionality I desired.

The live average bitrate display works properly, but I think it refreshes too fast.  I think it should refresh ever 1 second or so.  It changes too fast for my slow brain to comprehend the numbers. 

I just downloaded the latest version.  I'll see if any of my other problems remain.

Keep it up, this thing is great!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-21 07:31:39
To push it any further maybe support for this (http://www.hydrogenaudio.org/forums/index.php?showtopic=47518&pid=422680&st=0) would make it the ultimate plugin?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-21 08:35:54
I'm preparing another update to smooth some of the streaming problems, along with some control on size of buffers. I also think tooltips are a great idea, so they'll be going in soon.    I'll make the live average display average out across approx. one seconds worth of frames and then update.

@gameplaya15143, Do you want to disable streaming completely? or just disable it if the URL doesn't specify "mp3"? - to do the latter, disable 'detect unknown internet streams'. If you could see if the sync errors go away when you disable both of the streaming tag options, that'd be a help.

@odyssey, can't hurt to look into it 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-21 14:31:48
@odyssey, can't hurt to look into it 

It just came across my mind, when they mentioned simelar routines as used in freeformat... which of course in_mad supports beautifully
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-21 18:31:59
I've uploaded another update, download from the usual place.

This adds basic VBRI tag support, along with buffer options. The buffers that I've set as default for internet streaming are purely guesses made using an Excel spreadsheet, feel free to post values that work for you for your internet connection bandwidth to help me fine tune these.

I've looked into the mp3 surround technique, its interesting to read about, but I'd be facing a lawsuit if I even thought about trying to do anything about it. There is a project called Aud-X but its closed source and takes over the role as decoder.

I'll have a look into tooltips in the configuration box, or perhaps add more descriptive options.

Cheers to all, 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-23 11:46:52
I'm going to have another update ready in around 3 days - I'm not going to have access to my computer for the next few days. I've been working on the VBRI gapless support, and making the ID3v2 editor show data fields (but not edit them yet). Tooltips for options are then next on the list.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-23 11:49:09
Gap removal is only available in 16bit mode (why?)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-23 12:13:41
Hmmm, should work in any output mode. Will look into it for you. Anyone else noticed any further bugs?

Cheers,
Craig
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-23 13:26:43
Hmmm, should work in any output mode. Will look into it for you. Anyone else noticed any further bugs?

Cheers,
Craig

Sorry I guess it was just the 08-20-06 build that suffered. Updated now and it seems to work.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-23 16:19:13
No problem, I've noticed something still a bit wrong with it, but I don't have access to my own machine now to rebuild and upload it. Thanks for testing and reporting your bugs, you help is definitely appreciated, my mp3 collection isn't that varied in terms of different file types and tag types! 

Has anyone found any more tag problems?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hat3k on 2006-08-23 20:13:51
as for me, old winamp's id3v2 editor was more suitable. can you make a tab for oldstyle editing, like it is already for id3v1 now?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-23 22:26:19
Making the ID3v2 editor more friendly has been on the to-do list, perhaps an option to switch between a basic and advanced editor then would be a good idea. The advanced would be as it is now, and the basic would resemble the winamp editor?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-24 22:35:09
The advanced would be as it is now, and the basic would resemble the winamp editor?
Something like that would be great!  I think just the main tag values (artist, title, comment, etc.) would be enough.  There isn't that much room to put the more unused tags.. the advanced editor is there for those.


Ok, downloaded the latest..

Yes I would like to have the option to disable in_mad for streaming completely.  Because sync errors  occur with a VBR mp3 stream, CBR works perfectly fine.  I haven't played around with the buffer settings much yet, perhaps increasing them could help (I'll try that out later).  I just tested out real quick to see, I had set the buffer to the lowest internet speed settings (too lazy to go look what it was), seemed to improve the sync error problem.

The problem with creating the ID3v2 tag is gone for me, it works just fine now    It still freezes winamp when creating an ape tag though (editing tags when the song is NOT playing).

The live average bitrate display looks great!

I've been using in_mad for mp3 playback fulltime for about a week now with no problems at all. So at the very least the decoder seems to be working wonderfully  very stable.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-24 23:34:28
I'll have another go at the APE tag problem as I write in the basic editors for ID3v2 and APE tag pages. The disable streaming option will be in the next release    .

Glad that everything else is working ok. It's been suggested that ID3v2 EQU2 frames are recognised and read, and I was thinking about moving some EQ functionality into in_mad, as winamp can make its own EQ implementation the responsibility of the input plugin - was thinking of using Shibatch supereq as a base. This would then enable these tags to be understood and used without the user changing DSP or EQ settings etc. Anyone else have an opinion on this?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-25 05:15:18
I've been using in_mad for mp3 playback fulltime for about a week now with no problems at all. So at the very least the decoder seems to be working wonderfully  very stable.

I shouldn't speak to soon  I ran into this problem before, but forgot about it.
Mono, 22050hz.... plays double speed. No errors are reported by in_mad. The info page reports the proper info.  If I stop, and attempt to play the file again, winamp crashes.
"lame -m m -a --resample 22" should be sufficient to reproduce this.


It's been suggested that ID3v2 EQU2 frames are recognised and read, and I was thinking about moving some EQ functionality into in_mad, as winamp can make its own EQ implementation the responsibility of the input plugin - was thinking of using Shibatch supereq as a base. This would then enable these tags to be understood and used without the user changing DSP or EQ settings etc. Anyone else have an opinion on this?

As long as there is an option to not use it I'll be happy.  Personally I like to use winamp's built in EQ. Then no matter what format (mp3, ogg, etc), they all sound the same with the EQ applied.  But, it would be a cool option to have
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-25 08:50:10
It's been suggested that ID3v2 EQU2 frames are recognised and read, and I was thinking about moving some EQ functionality into in_mad, as winamp can make its own EQ implementation the responsibility of the input plugin - was thinking of using Shibatch supereq as a base. This would then enable these tags to be understood and used without the user changing DSP or EQ settings etc. Anyone else have an opinion on this?

I've been looking for months for support for the EQU2 tag, but found nothing. An implementation would make this plugin a KILLER!!

I took a look at the supereq - It looks very promising, and works the way I think an EQ should work (no horrible volume boost).

However I really think it should take a standalone application to apply album-EQ settings, or even an analyzer option to adjust spectral balancing (like VolumeLogic does for instance).
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-25 14:21:03
@gameplaya15143, I can't seem to reproduce the problem with 22kHz mono mp3 at any bitrate - what output plugin are you using, and what type of file was played before the problem track? I'll have a look through to see if I can spot a possible problem area.

As for the EQ, I think it'll be suitable for everyone if I do implement a smaller version of Shibatch supereq into in_mad along with reading the EQU2 tags and applying accordingly, and make the ability to integrate the Winamp EQ optional. I'm not sure how to implement the adjustment and EQU2 tag saving - perhaps the analyser idea is a way forward.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-25 16:07:33
I've uploaded another update, hopefully this will have fixed the APE tag writing (and another libid3tag fault linked with it). I have a feeling that linking the APE writing through the libid3tag file structure was probably a bad idea short term, good idea in the long run. The option to disable streaming completely is in too. I've disabled the basic/advanced editor option as its not completed yet, but some code is there. I've done a few more stray fixes while scrolling the code too.

Download from the usual place, and post bugs and comments. As always, all your help is appreciated and needed! 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: zee on 2006-08-25 17:15:13
hell yeah! -- been waiting for this for years!

THANK YOU!:)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-08-25 19:58:27
Nevermind my little mono problem  it's the kb5.1 output plugin that has issues.  Sorry if I caused you a headache 

Ape tag writing works now... but you forgot to remove your debugging popups  "here"

As for sync errors with vbr streaming, as you suspected, disabling shoutcast title support fixes that problem.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-26 17:02:12
I've uploaded another update.

This contains both advanced and basic ID3v2 + APE tag editors, as well as Equaliser code. It is still a bit of work in progress as EQU2 tag reading has not been implemented yet. The Winamp EQ link code does work however - mainly just to test that the EQ was functioning. The EQ code needs to have 32 bit support added, and possibly make the EQ input buffer share the decoder output buffer, stopping the audible end of 'previous' buffer on skip.

List of things to do now,
1. Write in EQU2 tag reading
2. Look at VBR streaming sync errors
3. Think about EQU2 tag writing
4. Make options dialog clearer (possibly with tooltips)
5. Fix other problems 

Thanks for comments in advance! 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-26 17:24:39
Thanks for comments in advance! 


Um... how about "You rock"?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hat3k on 2006-08-27 01:46:02
rapid work i should say. and another wish - you told about tooltips. please do, if you can. also translation would be good. if need help - please ask, i can translate into russian.

also i report problem. i've got song with id3v1 and id3v2 tags. both tags are the same but, in mad shows year in id3v1 but not shows in id3v2. checked with tag scanner - both are same... i can send you this song

also another problem. i have song with no filled fields composer, encoder etc, but id3v2 plugin says DATA.

and another problem - if track is in winamp's playlist and view file info is pushed and i see id3v editor - i cant see tags of file in tagscanner. on closing your editor and refreshing tagscanner i see the tag again
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-27 10:22:14
also translation would be good. if need help.

Danish here

It's beyond my imagination you already are implementing EQU2  You rule so much
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-08-27 14:04:12

also translation would be good. if need help.

Danish here

It's beyond my imagination you already are implementing EQU2  You rule so much


I could translate it to german
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-28 09:20:51
What's causing that few ms of last audio played with the input plugin every time a track is played? I would assume some kind of bufferleak which are not proberly handled maybe in the gapless routines.

It seems to occour every time I enable the EQU2 option, but i've experienced this with other plugins before
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-28 10:04:03
Its caused by the internal EQ being active, the supereq DSP plugin and some other DSP plugins have the same effect - it contains an internal buffer that isn't cleared on skip or track change. If I was to just make it clear, playback would no longer be gapless, it'd be dropping huge chunks. Am thinking about making it either use a shared buffer, or try to lessen the effect by adding buffer flushes where neccessary.

Am slowly working on it    Have got to make the EQ a bit more stable first - some stray crashes are happening when you push it.

@hat3k, I'll sort the DATA problem. The year problem is caused by using an obsolete tag as libid3tag calls it - I'll look into that. As for the file locking, I think its best that only one editor can access tags at once.

I'll get round to implementing a string table for language translations for everyone as well. I will need help to translate to other languages than English and French. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-28 10:15:41
Another thing; is it just me having 24bit problems with gapless files? seems to work sometimes, but not always.

Another edit: To me it looks like it chokes a little on my gapless files (may be my pcutmp3 splitted files again!), it adds a little "chuckle" while it changes track
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-28 10:21:37
I'll have a look into that one, has it just developed with the addition of the EQ? I need to do some work to that whole section. Otherwise, can you tell me the length of start and end padding on the songs that are moving between (Can find that in the file info general page with the LAME tag button). I have noticed an problem, but couldn't track it down and thought it could just be me! Along with the EQ, the decode loop needs some attention. I'm planning to do both together as I sort that buffer problem.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-28 10:34:40
I'll have a look into that one, has it just developed with the addition of the EQ? I need to do some work to that whole section. Otherwise, can you tell me the length of start and end padding on the songs that are moving between (Can find that in the file info general page with the LAME tag button). I have noticed an problem, but couldn't track it down and thought it could just be me! Along with the EQ, the decode loop needs some attention. I'm planning to do both together as I sort that buffer problem.

Well i'm just updating regulary and listen to a lot of different mp3's.... currently a mix I just split up myself, which are pretty ruined

It seems to be a problem only with continous play - a buffer (over?)flow??? If i skip to the end of a track, usually I'm not able to reproduce the problem; sometimes it just chuckles, but often it chokes.

Track 11 SP: 2136 EP: 1152
Track 12 SP: 2314 EP: 1272
Track 13 SP: 2184 EP: 1332
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-08-29 08:53:50

I'll have a look into that one, has it just developed with the addition of the EQ? I need to do some work to that whole section. Otherwise, can you tell me the length of start and end padding on the songs that are moving between (Can find that in the file info general page with the LAME tag button). I have noticed an problem, but couldn't track it down and thought it could just be me! Along with the EQ, the decode loop needs some attention. I'm planning to do both together as I sort that buffer problem.

Well i'm just updating regulary and listen to a lot of different mp3's.... currently a mix I just split up myself, which are pretty ruined

It seems to be a problem only with continous play - a buffer (over?)flow??? If i skip to the end of a track, usually I'm not able to reproduce the problem; sometimes it just chuckles, but often it chokes.

It looks like my problem was related to my buffer-ahead was too small. Increasing it from 500 ms (default) to 1500 eliminates my problem.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-08-30 18:13:37
Ah right, so it was caused by output plugin buffer underrun, I'll have to look into making the plugin start decoding a bit quicker.

I'm in the process of preparing a new update, currently I'm working on the EQ with 32 bit support, and some other quality issues involved. EQU2 support is moving along as well, though I'm still undecided about how to edit and write these tags.

Hopefully I'll have the update available in the next few days. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-09-01 00:16:37
Ah right, so it was caused by output plugin buffer underrun, I'll have to look into making the plugin start decoding a bit quicker.

I'm in the process of preparing a new update, currently I'm working on the EQ with 32 bit support, and some other quality issues involved. EQU2 support is moving along as well, though I'm still undecided about how to edit and write these tags.

Hopefully I'll have the update available in the next few days. 

Don't digg into it too much - Seemed like my laptop was a little picky that day. But speaking of decoding I tried some DiskWriting comparison - Isn't in_mad insanely slow when it comes to decoding? (I havent tried the original in_mad though) I got something like 3x realtime decoding, while in_mp3 was too fast for my diskcontroller to react on

Sounds cool with the tag support. Did you think of just manual selection on EQ curves incl maybe some user-defined presets? This would be great!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hat3k on 2006-09-02 01:01:04
oh goddamn..... russian letters are not seen in both id3v2 tag editor and media library, i see dots instead of letters
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-02 17:55:25
The plugin has no international support at the moment, but it is on the to-do list. At the moment the EQ editor is taking a lot of work. I've also made some changes to the decoding loop in an attempt to improve buffering.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-03 19:13:17
I have finally uploaded a new update to the usual location!

The EQ on this update is now completely functional, with the 32 bit support, and EQU2 tag reading and writing. The EQ editor still needs a little more work, but I thought I'd put this up for those that are testing the plugin. At the moment, it writes one EQU2 tag with a maximum of 128 points to be applied to both channels. The ability to write a separate EQ for each channel is possible, I just need to finish it.

Probably the easiest way to apply a curve, is to link with the Winamp EQ (in configuration), create your setting, then save the active EQ data to some files, and when finished - remove the link with the Winamp EQ.

I've made some more minor changes, the most significant would be the buffer->decode loop no longer waiting around unnecessarily.

I'm going to make some more changes to the EQ editor, and as always your comments and suggestions are welcome.

Thanks 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hellgate on 2006-09-03 21:26:23
Well i download your new update, but it hangs my pc, winamp takes 99% of cpu in task manager. All older updates have worked well.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-03 22:25:11
hellgate, does it lock on loading Winamp, or on trying to play a file? In either case, try entering the registry and deleting "HKEY_CURRENT_USER\Software\Winamp\MAD Plug-in" to reset the plugins defaults, and also disable any DSP plugin you might use. What output plugin are you using as well?

Thanks in advance

I have just noticed that its causing things to take a long long time accessing files......
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-03 22:53:03
OK, I've uploaded another update to the usual place.

I've added a sleep in, as the decode loop thread was hogging processor time.
@hellgate, does this update fix your problem?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-09-03 23:10:51
I have finally uploaded a new update to the usual location!

The EQ on this update is now completely functional, with the 32 bit support, and EQU2 tag reading and writing. The EQ editor still needs a little more work, but I thought I'd put this up for those that are testing the plugin. At the moment, it writes one EQU2 tag with a maximum of 128 points to be applied to both channels. The ability to write a separate EQ for each channel is possible, I just need to finish it.

Probably the easiest way to apply a curve, is to link with the Winamp EQ (in configuration), create your setting, then save the active EQ data to some files, and when finished - remove the link with the Winamp EQ.

I've made some more minor changes, the most significant would be the buffer->decode loop no longer waiting around unnecessarily.

I'm going to make some more changes to the EQ editor, and as always your comments and suggestions are welcome.

Thanks 

This is SO cool. I only see one possible problem with this in the future: When lowering mid-bands the overall gain will be lower than a calculated replaygain value. But if the thought was to make a more interative EQ, a slider for gain-tag could proberbly be implemented?

Edit: Well actually now I only need a preset function to remember used EQ's     

Another edit: Okay it's actually quite a hassle to edit EQ without ability to hear the real results (Or maybe i'm just not best friends with Winamp EQ!)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-04 00:02:20
If you enable the Winamp EQ link, and turn the Winamp EQ on, then check the store active EQ box - as you edit the Winamp EQ you should be able to hear the changes (after a buffer time lag) and these will be stored to the file when you save. You have to remember to change/disable the Winamp EQ after otherwise it'll apply them twice (the file EQ, then the Winamp EQ).

Was thinking of making the EQ display larger and/or easier to use - so can click to create a point for adding to the EQ, along with a Preview option.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: benski on 2006-09-04 00:04:15
If you enable the Winamp EQ link, and turn the Winamp EQ on, then check the store active EQ box - as you edit the Winamp EQ you should be able to hear the changes (after a buffer time lag) and these will be stored to the file when you save. You have to remember to change/disable the Winamp EQ after otherwise it'll apply them twice (the file EQ, then the Winamp EQ).

Was thinking of making the EQ display larger and/or easier to use - so can click to create a point for adding to the EQ, along with a Preview option.


In your Init() function, set mod->UsesOutputPlug |= 2  to disable Winamp's EQ  (or any time, just be aware that winamp clears all but the first bit when it forst gets your In_Module from winampGetInModule2)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-04 00:16:03
I've already included that, along with module.UsesOutputPlug |= 8 to disable the upcoming RG support I had read about on the Winamp forum. The double EQ is applied by in_mad as it takes both the file and the Winamp EQ specified settings.

@benski, Talking of this international support, how do I go about it with the Winamp DLL interfaces? I thought Unicode, but I think I read on the winamp forum that winampGetExtendedFileInfoW etc. was unsupported and not really to be used. Any pointers would be of great help!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: benski on 2006-09-04 00:23:54
I've already included that, along with module.UsesOutputPlug |= 8 to disable the upcoming RG support I had read about on the Winamp forum. The double EQ is applied by in_mad as it takes both the file and the Winamp EQ specified settings.

@benski, Talking of this international support, how do I go about it with the Winamp DLL interfaces? I thought Unicode, but I think I read on the winamp forum that winampGetExtendedFileInfoW etc. was unsupported and not really to be used. Any pointers would be of great help!


You can implement winampGetExtendedFileInfoW in addition to the existing winampGetExtendedFileInfo.  It is supported from 5.22 onward, but is safe to declare even with old Winamp versions.

Declaration:
Code: [Select]
extern "C" __declspec(dllexport) int winampGetExtendedFileInfoW(const wchar_t *fn, const char *data, wchar_t *dest, int destlen); 
/* return 0 to indicate 'tag name not understood', 1 to indicate success (set dest[0]=0 to indicate empty tag) */


Implementing the rest of the unicode plugin stuff isn't absolutely necessary, Winamp does a decent job of giving you a "fake" filename if the real filename has foreign characters.  Especially since the majority of in_mad users are probably using older Winamp versions.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-04 00:32:55
Ah right, thanks! Your probably right about everyone using older Winamp versions. I'll get round to adding it eventually.    Cheers benski!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-04 02:31:37
 you broke it

New one is CPU hungry. 100% during playback. (maybe do to the quicker playback thing?)

Why is the 'buffer' tab present when a file isn't playing? Not present in previous version. (found out the hard way when clicking on it froze my whole system  )

I'll stick with the previous version till those problems are fixed.  Good luck
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-04 02:56:09
I'm very interested in these CPU hogging problems, though I'd have thought the previous Sleep would have solved it, with the difference that it decodes some audio data in between.

I've uploaded another update, with the Sleep moved to a better position. If this fails to work, it looks like its back to the old way or maybe include an 'experimental' option to allow data to be decoded while waiting for the output plugin to make space.

@gameplaya15143 and hellgate, what CPU type and speed are you running?

EDIT: I've also fixed the buffer tab problem, bit of a copy n paste error when I added the EQ tab! sorry about that!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-04 04:02:30
I've also fixed the buffer tab problem, bit of a copy n paste error when I added the EQ tab! sorry about that!
lol, it happens 

The cpu issue is gone 

Running a P4 2.4GHz by the way.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-04 12:50:59
I think I've figured where the CPU hogging came from, the last update should be OK for all. Under certain circumstances, there would be no situation where the output buffer was full, and the output plugin wasn't wanting data, causing it to forever decode and output, running the thread at full power.

I'm currently trying to add more functionality to the EQ editor.

Cheers for all help!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hellgate on 2006-09-04 18:09:50
Thank You, best "customer service" in world . Ur new update works
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-05 14:29:02
I've uploaded a new update.

This now allows both left and right EQ to be defined and saved to a file. I've included a preview mode, so you can hear changes as they are made. You can also now add a point by double clicking the EQ window. Basic tooltips can also be found in the configuration dialog box.

I'm getting about ready to ask people to make some langauge translations.

Keep your comments and bug finding coming, and as always thanks for everyones help. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-05 16:27:02
I doubt this has changed in the latest update...

Replay gain problem:
Lame encoded mp3s that don't store RG data should use the preamp for files with no RG.  It is not doing that.  Instead it pretends that the RG is 0dB.  This happens with older versions of lame (which don't calculate track gain) and with newer ones as well when RG calculation is disabled.

Lame tag problem:
Doesn't seem to read the lame tag for 24khz samplerates and below (at least I can't view the tag info).  Shows xing tag as being present (which is correct as it is there), but does not report the lame tag.

There was something else too.. but I can't seem to remember it 
Oh.. just remembered.

VBR seeking:
It's not accurate  in_mpg123 is.  It's not a big deal, just a bit of an annoyance 

About the advanced tagger... I was kind of hoping for a button right on the ID3v2 and ape tag tabs to 'go to advanced mode'.  It's a little bit of a pain to switch between the two as it is.  Problem is, there doesn't seem to be enough room for a 'go advanced' button on either tab.  Something to think about.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: [JAZ] on 2006-09-05 16:28:36
MoSPDude, good work with the plugin. It is very informative and seems to work well in general.

Yet, i would like to point out that the way you're doing buffering is probably not the best one.

I've got a 6M down/512Kbit up ADSL line, with relatively low ping times and was getting skips on some streams until i decided to change some settings, (i also have a low audio buffer ( 200ms ))

I changed the "Input" buffer to 24KB ( 16 was also good ), while leaving the Output at 128KB ( I used to have 96KB with in_mp3 anyway ), and that solved the problem.

Yet, with this setup, i still wasn't getting the results i was expecting... the network activity still showed chunks of data being downloaded non-constantly ( say.. 30KB/s during two seconds, then 0KB next second, or a peak of 60Kb/s and then two seconds of 0KB/s).

So what are you doing for buffering? I would say a good way to do so would be

1) keep connection open (i assume you do so, but just in case)
2) download in chunks of "Input buffer" size until you've filled the output buffer.
3) when the output buffer has played at least a size as big as "input buffer", try to fill the input buffer again, and keep until output buffer is full again.

Good defaults for these would depend on stream line, of course, but Input buffer has to be clearly smaller than the output buffer.

You might want to check the network usage with the in_mp3 plugin. you'll see that the download rate keeps much around the stream bitrate, while with in_mad, it's always peaks and valleys.  (check with the task manager)

Also, not sure if it will keep happening, but right now, playing this link hangs in_mad  (no CPU usage, just hung): http://www.m1live.com/listen/musicone_hi.pls (http://www.m1live.com/listen/musicone_hi.pls)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-05 17:51:52
@[JAZ], OK, I've just tried http://www.m1live.com/listen/musicone_hi.pls (http://www.m1live.com/listen/musicone_hi.pls) and in_mp3 can't connect to it either. At the moment in_mad is missing connection timeouts etc and this is why it hangs.

The buffering does need to be re-written - its been inherited from the MAD 0.14.1b plug-in. Its all included in the decoding thread loop. Basically, it does what you suggest anyway, but where and when the decoding occurs is an issue. Basically, 3 main things need to happen and they can't be done simultaneously, that is fill input buffer, decode, and maintain a full output buffer. The current decode loop goes basically like this,
1. Enter input section.
2. If file, read in to fill input buffer. If stream, read in 'metaint' bytes, process shoutcast metadata if needed, output some audio, loop to fill input buffer.
3. Enter decoding section.
4. Check if able to decode a single frame, if not enough data in input buffer goto step 1 or other problem then handle it or abort.
5. Decode a single frame.
6. Output audio data if output buffer full, until one frame has been sent or output plugin signals its full.
7. If not told to stop, loop to 4

One of the previous major problems with streaming was that when it was trying to get data from the stream, as no audio data was being sent, the output plugin would buffer underrun. This was helped by placing audio output with the data reading, though the main reason for a larger output buffer initially was gapless output (on detect of EOF, it hacks off the end of the buffer accordingly for gapless).

The reason for it downloading a chunk suddenly, then none for a while, is the process of input section downloading to fill input buffer, then the decoding and output section afterwards decoding it.

I could try to make it download continuously to re-fill the input buffer on every loop, but for file usage when I made it decode and output continuously, some people reported 99-100% CPU usage as was non-stop decoding and outputing a single audio frame. Streaming, decoding and outputing continuously might do the same thing.

I'll get round to having a proper look at it eventually.

@gameplaya15143, The LAME tag RG problem is partially to do with lame, it always marks the file as having that information - even though it hasn't (well its set to 0dB). I can make it ignore it if its 0dB, but some files could really have RG set with 0dB. I'll have a look into the LAME tag less that 24kHz samplerate issue. VBR seeking needs to be implemented, it ignores the tables in the XING tag (and the VBRI tag too).

I've been thinking of making the dialog boxes bigger, then can have more room to do the EQ editor. 

Will hopefully get another update done soon addressing some of the above. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-05 18:15:47
I've made that change I thought of while writing the above, and it seems ok on my system. Internet streaming is now continuous in small blocks. I'll upload it later, for people to test and see if it bring 99% CPU issues back.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-06 01:14:36
I've uploaded another update to the usual location.

This has continuous internet streaming, internet connection timeouts, it ignores LAME replaygain if set to 0dB, has XING VBR seeking using table implemented, and now shows LAME tag when used with MPEG-2 encoded files (24khz rate and less).

Thanks for all bug reports and suggestions. I'm going to resize the dialogs to allow for a "Basic to advanced button" at gameplaya15143 request, and add more touches to the EQ editor.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-06 18:57:59
I've uploaded another minor update.

This has the Basic <-> Advanced editor mode buttons, and now runs the id3v2 text fields through the Windows code page conversion to ANSI strings. I'm interested if this will allow more foreign characters to be displayed that the libid3tag straight conversion does (obviously depending on the users ANSI code page settings).
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hat3k on 2006-09-07 09:49:04
i wonder, what's the problem is it : i see dots instead of names of SOME russian song(mp3) in winamp's ML and PL, but all of them are god with tag editor. also i see russian words in other songs in ML but i see abracadabras in id3v2 and normal names in id3v1,.... i may send you problem files, but you cant see russian symbols i think
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-07 11:05:49
The dots are displayed when characters not in the current windows ANSI code page (or libid3tag conversion page) are converted from Unicode. If in the latest release now, when you load the tag editor they are display correctly, but not in Winamp Media Library or Playlist Editor, I'll have to have a look at the interface code to Winamp.

I've had a trial look at converting the entire plug-in to a Unicode implementation, but this requires a LOT of work, but it would solve your problem within the plug-in. I'm going to add the Unicode Winamp DLL interfaces so will be ready for a Unicode winamp.

I'm also getting ready for help adding language translations.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-08 10:57:25
I've uploaded another update, this includes some EQ presets, and winampGetExtendedFileInfoW for Winamp to get Unicode tags.

Download from the usual place.

@hat3k, If you could see if this solves your problem, then I'll write in the other Unicode extended file routines.

If anyone wants to have a go at language translations, load "resource.rc" up in a trusty text editor, and change everything thats in English to desired language. If you do have access to a proper resource editor, you can change the language codes too, but as long as you note what language it is in somewhere I can make the changes when I collect all the translations together. I'm going away for the weekend, so I'll collect and sort them out after then.

Cheers for everyones help, bug finding and suggestions. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-08 21:14:46
I think it would be helpful to say what heppens when certain things are disabled.  ie. detect unknown streams, disabling title streaming, etc.

ID3v2 year display (simple mode)
ZOBS, TYER, \0 1 9 9 7 (switching from advanced to simple and back erases this tag!!) and simple mode does not display the year
year is also stored TDRC, iso8859, 1997; this also does not show in simple mode
mp3infp shows the year in its year field just fine 
The 'advanded' button is convienient, but I think it might be having a few issues.  If I change advanced/simple tag mode in the main config, it doesn't lose that year tag of mine.
Wouldn't hurt if the 'advanced' button was independent of the other (ape/id3v2 depending) and didn't set the 'default' view as defined in the main decoder config.. just my thoughts.

When I read my lame mp3 files with lametag, replaygain shows as <not stored>, it does not say 0dB.  I would think they would be stored differently, but I surely don't know.  Anyways, the RGless preamp is still not being applied to my RGless lame  mp3 encodes.

"XING VBR seeking using table implemented" Doesn't seem to be working, in_mpg123 is right on with my test vbr file.

Tested for streaming... The input buffer remains full, while the output buffer remains extremely low.  Many many many buffer errors reported, along with the usual sync errors from my vbr test stream.  Still, disabling shoutcast title support fixes the sync error problem.  If the output buffer ever manages to fill, then the buffer errors go away, but this seems to take a while if it happens at all. (ok, I just watched the output buffer fill up then drop all the way back down  )

No CPU usage problems here 

I don't like the amount of negativity in this post.. This thing is wonderful anyways!  Keep it up.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-09-10 18:11:08
Is it just me getting skips from time to time? I just noticed twice - At first I just thought it was an error in my mp3-file. (Edit: It doesn't happen often - maybe for every 5-6th file, but it sounds like it skips a frame) Edit: Nevermind, it WAS errors in the files 

Also I think CPU usage of 10-18% is kinda much - for a decoder (on my 4800+ X2). Try decoding a file with in_mad and afterwards with in_mp3 - in_mad is 5-6x for decoding where in_mp3 decodes as a lightning strike!

But BIG thumbs up for the EQ now with presets - It's REALLY cool!!   
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-10 18:35:55
Ok, I'm back. Looks like some heavy beta testing! 

First thing, the buffering, I think I'm going to take the main functional decode sections (because they work) and tear the rest apart. I've only been "patching" from 0.14.1b, and as such its now time for a rethink.

The ZOBS TYER problem is due to libid3tag automatically upgrading an ID3v2.3 tag to an ID3v2.4, where TYER is an obsolete tag and is removed and replaced by a TDRC frame. I typo'd in TDRL not TDRC in my code, so that's fixed - but TYER will still be removed. I'll probably add an ID3v2.3 compatability mode.

The lame tag problem has been properly solved now, will be in next update I promise  .

The XING VBR seeking probably isn't that accurate still, but at least now it uses the tables, before it completely ignored them! I'll get round to that.

CPU issues.....I'm still a bit worried, as odyssey said, its high - but is it due to libmad naturally? or how the plugin is handling the buffer? I don't know.

If I rethink the decoding loop as a priority - hopefully that will clear usage issues, then start on the rest. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2006-09-10 18:54:37
Also I think CPU usage of 10-18% is kinda much - for a decoder (on my 4800+ X2). Try decoding a file with in_mad and afterwards with in_mp3 - in_mad is 5-6x for decoding where in_mp3 decodes as a lightning strike!


Well, the pure decoder surely doesn't cause such a high CPU load. I'm  running in_mad on a P4 2.6 ghz, the CPU usage varies between less than  1% and 4%, even while using a slightly animated modern skin. With the  internal equalizer and dithering as well as noise shaping enabled  (commonly i don't use these options)  the task manager shows a CPU load  that stays a bit closer to 4% than with these options disabled. Nothing  really spectacular, therefore there must be something else wrong on  your machine.

Quote
CPU issues.....I'm still a bit worried, as  odyssey said, its high - but is it due to libmad naturally? or how the  plugin is handling the buffer? I don't know.


Obviously it can't be libmad generally that's causing the issues concerning the CPU, 'cause in my case in_mad...

Quote
...decodes as a lightning strike!


I wonder whether some other winamp plugin interferes with the functionality of in_mad on odyssey's machine. Maybe DSP or a software resampling plugin?

Edit: Removed "surround sound plugin" since that's the same like a "DSP plugin". Stupid...
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-09-10 20:35:12
Admitted I used a DSP, but without in_mad still takes 4-8% CPU power - quite much on this kind of CPU! in_mp3 uses 1-5% actively, but I don't think we can base the performance on active CPU measurements.
therefore there must be something else wrong on  your machine.

You need to prove your claims - Why would one plugin work fine and another conflict with things on my machine?? Try my test using the diskwriter output or some null plugin to see the decoding speed.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-11 02:24:07
I've uploaded an update, with the changed decoding and buffering loop. I've taken each main section, and re-wrote it into a new loop.

A quick and not very accurate test of disk writing times shows the new in_mad to be approx 0.8x speed of in_mp3. The old one roughly tested to be 0.6x.

These are no measure of speed, but I can say that my machine sees an improvement, hopefully you'll all experience the same. Then again, mine had an improvement when everyone else had 99% CPU usage! 

Cheers for all comments in advance!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2006-09-11 10:58:50
You need to prove your claims[...]Try my test using the diskwriter output or some null plugin to see the decoding speed.


It's not a claim, it's a suspicion. Since the pure in_mad decoder isn't much slower than in_mp3 (in a quick diskwriter test i measured 6 seconds for in_mp3 and 7 seconds for in_mad, tolerance + - 1 second due to inaccuracies caused by using my watch for measuring) the problems you experience might indeed be caused by some unknown problem which has to be found to be able to fix it. Your machine should perform much faster than mine, due to its better processor power, therefore there must be a certain issue that wasn't mentioned in this topic yet. That's why i suspected another plugin to interfere with in_mad's functionality. As you admitted yourself, an active DSP plugin falsified your results.

Quote
Why would one plugin work fine and another conflict with things on my machine?


Maybe due to a decoding bug in libmad that isn't present in the Fraunhofer software used by in_mp3. This bug could cause further issues when the decoded data's being processed in certain output or DSP plugins. But judging by the data you mentioned above, this isn't the case. 4% till 8% without DSP is still noticeably much for an Athlon 64 X2 4800+.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-11 11:35:09
In defence of in_mad, and how the decoding loop works, several things could be causing these differences in CPU usage.

I assume we're all using Windows XP. How different operating system schedulers handle threads is an issue. The 99% CPU issue was solved by reinserting a Sleep(20) command (I'd removed it, believing it to be pointless waiting around) - effectively putting in_mad decode thread to sleep for 20ms, I assume allowing other threads in the system to run properly, otherwise in_mad kept looping (under certain circumstances) running at full CPU usage. "Background" tasks, will also change how much process time in_mad has.

A quick note about in_mp3, its default decode thread priority is Highest, where in_mad is Normal. I haven't tried increasing in_mad to Highest priority setting, or decreasing in_mp3 to Normal, but these will again have an impact on CPU usage and decoding speed.

A DSP plug-in (and any extra processing by in_mad) will contribute to an increased CPU load, but I don't think CPU values are anything accurate to go by, it varies between systems, CPU, memory, background workload etc.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2006-09-11 11:54:05
A quick note about in_mp3, its default decode thread priority is Highest, where in_mad is Normal. I haven't tried increasing in_mad to Highest priority setting, or decreasing in_mp3 to Normal, but these will again have an impact on CPU usage and decoding speed.


Thanks for that clarification. I haven't noticed the differences regarding thread priorities in both plugins so far. Would make sense for the people experiencing performance issues to test whether changing the thread priority resolves these.

Quote
"Background" tasks, will also change how much process time in_mad has.


I assume that odyssey disabled all running tasks except Winamp itself (and the system processes, of course  ) before running his tests. If he didn't this whole discussion would be nonsense anyway.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-09-11 12:01:13
Since I'm currently at work I'm using another PC for my test now. No DSP's and both plugins set to priority "Normal". (Btw. I was unable to find a "null" plugin that would decode independent of timing in files)

For in_mp3 I measured around 3 sec decode of a 2:30 track. in_mad did this in 14 sec (still better than before, but I don't have one of the older versions here to compare).

I was unable to measure anything on this PC with the priority set to "Highest"; in_mp3 would decode faster than Winamp could react (possibly a combination of the high priority and my disk being the bottleneck), and in_mad would just make Winamp freeze until it was finished.

Junon: Are you sure you are switching between the plugins? 

I assume that odyssey disabled all running tasks except Winamp itself (and the system processes, of course  ) before running his tests. If he didn't this whole discussion would be nonsense anyway.

This would be sufficient for small differences tests - When the difference is this big, the environment does not have a great impact.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2006-09-11 12:35:50
Junon: Are you sure you are switching between the plugins? 


Of course. Every time I restart Winamp after having enabled/disabled in_mad and having added/removed the MP3 extension to/from in_mp3 I view the file info to ensure that the correct plugin's currently active. The properties window created by MoSPDude looks quite unique compared to standard in_mp3's one.

Edit:
This would be sufficient for small differences tests - When the difference is this big, the environment does not have a great impact.


That might be true. However, it's hard to tell since I don't know which processes are exactly running on your machine while testing the plugin.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-12 11:41:33
I'm currently working on an ID3v2.3 mode for libid3tag, at the moment it writes "hybrid" ID3v2.3 tags, that is ID3v2.3 tag and frame structure with ID3v2.4 frame types. I'm wondering if this is acceptable for a compatability mode or not?

I think I'm going to aim for it to leave both types of frames in (for example both the ID3v2.3 TYER and upgraded ID3v2.4 TDRC) and decide what to write when it comes to update the file tag depending on desired written version. Either this, or override libid3tag updating behaviour - keeping ID3v2.3 frames as ID3v2.3 frames, and ID3v2.4 frames and ID3v2.4 frames. All ID3v2.2 and less tags, will still be upgraded to ID3v2.4 type regardless of what happens.

Opinions on the above are very welcome 

I might even fix the CRC problem I've been having with ID3v2.4 tags while I'm working on libid3tag. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: odyssey on 2006-09-12 16:34:57
Why has in_mad begun to stumple every time you seek?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-13 17:47:51
I don't know why it stumbles, and I can't reproduce it, I have been making some more tweaks to improve seeking, so maybe that will clear it. Does it do it on all files, or certain types of mp3? For the moment, I'm working on the libid3tag library.

If anyone has any problems like this, if your output plug-in has a status window, then you can view both the output plug-in status and in_mad buffer status - and see what happens eg any buffer under-runs etc.
I do this with the DirectSound output when I'm testing buffer behaviour as both together give a good indication of the input->output plug-in connection.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-14 16:19:41
I've uploaded another update, download from the usual location.

This includes working ID3v2.3 tag support (hopefully solving TYER issues), changes to the Advanced/Basic editor switching, changes to seeking (I think this did fix odyssey skipping problem when I checked against last version) and a few other minor things. I had also updated the EQ FFT routines used by shibatch supereq to the last version available.

A quick note on the ID3v2.3 tag support,
no writing, no conversion prevent - all tags will be written as updated ID3v2.4
writing, no conversion prevent - all tags will be written ID3v2.3 (with no change to frames!)
no writing, conversion prevent - all tags will be written ID3v2.4 (with no change to frames!)
writing, conversion prevent - tags will remain the same version

Thanks for all comments in advance. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-17 13:04:47
I've uploaded another minor update.

This addresses some VBRI issues (although I've not fully tested as I only have 1 file with a VBRI header!) and some work towards a multi-lingual version.

If anyone has found any more issues or bugs, please post and I'll look into it.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LITBe on 2006-09-17 21:31:43
For a start sorry for my English...
Thank you for updated plugin.
But can you fix one bag?
Example:
When I want to display in playlist TAG (for example) "Encoder" I write in options of plugin %#TENC
and all good, but only if file have in field "Encoder" something... If file have not this field winamp crash...
If | Else don't help.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2006-09-17 21:53:48
Obviously the plugin only supports displaying the kinds of tags shown when clicking the "Help" button in the Title/Tags tab. I've played around with a few alternative entries, including yours, only to see all of them crashing the player, no matter if the required field was present or not.

But anyway, even in case this was fixed, your example still only worked correctly using files tagged with ID3v2. You'd have to define a whole mass of IF|ELSE conditionals for the player to be able to also read the tags of files which contain nothing but ID3v1 or ID3v1 and APEv2. Might become a bit complicated - at least for me it was a bit troublesome to find out how to define my current "%?1<%1 - >%?3<%3 - >%?0<%0 - >%?2<%2|%8>" setup. But maybe I was just slow on the uptake. 

Edit: Modified my answer a bit because I misunderstood the question.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-18 11:48:56
I've fixed the above ready for the next update, I'm just finishing some work on moving all fixed strings to the resource file.

If the plug-in can't find a field it places a '?' - to tell you its not there. You can use '%?#XXXX<%#XXXX>' to override this. I have been thinking of extending this to accept a similar syntax to Winamp 5 advanced title formatting.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LITBe on 2006-09-18 14:27:35
One more request to you.
It will be very good for me if on the "File info..."(Alt+3) dialog in field ID3v2 in Basic mode will be a button "Copy from ID3v1 Tag"...
I know that this button is in the advanced mode, but...
By the way, when I copy ID3v1 tag to ID3v2, and tag fields not in English, ID3v2 display not readable symbols(but ID3v1 tag display good).
Hm... I see that always when file have ID3v2 tag not in English it display not readable symbols but always ID3v1 tag display good!?
Can you fix this?
Thank you once more!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Domin on 2006-09-19 12:33:40
Very nice plugin im loving it 

Any chance you can fix shoutcast title support from this stream:

http://stream.mmradio.dk:8000/listen.pls (http://stream.mmradio.dk:8000/listen.pls)

It works fine using standard in_mp3.dll and it also plays if i disable title support in in_mad.dll but i wouldt really like the title to work in in_mad.dll to 

Thanks for a greate plugin
Domin
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-19 17:10:04
I don't see any mention of this so I assume it hasn't been fixed (I have the version from last week sometime).  Buffer errors on seeking!  ..which then cause sync errors.  Older versions did not suffer from this.

The issue with the ZOBS year no longer occurs (neither of the 2 new options are checked).  It is now safe to switch between basic and advanced mode

RG for non-RG'd lame encodes now seems to work properly, using the preamp for no-RG as it should.

Keep this good stuff coming
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-22 17:32:46
I'm preparing a new update, this should play more internet streams with shoutcast titles happily now.

The buffer errors on seeking shouldn't cause any audible problems, they're caused by the new seeking and shouldn't really be counted as errors - though sync errors shouldn't occur at all as the stream is resync'd before further decoding. I've made some more changes so hopefully that'll clear it up.

The ID3v1 to v2 character problems are in libid3tag, I'll make it use the Windows conversion routines. The basic mode copy from ID3v1 button will be added as well.

I'll post again once I've uploaded it. Has anyone found any other bugs I might get to look at before I upload an update?

Thanks to all 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: pepoluan on 2006-09-22 17:43:12
Gee... this plugin is well on its way to becoming like Lancer editions... the "Build-of-the-day" club...

Heck... haven't even copied the zip from my office PC to my house, you already released a new build....



Anyways, great work, MoSPDude! Much appreciated!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-22 19:25:15
I've uploaded the update to the usual place.

@pepoluan, I just like things to work for people 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LMS on 2006-09-22 22:37:13
MoSPDude, thanks for this plugin. I am curious about the dither used. You mentioned in the original post that you are using Gaussian dither. If I don't tick "dither" and set the output to 16 bits, is the plugin simply truncating the data at 16 bits?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LITBe on 2006-09-22 22:49:01
Thank you.
But not English simbols in ID3v2 still displays incorrect 
I know that in Unicode all good, but nevertheless maybe you fix this for not only Unicode symbols?
(I'm still wondered because ID3v1 at the same time absolutely correct    )
By the way when copy tag from ID3v1 to ID3v2(pressing the button) field "Gentre" don't copy correctly.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-23 11:17:55
@LMS, effectively yes, without any dither or noise shaping the lower bits from libmad fixed output are simply removed to give you your desired resolution.

@LITBe, they are some strange things in libid3tag but I've fixed the Genre problem. However, the foreign characters are still confusing...first of all, what operating system are you running? and what regional settings is windows set to? The ID3v1 tag will be shown in your regional ANSI code page, but the ID3v2 tag will want to be shown in Latin only characters, so I made it though go through windows conversion to Unicode and use that.

I'm going to keep thinking about this character conversion for a bit longer, then I'll upload another update.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LITBe on 2006-09-23 14:38:52
@LITBe, they are some strange things in libid3tag but I've fixed the Genre problem. However, the foreign characters are still confusing...first of all, what operating system are you running? and what regional settings is windows set to? The ID3v1 tag will be shown in your regional ANSI code page, but the ID3v2 tag will want to be shown in Latin only characters, so I made it though go through windows conversion to Unicode and use that.


Windows XP SP2
All regional settings is set to my language.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-23 15:41:03
@LITBe, can I ask what your language settings are? and specifically on the Advanced tab of the Regional and Language options in the control panel, what is the language for non-Unicode programs? It could be that I'm passing flags which aren't valid for your code page and its falling back to Latin coding only.

Thanks 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LMS on 2006-09-23 16:10:08
I may be wrong, but it seems that the plugin is not handling the dither and noise shaping functions correctly. To test this, I wrote 4 wav files using the Wimamp diskwriter, each with the MAD plugin set to output 16 bits. The four files were Dither Only, Noise Shaping Only, Both, and Neither. I loaded all four wav files into Foobar 0.8.3 and bit-compared them. "Dither Only" and "Neither" were bit-identical. "Both" and "Noise Shaping Only" were not identical.

Thanks again for the plugin, I'm really enjoying it. I think we are all impressed by your efforts to fix bugs and add features that people request.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-23 18:29:14
It could well be not adding dither correctly, I had doubts as to whether the noiseamp value was right or not. I'll look into it.

Hopefully, I might have fixed this international character problem. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LITBe on 2006-09-23 18:56:40
@LITBe, can I ask what your language settings are? and specifically on the Advanced tab of the Regional and Language options in the control panel, what is the language for non-Unicode programs?


Russian in ALL Regional and Language options and in Advanced tab too
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-23 23:36:34
When seeking, buffer errors are no longer reported.  Sync errors still sometimes occur and there are a LOT of 'other' errors.  This IS an audible problem.  Just step by 5sec using the arrow keys, and watch the errors add up.  VBR seeking isn't accurate yet either 

Still sync errors with VBR streams (disabling shoutcast title support still fixes that problem).  Doesn't get titles from my icecast2 server even when titles are enabled.  When starting a stream, the sound skips for a while (sounds like buffer underruns), pausing playback for a few seconds fixes this.  It also isn't decoding shoutcast mp3 streams even with streaming enabled (grabs streams ending with ".mp3" just fine though).

It also chokes on mp3s with bad headers (44.1khz stereo, but reported as 48khz mono, etc.).. shouldn't it be able to pick up on stuff like that when it's wrong? 

Anyways.. keep up the great work.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-24 10:26:35
I've had a look at the resync section - I'd based it on 0.14.1b, but now rather than try to decode only two frames, it'll search for the first full frame and then continue. libmad seems to seek only one byte forward when it lost has lost sync meaning that is has to loop potentially nearly a full frame of bytes to find the next sync. The other errors (bad data ptr, bad huff table, bad sample rate, bad bitrate) were due to libmad thinking it had found a frame and then changing its mind! Hopefully its sorted now 

I doubt VBR seeking will ever be 100% accurate as there is no sample counter, I could make it use the xing tables to seek in the file to the correct whole percentage then sample skip to the correct place, I don't know how much extra processing this would require.

Do you have any links to VBR streams I can test? I can't seem to find any. There is a problem if shoutcast metaint is set to less than 2048 bytes, or your first metadata block is sent before your first (valid) mp3 frame. I'll have to think of a way to solve this elegantly. The shoutcast failing could be due to the above, or the ICY header parser - I'll tweak the parser a bit and see if that helps.

The mp3 header problem is difficult to solve, the plug-in uses the first header to open the output plug-in. I could make it scan for second or third header and hope thats correct. It'd be difficult to have it close and re-open the output plugin mid-track.

I'll have a think about the above, thanks for all comments and problems you find 

EDIT: I'll upload the update later, I might add a stream saving option to 'record' internet streams so it can help solve these streaming problems.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Domin on 2006-09-24 17:48:10
This plugin is the best :-)
My radio stream now play and show title correct, thanks for that ;-)
The save stream sounds like a nice feature 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: k.eight.a on 2006-09-25 01:06:08
@ MoSPDude: I really much apperciate your work, thanks a lot!
I have a "feature request"... I'd love to have a button Cancel in the ID3Tag window do "Cancel All".
I mean when I select several files in the playlist I click Save and I see ID3Tag window of the next file but when I click Cancel I see the same as before. Contrary to this the original WinAMP mp3 decoder don't view ID3Tag windows when Cancel is clicked.

OT: I hope I have cleared up enough what I want, sorry for my bad English.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-25 02:23:47
I uploaded an update to the usual place.

I've had a go at tweaking the shoutcast header parser, and added an internet streaming save function in the configuration, its not that advanced but enough for recording streams to provide debugging information.

@k.eight.a, will look into making the cancel button cancel all.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-26 01:02:49
I doubt VBR seeking will ever be 100% accurate as there is no sample counter, I could make it use the xing tables to seek in the file to the correct whole percentage then sample skip to the correct place, I don't know how much extra processing this would require.
Might be worth a try to find out.

Quote
Do you have any links to VBR streams I can test?
I don't know of any myself, although it is a perfectly acceptable practice.  I just run oddcast3 and icecast2 on my own machine for testing.  Running shoutcast server on my own was when I first realized mad wasn't decoding it even with streaming enabled.  All metadata intervals are at whatever the defaults are (1024 bytes maybe).  I'll test with the new version once I get a chance to download it.

Quote
The mp3 header problem is difficult to solve, the plug-in uses the first header to open the output plug-in. I could make it scan for second or third header and hope thats correct.
Yes I have a few corrupt files in my library  (only the beginnings and ends though).  I would have it check the first 2 headers, if they are the same, then begin playback. If not, keep searching untill 2 consecutive headers have the same info.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-27 16:49:33
I'm preparing a new update.

I've attempted to make input buffering more efficient, along with making it check for a set of identical headers to solve gameplaya15143 problems  . I've fixed a large problem with gapless playback and internal EQ, there was data left in the EQ buffer that would be emptied into the next song - so when you disk write it would catch part of the previous song. This has been solved now. Dither is also now applied correctly.

With the release of Winamp 5.3 I'm going to look into getting global replaygain settings from Winamp. I could do with some clarification as to how Winamp is applying the replaygain settings though. For the moment, you still need to set them through in_mad configuration as this will be separate to the rest of Winamp.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-09-27 21:07:29
I was playing around with VBR mp3 streams last night (yesterday's version of in_mad).  VBR mp3 streams from a shoutcast server work perfectly fine  no sync errors, titles show up perfectly.  When using icecast2 server, sync errors galore, and no titles.  I was under the impression that both icecast2 and shoutcast streamed mp3 titles the same way.  I'm beginning to think this is not the case.

www.icecast.org should have the info needed to hack in icecast title support.  Good luck with all the great improvements.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-27 22:09:59
I was playing around with VBR mp3 streams last night (yesterday's version of in_mad).  VBR mp3 streams from a shoutcast server work perfectly fine  no sync errors, titles show up perfectly.  When using icecast2 server, sync errors galore, and no titles.  I was under the impression that both icecast2 and shoutcast streamed mp3 titles the same way.  I'm beginning to think this is not the case.


That suggests that in_mad probably isn't understanding the header correctly still. If you could use the internet stream save option and store header and metadata information, then post the header information from the beginning of the file that'd be great. I'll also download the icecast source code to try and help clarify things. I've not had chance to fully test the streaming VBR problems yet.

I'm just hunting down an issue with the new buffering 

Cheers for all the help everyone 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-29 14:02:21
I've uploaded an update to the usual place.

One of the minor things I've also fixed is seeking to 0:00 now works. Hoepfully this new buffering shouldn't cause any problems and be more efficient with usage of memory. I haven't noticed any improvement on decoding speeds though. When you press Cancel in the file info box, its cancels all afterwards now. To cancel a single file box, press the close button in the top right of the window.

I'll look into icecast streaming problems and make a few other tweaks.

Please post problems all problems, and I'll look into them, especially with the new buffering.

Thanks 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: k.eight.a on 2006-09-29 14:57:38
When you press Cancel in the file info box, its cancels all afterwards now. To cancel a single file box, press the close button in the top right of the window.
Thanks a lot, I love you!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2006-09-29 15:55:53
Please post problems all problems, and I'll look into them, especially with the new buffering.
Thanks 


I've encountered a weird bug concerning files which contain ReplayGain tags with the plugin's preamp being enabled. Sometimes repeated seeking causes these files to soften, no matter whether the preamp value is positive or negative. Usually I use a preamp of 3.0, the first time I encountered this bug the volume level was lowered a bit, therefore I suspected the new buffering had conflicted with the preamp, disabling it completely. Hence, for testing purposes I increased it to 6.0, but against my expectations the next time this bug occured the volume level wasn't set back to the one I encountered the previous time. It was audibly louder instead, meaning the bug doesn't set back loudness to the non-preamped value, but always more quiet. For verification I set a negative preamp of -6.0, after some excessive seeking (the bug occurs rather rarely) the volume was lowered once more. I'm not completely sure whether it's the preamp causing this issue, but up to this point I wasn't able to reproduce it with the preamp being disabled.

To reproduce the bug by yourself simply keep clicking around in the seeking bar until an audible volume change takes place. Sometimes it already happens just after a few clicks.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: pepoluan on 2006-09-29 16:15:31
With the release of Winamp 5.3 I'm going to look into getting global replaygain settings from Winamp. I could do with some clarification as to how Winamp is applying the replaygain settings though. For the moment, you still need to set them through in_mad configuration as this will be separate to the rest of Winamp.
So, what's you're trying to say is, use ReplayGain inside in_mad instead of Winamp's Preference > Playback?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-29 16:28:31
@pepoluan, yes if you want RG for just your mp3 files.

With the replaygain you need to set it twice, within in_mad for mp3 files, and again in the winamp for the other "Winamp replaygain compatible" plugins. This is because in_mad doesn't take its settings from Winamp 5.3 global settings.

@Junon, I'll look into it

Thanks for all comments, I've noticed a small problem with gapless and EQ now but seems to vary depending on song and output plugin    .
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-29 20:03:36
This gapless EQ problem is very strange.

When disk writing and joining the outputted files together it plays back gaplessly. However using the directsound output plugin gives what sounds to be a break, but the output plug-in status shows no under-runs etc. When EQ is disabled it doesn't show this problem.

Does anyone have any ideas as to what could be causing this?  Has anyone else found or not found this problem?

Thanks for all ideas and help on this
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Teknojnky on 2006-09-29 20:22:46
For the last month or 2 builds, I get memory errors/crashes with using this plugin in Mediamonkey (compatible with WA2 plugins).

Unfortunately it got so bad I had to stop using it, but if I can help narrow down the problem somehow I will.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-09-29 23:47:16
The EQ gapless problem is due to CPU usage (again) causing it to skip on my laptop. I'm going to look into reducing the amount of repetitive things that happen in the decoding loop etc.

@Teknojnky, I've not checked in_mad in Mediamonkey for some time now, I'll reinstall it and look into it.

The main list of bugs now are volume reducing on seeking, MediaMonkey problems, Icecast VBR title problems and more CPU usage/speed problems. I'd also like to get Winamp 5.3 global settings working.

Thanks to all for comments and testing
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-01 20:08:53
I've uploaded an update to the usual place.

I've made some changes to seeking, RG behaviour, and both input and output buffering in an attempt to reduce CPU usage. I've also made changes to the shoutcast header parser hopefully allowing more streams to be played.

@Teknojnky, what other plug-ins are active in MediaMonkey? what tags are on the files your trying to play? I've clean installed it and tried it with various DSPs and options but can't make it crash.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Teknojnky on 2006-10-01 22:42:13
I don't actively use many special plugins, however the main ones are gen_audioscrobbler.dll (new style last.fm plugin), minilyrics (v 2266), and the DS_out.dll from winamp 5.21 (says v 2.42).

When not using the mad plugin, I use either in_mp3 from winamp 5.21, or sometimes the default MM plugin.

As far as tags, MM uses id3 2.3 format. My own rips I use cbr 192, but I have lots of varying types of encodings from whenever and wherever.

I'll load up the lastest mad and see if I can find a file which has problems.

As to why I use 5.21, I beleive it was the last release of winamp which plugins work in MM. Newer releases plugins have changed something so that MM can't use them.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: HeXeR on 2006-10-02 11:48:47
Hi
I have found a small bug in the id3v2-tags. My with Lame tagged files have in Genre a number instead of the actual Genre.  Otherwise it's a great plug-in and i love your work
Btw: The bug with volume reducing in seeking hasn't been solved for me.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-04 22:54:44
I'll have to take a closer look at the volume reducing bug, and I'll fix the genre problem as well. 

@Teknojnky, I'll test MM with the plug-ins you mention and in_mad, hopefully it'll shed some light on your problem.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-10-06 16:05:32
Seeking seems to be doing much better now.  I don't think I'm getting any more audible glitches. (will continue to test though)

edit: Seems to freeze up winamp a lot.  Always at the end (and possibly beginning) of some mp3's (my nice old partially corrupt ones).  Sometimes results in 100% CPU usage, other times I can just hit the stop button and advance to the next track.  I've reverted to the previous version to see if the problems still occur.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: jarretth on 2006-10-08 18:38:27
I have to ask...is this preferred to Otachan's mpg123 for any reason? Is it more accurate or better features? Otachan's is updated once or twice a month and I see no discussion about it in its thread. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2006-10-08 18:53:23
I have to ask...is this preferred to Otachan's mpg123 for any reason? Is it more accurate or better features? Otachan's is updated once or twice a month and I see no discussion about it in its thread. 


I switched from Otachan to MAD mainly because the latter offers full tag editing support for both ID3 and APEv2. The last Otachan version I tested opened the native Windows properties panel when I checked the info of an MP3 file, which was really useless in the case of my APEv2 tagged MP3 collection. It also offers a nice Gap Removal function for non-LAME encoded files and ID3v2 equalizer as well as streaming support. In the case of MAD we also have a very dedicated developer who reads both bug reports and suggestions in this topic. Cheers @ MoSPDude!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: D!m@$ on 2006-10-09 07:17:45
I from Russia. MAD does not support the russian text in tags...
Possible this correct and as?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hat3k on 2006-10-09 08:42:57
I from Russia. MAD does not support the russian text in tags...
Possible this correct and as?


ENG: Author knows it and works on it

RUS: ????? ? ????? ? ???????? ??? ????
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: nogus on 2006-10-09 14:28:40
Hello MoSPDude

Is there any fixes to original in_mad 1.14.2-beta code in your modification?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-09 20:17:06
@nogus, this plug-in started out as an upgrade of the code to the 0.14.2b plug-in with basic ID3v2 support using libmad 0.15.1b and libid3tag 0.15.1b. From there I've added large parts to it such as the enhanced ID3v2 support, APE tag support and shoutcast support, and re-written a few old troublesome sections such as the decoding loop. The most heavily changed library in this plug-in is libid3tag as I've fixed it so it writes correct ID3v2.3 and v2.4 tags.

@gameplaya15143, I'm holding off on an update while I solve the end of track problem. It occurs very rarely (like that volume bug!), but I've had it happen now twice.

I've also managed to fix the volume bug ready for the next release, hopefully for good! 

Thanks to everyone for all support, testing and comments 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: nogus on 2006-10-10 15:03:30
my in_mad mod

I just found MoSPDude's modification. I thought there is no modifications. So i compiled in_mad 0.14.2.beta with msvc60 against 0.15.1 mad libraries and just used ID3V2 tag editor from in_mp3.dll (there is call to in_mp3 InfoBox function).
Changes to in_mad 1.14.2 code is minor, just one minor fix, so therefore i asked about known bugs in 0.14.2.
It supports cyrillics in tag values.
The untested issue is how id3v2 creation wil interfer with same file playback.
If somebody interested:
http://rapidshare.de/files/36213437/mad-0.14.2b.p1.rar.html (http://rapidshare.de/files/36213437/mad-0.14.2b.p1.rar.html)

About SSRC

I have found out_wave_ssrc 2.0.2a source code by Peter Pawlowsky. He used old version of ssrc resampler by Naoki Shibata. I wanted to compile out_wave_ssrc against new SSRC 1.30 but unfortunately resampler is not convenient for external usage so people just cut-n-paste some code from it. Peter made nice OO refactoring of SSRC library. But it is OLD SSRC code and no easy way to update it

There is allso Besweet DLL based on version 1.28 of Naoki SSRC code. People expecting 1.30 dll from BeSweet. Sounds good but: BeSweet can't redistribute SSRC code due to LGPL license...

Conclusions:

1. Naoki resampler needs library interface! There is some reasons to use Besweet SSRC DLL. Or find some automated way to make library from Naoki SSRC resampler. Certainly best way is to ask Naoki to part his code into normal lib and frontend.
2. Resampling, dithering and shaping is output module business. Best solution is SSRC output module that chains to any Nullsoft output module.

Cheers,
Oleg
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-10 17:55:56
Dithering and shaping are not necessarily just for the output module, it should be used whenever there is a bit-depth conversion. libmad uses a 28-bit fixed internal representation. The dither and noise-shaping are applied when the 28-bit output is reduced to 8, 16 or 24 bits (the 32 bit output is simply 24 bits padded).

The old 0.14.2b plug-in applied simple triangular dither and a basic 2nd order noise shaper. In my updated in_mad the only parts used from SSRC 1.30 are the co-efficients for the noise shaper at different sampling rates, and the methods for generating and applying the dither.

In terms of bugs in the 0.14.2b code, one I remember is in the Xing tag reader - I merged the Xing/LAME tag reader from the latest madplay as that was more updated and fixed that. Another is the internet stream hijacking problem due to "is_ourfile" behaviour. Feel free to look at my updated source code and apply fixes, although if you are going to apply huge sections of code such as decoding loop, please would you add some recognition to the About box. Thanks
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-12 14:38:38
I've uploaded an update to the usual place.

This hopefully will have solved both the volume reducing on seek and sync error, and the end of track problem. I've also fixed the genre problem, converting genre names back to numbers (and back again) as in the specification. Improvements have also been made to the gap removal feature on tracks without gapless information - the threshold for silence can also be set.

I've been trying to access WA5.3 global settings, but my C to C++ wrapper crashes.  Does anyone know of a way to access them without going through class pointers?

@Teknojnky, I still can't make MediaMonkey crash. The only plug-in you mention that I haven't been able to test is the gen_audioscrobbler.dll, if you could check that by disabling it for me. Otherwise I've tested the latest minilyrics and the DS output plug-in you mentioned, with the latest MediaMonkey. What OS are you using? Does in_mad crash winamp on your machine?

Thanks for all help, bug-finding and comments in advance. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-13 23:22:31
I've uploaded another quick update to the usual place.

This now has (hopefully) sample accurate seeking - its disabled by default. I haven't properly tested it so all comments are welcome. 

EDIT: There is a bug in the accurate seeking that puts it way off. I've sorted most of it out but am still out by a few samples. I'll hopefully get it fixed for an update later.

EDIT 2: It turns out that on my test files instructing winamp to seek to 2 minutes actually seeked to 120092 ms, which was the exact output I was getting. I've uploaded this new version, all other files and seeks seem to be working
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-10-19 00:11:22
I'll have to redownload to make sure I have the latest version.

Accurate seeking worked fine for me, no audible glitches, and it has yet to crash.

Excellent work!

edit: There is still a problem that hasn't been resolved.  At the end of some of my lovely slightly corrupt mp3's, in_mad ends up in an infinite loop (CPU 100%).  I can still use 'stop' and 'next' without crashing winamp.  This happens both with and without the gapless option on, the accurate seeking option doesn't effect it either.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-20 14:25:05
@gameplaya15143, can you tell me what it says in the Buffer information tab in the File info window when it enters its infinite loop. (The option to show the buffer information is at the bottom of the Buffer configuration page). I'm mainly interested in the length of the input buffer, and status of end of input and end of decoding flags.

Come to think of it, I might know what is causing the trouble if the file is damaged at the end - I'll have another go at it later today for an update tomorrow.

Thanks 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-10-22 01:37:17
The 'end of input' box gets checked, and the input buffer goes down (as it should).  On the files where it is looping, the 'end of decoding' box does not get checked.  There is still a lot in the decoding buffer when it runs into this problem.

I hope that helps
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: kairo on 2006-10-22 01:51:28
It appears that it's stuck in a while loop at playback.c line 639. Specifically, after call to mad_frame_decode fails, it breaks there:
Code: [Select]
  if (input_buffer_cycle(input_buffer, stream.next_frame, &input_ptr, input_length, input_size) == -1)
                        {
                            //we've EOF and its not because we're at the end of memory
                            err_buflen = 1;
                            break;
                        }

and goes here:
Code: [Select]
  if ((err_buflen == 1) || (eof_decode == 1)) continue;
            if (err > 0) break;

Since err_buflen is set to 1, it continues to the start of the while loop again and again. While loop condition checks if eof_decode==1, so i set it before continue:
Code: [Select]
if ((err_buflen == 1) || (eof_decode == 1))
                {
                eof_decode=1;
                continue;
                }
            if (err > 0) break;

and it seems to work. Well it's not that i understand the whole process, this is only a dirty hack.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-22 15:55:18
Yep, kairo is right. The behaviour when its ran out off data but not at the end of the buffer memory should halt the decoding because there is no more valid data and we're end of file. The err_buflen should have continued to the outside loop (my mistake) so as to fetch more data from an internet stream.

I've uploaded an update to the usual location. Thanks for everyone support and helping me track down these problems.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-10-23 20:37:40
Here (http://www.geocities.com/gameplaya_15143/mad_killer.mp3) is a small present for you MoSPDude, this one crashes in_mad even when it just tried to read the tag. (result of a 'bad cut')  I think this is the only file I have that is still causing problems.

As far as streaming goes.. I tried listening to a shoutcast mp3 stream, in_mad did not pick it up.  It also gave me an error when trying to listen to an icecast mp3 stream (../listen.mp3) saying 'file could not be located on disk' or something.  I tried opening the file info dialog, when I clicked on the 'buffer' tab (which shouldn't have been there since it wasn't playing) in_mad crashed.  I have no problems like these streaming from shoutcast or icecast on my own machine (localhost).  It seems to just not like outside sources.

The first 'problem' may be due to the fact that I am using some random letters for winamp's default type for unknown files (same random letters on the extention list of in_mp3).

As always, thanks for the great plugin!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: kairo on 2006-10-24 02:03:44
Apparently, something is wrong with buffering algorithm in scan_header() (same playback.c), but I can't figure out where exactly. It keeps calling memmove() with source=destination.

As another quick-and-dirty hack, simply enlarging buffer from 1536 to 15360 bytes seem to do the trick. Well, at least this broken track plays now 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-24 19:46:34
I'm playing with a way to fix this, I'm not quite happy with it yet.

I believe its to do with libmad and how it sets stream.this_frame and stream.next_frame when there is an error. I think its supposed to (correctly) set stream.next_frame = stream.this_frame + 1 , so in an error it steps byte by byte to find a correct header. On other occassions though it leaves it stream.next_frame = stream.this_frame (which ends up equal to the start of the buffer) entering the loop problem.

I try to avoid modifying libmad and libid3tag unless I really need to, but I think I'll have to have a proper look into libmad for this one.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: DrSiN on 2006-10-24 21:45:53
very clever my old buddy.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Teknojnky on 2006-10-24 22:11:44
I was wondering if it was possible to start including build/version info in the compiled DLL file so that it's much easier to see which version you have and thus report back any issues which might be version specific.

Normally when this info is included, windows will either show it on the explorer status bar or mouseover, and/or in the file properties, making it very easy to see at a glance.

I've been running the current version as of a couple days ago and have not had any crashes in Mediamonkey, but since I don't know what the current build is I have, it's difficult to relay any information.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-26 21:15:03
I'm preparing an update to be uploaded tomorrow.

Thanks to kairo for looking into the mad_killer problem  I've added a DLL version to help identify different builds at Teknojnky request.

Thanks to all for bug finding and problem reporting 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: kairo on 2006-10-26 22:38:11
Streams without extensions like http://222.122.131.23:22000 (http://222.122.131.23:22000) or http://scfire-nyk0l-1.stream.aol.com:80/stream/1013 (http://scfire-nyk0l-1.stream.aol.com:80/stream/1013) are causing a stack overflow in winamp2 with "detect unknown streams" disabled.

EDIT: Sorry, my conclusions were wrong...
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-10-27 18:12:47
I've uploaded the update. There is a DLL version included, that can be found by looking at the file properties, or from in Winamp in the title of the About plug-in box. Its currently at 0.1.1.26 .

@gameplaya15143, what are the URLs for the streams your testing? in_mad only attempts to connect to those starting http, https or ftp.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Alex. on 2006-11-03 12:21:04
Hi. I downloaded mad cause of old versions doesn't support id3v2 tags.
BUT this version  (0.15.1 beta) DOESN'T SUPPORT cyrillic symbols in 3v2!!
When i trying to save cyrillic to id3v2 after saving it looks like
.....-.....!! But if i save cyrillic to id3v1 mad saves it correctly.
Please fix this bug!! Cause I have great russian collection.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-04 19:17:59
International characters will always be a bit of a problem, what version of Winamp are you using? I'm planning, now Winamp supports Unicode, to redo the get_fileinfo and other DLL interfaces properly - but the plug-in as a whole won't become fully Unicode for a while as its a lot of work.

I'm also thinking about a rewrite from C to C++ code, and then try to access the Winamp global configuration classes again.

Cheers for comments and bug reports 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: fragmer on 2006-11-05 03:05:40
Hello;
I love the new in_mad; I would like to use it more, but unfortunately it is not compatible with the Last.fm (http://www.last.fm/tools/downloads/) (Audioscrobbler) plugin. Actually, sometimes the scrobbling actually does occur, but both song title and artist name are "È9", "È:" or something similar. How hard is it to make in_mad Last.fm compatible?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-05 16:32:43
@fragmer, not too hard  I've uploaded a quick update to fix the last.fm gen/ml_audioscrobbler problem. The problem was down to audioscrobbler looking for "Artist", not "artist" etc. The DLL is now at version 0.1.1.36 .

I'm currently making changes to improve Unicode and international character support.

Cheers for all comments and help
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: jarretth on 2006-11-05 18:33:43
oh my gosh thanks for fixing audioscrobbler I use it too!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-11-10 01:56:22
I'm downloading the newest version now.

Earlier today I was listening to so MP3s off a CDR (data), when the track starts, it plays for a split second, then has to buffer more before it can play properly.  Would that have something to do with the 'faster decoding' thing you added in a long while back?  I tried playing with the buffer size with no success to fix the gap.  I also managed to crach winamp from in_mad (it got reported as being responsible by windows) while seeking in long files on the CD (ie. 60mins 112kbps cbr).

As for the streams that weren't working with in_mad, I just tried some from www.shoutcast.com/waradio

Other than that, it is working perfectly

edit: The new version seems to think that my mp3's are read-only.  The tag fields are 'grayed out' when the file is playing.  If I access the tag editor while the song is not playing, everything is fine.  I'm going back to the last version I had since I haven't had any problems with it.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-12 14:10:04
Whoops  , the read-only problem was due to me playing with the access rights when opening the file for playback. I've uploaded the fixed version just now, its DLL version is 0.1.1.37. 

@gameplaya15143, what kind of internet connection do you have? The plug-in only uses windows InternetOpenUrl to create the connection. Also, what options are enabled in the General tab of the configuration page.
As for the CD reading problem, on playing back tracks does your CD drive spin down after an initial burst read? I've had a lot of trouble with this - my solution was to extend the Output plug-in buffer to give enough time for the CD drive to spin up again and fetch the data ready for the plug-in to decode more. I also tried a utility to extend the spin down time of the drive at the cost of more whirring noise. The hanging when seeking on CD will likely be caused by Accurate seeking - again does your CD drive appear to be heavy seeking when you tell Winamp to seek? Accurate seeking works by 'header skipping' its way from the start of the file to the desired output position - which on long/large files on CD could be a problem.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-11-13 03:36:33
I have everything enabled in the 'general' tab.  I generally use only 300ms for my output buffer.  I did compare how in_mad and in_mpg123 and in_mp3 handled input from my data CD.  I'll have to try seeking without accurate seeing enabled.  I rarely ever listen to mp3s directly off a CD, so increasing my output plugin buffer for those few times certainly isn't out of the question.  I wouldn't worry about it too much unless you have some idea of how to compensate for super-slow access speeds.  And yes my CDrom drive is working properly by not spinning at full speed the entire time  The 'skips' generally occur when reading the tags on other files when the winamp window scrolls.

As far as internet connection goes, I have tried it on both dialup and direct connection.  Both with the same result.  It would only decode the stream when I was running my own server on localhost.  I haven't done any stream tests with the latest version yet.. so, I don't know, maybe it's already working better.  I'll be sure to let you know how it goes.

Keep up the wonder work.. I already can't stand to go back to any other mp3 plugin (I did that a while back, and I ended up like this ->  )
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-15 13:51:32
With the playback from CD, it might help if I was to make it so it didn't require to read from the CD all the time, as reading into the buffer occurs synchronously so the plug-in stops sending data to the output plug-in. Maybe an option to set the percentage of buffer thats empty before it reads again, in the earlier versions it only used to read when the buffer had emptied completely, now it reads all the time - but a compromise say 75% buffer would make it read bigger chunks less of the time. Then again, if windows caches the whole file from the CD, the CD would still spin down as its not physically reading it all the time.

I'll make some tweaks to the internet open routines etc. and see if that helps the streaming issue.

The Unicode interfaces are coming along slowly. It detects what the winamp version is, and if 5.3 or over enables the Unicode interfaces. The Unicode interaction is only with Winamp, the plug-in is still ANSI - although rewriting all the tag routines as such will make it easier to move over to a Unicode plug-in.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Cybermutant on 2006-11-23 00:43:09
The CUE Player plugin (latest version here (http://etono.cplusplus.se/cueplay/downloads.xml)) doesn't work properly when MAD is the default MP3 decoder. I'm using Winamp 5.32, and its standard MP3 decoder has no problems with CUE Player. However, when I switch to MAD, I see two different behaviors:

- If "Enable accurate seeking" is off, Winamp cannot accurately seek to the beginning of the tracks in the CUE file. It is always off target by a few seconds, but the seek points are the same between consecutive plays; if one track starts playing from +2.5 secs, it does so everytime, while another track always starts at -1.3 secs, etc... I guess this is expected, since accurate seeking is disabled.

- If I turn on "Enable accurate seeking", playback is totally broken. All tracks start to play from the very beginning of the file, the handle of the Winamp time slider disappears, and the time display freezes at 00:00. Sometimes a track will start properly, but this happens once in maybe 30 tries.

Can you please look into this? If it turns out to be CUE Player's fault, I'll contact its author for a fix.

Thank you for all the work you put into this plugin. The APE tag support alone is enough reason for me to use MAD. Best regards...
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-23 20:28:41
I've uploaded a new DLL version just to fix CUE player, DLL version 0.1.1.39. This still has NO WA5.3 Unicode support.

It was a welcome change to writing in Unicode stuff!!    Its coming along slowly, just over half done and working, I don't want to put it up until its functional. I've also prepared some changes to make the buffer filling level changable, and changes to paramters for internet routines but these will have to wait until Unicode stuff is ready.

Thanks, and please feel free to post questions, bugs and suggestions!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: fragmer on 2006-11-25 07:39:47
Thanks for fixing the plugin with Last.fm a while back . You should seriously consider adding a paypal/donation link here; you're putting so much work into in_mad!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Cybermutant on 2006-11-25 16:04:23
CUE Player problem fixed in 20 hours, you are fast  Thanks a lot.

By the way, if accurate seeking is enabled, does MAD scan the whole file from the beginning whenever it performs a seek operation? Jumping back and forth seems to take longer with accurate seeking, especially towards the end of large MP3 files.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-25 19:58:23
@Cybermutant, essentially yes, it header skips its way from the start of the file, counting samples, to 2 frames before the desired point, decodes 2 frames properly and then sample skips to the exact sample location. I've thought about adding a kind of seek table look up to the accurate seek so while playing if it knows that at a fixed location its at such a sample number it wouldn't have to seek from the beginning.

@fragmer, I just wanted an in_mad plug-in that supported ID3v2 tags and worked! 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-11-27 03:04:18
Maybe an option to set the percentage of buffer thats empty before it reads again
Sounds like a good idea to me.

Quote
I'll make some tweaks to the internet open routines etc. and see if that helps the streaming issue.
It didn't like that I had IE set to 'work offline'.  Streaming works fine now ...once I figured that out.  I can't say I like the idea of going through IE though
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-27 10:12:53
I think its a case of we say Internet Explorer, MS say integral part of the operating system and API. I've just done a google search on it, and found documents relating the WinInet API to a global offline mode, that I didn't realise. I'll have a rethink about the connection API, or perhaps for now make it change the global offline state, which will have an effect on IE though  .

Thanks for all bug reports, comments and suggestions 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Cybermutant on 2006-11-27 22:52:34
I've thought about adding a kind of seek table look up to the accurate seek so while playing if it knows that at a fixed location its at such a sample number it wouldn't have to seek from the beginning.
A lookup table would be very nice. It can wait though, I know that your current priority is Unicode support
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Cybermutant on 2006-11-29 20:36:21
Using Winamp 5.32 with MAD DLL v0.1.1.39, when I open an m3u playlist which contains some files that are missing (in my case, they are in queue to be downloaded but their download haven't started yet), Winamp crashes when it reaches the first missing file while trying to read file tags for displaying them in the playlist. The crash details given by Windows are:

AppName: winamp.exe    AppVer: 5.3.2.1003    ModName: in_mad.dll
ModVer: 0.1.1.39    Offset: 00040479

The offset is always 00040479. The same m3u file is loaded without problem after all files in it have been downloaded (actually, after all files have been created on disk, even if they have a size of zero).
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-29 21:54:14
I've uploaded a fix for the problem of trying to read tags from a file thats not there! Whoops! The DLL version is now 0.1.1.42. I'm close to releasing the Unicode version now.

Thanks to everyone for the help! 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Cybermutant on 2006-11-29 23:29:12
Did a quick check and, yep, problem fixed. Thanks for the lightning fast update 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: HandleX on 2006-11-30 06:51:51
Hi, your mp3 decoder just enchant me. It's great!

But there is a question: in source code  (playback.c) a call to CreateFile has in dwFlagsAndAttributes FILE_FLAG_SEQUENTIAL_SCAN optimisation, it's good. Why this flag has not FILE_FLAG_NO_BUFFERING optimisation? I'm using winamp in very hard system performance environment such playing music with winamp and gaming CS at only 256 RAM -)) Call to ReadFile will read data in your codec buffer and will be cached by kernel 4096 bytes (page size) replacing gaming file cache... This is not good, IMHO, cached by kernel data from mp3 file will never been reused.

Can you correct this program behavior? I've dont have C compiler, rather I've done it by my own.
Sorry for my English, I'm Russian.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-11-30 15:38:32
I did have a look at the flags for CreateFile a bit ago. The problem with CreateFile using FILE_FLAG_NO_BUFFERING is that the application needs to meet certain requirements with regards to file access, which would mean making some changes to the way the file is read. The criteria are specified on the MSDN site. It might be possible by fixing the size of data read, and making it only read once a sector worth of data has been processed - I'll have a look into it, it might help with the CD reading problem because then windows definitely won't cache the data.

If you download and install Dev-C++ 5 Beta 9.2 with the MinGW package from the Bloodshed Software website, the plug-in should compile without problems using the Dev-C++ workspace .dev file.

Cheers,
Craig 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2006-11-30 21:11:25
If you download and install Dev-C++ 5 Beta 9.2 with the MinGW package from the Bloodshed Software website, the plug-in should compile without problems using the Dev-C++ workspace .dev file.

Cheers,
Craig 


I didn't try the current Dev-C++ versions yet, because I switched to Code::Blocks a while ago. Don't know if you ever heard about it, but I think it's great so I recommend you try it out when you have a bit of time. Dev-C++ was quite unstable when I switched, so I'm probably biased by those old builds...

Use a nightly build when you try it, though. The stable release is very outdated.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-12-07 22:08:03
Well its here, DLL version 0.1.2.0 with a working Unicode implementation. 

The Unicode will only work with Winamp 5.3 or greater, and if it causes problems I've included an option to turn it off. This build also includes a buffer fill level option, and a few other minor changes. I've also moved over to Code::Blocks as a development IDE as it appears much more stable, thanks MedO!

The plug-in is still ANSI based so the tag editor still won't show all characters correctly, and at the moment the Media Library doesn't seem to set tags via the Unicode API either so there is no way to set Unicode tags directly yet.

I look forward to the bug reports and comments. Thanks to everyone in advance 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2006-12-11 03:16:58
The new one doesn't work with winamp2.  It doesn't even show up in the input plugins list.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Mangix on 2006-12-11 03:51:53
The new one doesn't work with winamp2.  It doesn't even show up in the input plugins list.

he stated that it only works with Winamp 5.3
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-12-11 09:28:02
I've just uploaded DLL version 0.1.2.1, with some changes to how Winamp is told what version the plug-in is. Hopefully, this will fix the compatibility with Winamp 2.

@gameplaya15143, What version of Winamp 2 are you using?

EDIT: There appears to be a slight problem with the above version, the plug-in doesn't appear to detect new winamp versions, and always disables Unicode on startup.

EDIT 2: I've uploaded DLL version 0.1.2.2, hopefully fixing the above.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Teknojnky on 2006-12-11 19:08:38
I had to uncheck "enable unicode support" and restart to get it to start working again in mediamonkey (2.5.5.985 rc-3 (http://www.mediamonkey.com/beta/MediaMonkey_2.5.5.985.exe)).

in_mad.dll 0.1.2.2
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-12-11 20:27:09
I had to uncheck "enable unicode support" and restart to get it to start working again in mediamonkey (2.5.5.985 rc-3 (http://www.mediamonkey.com/beta/MediaMonkey_2.5.5.985.exe)).

in_mad.dll 0.1.2.2


I wonder what version of "Winamp" MediaMonkey is reporting to the plug-in. The plug-in just simply checks if the quoted version reported by IPC_GETVERSION is less than 0x5030 and decides to automatically enable Unicode or not. I'll have a look into it 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: JWolf on 2006-12-12 14:11:18
Is this a bug in MAD or is this a bug in Shoutcast?

Sometimes I listen to internet radio that uses Shoutcast. http://NovaStreamRadio.Org/pls/listen.m3u (http://NovaStreamRadio.Org/pls/listen.m3u)

The tags work fine after the track I tune into is finished playing. The track I tune into has a truncated tag being displayed in the playlist editor. The track being played is "Randy Travis - I'm Gonna Love You Forever" and all I see is "Randy Travis - I"

if the bug is with Shoutcast then feel free to ignore this message.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2006-12-12 16:32:54
It is a bug, I'll get it fixed in the next release. Its because the name has an apostrophe which is also the terminating character for the end of the title.

Cheers and thanks for telling me
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-01-02 12:11:50
I've uploaded a minor update. The DLL version is now 0.1.2.7 . This fixes the streaming name problem and a Unicode setting problem. Hopefully, I'll have improved seeking ready for the next update, and perhaps the WA5.3 global settings working too.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MedO on 2007-01-02 12:23:51
I've uploaded a minor update. The DLL version is now 0.1.2.7 . This fixes the streaming name problem and a Unicode setting problem. Hopefully, I'll have improved seeking ready for the next update, and perhaps the WA5.3 global settings working too.


Thanks Dude!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: AspiringSquire on 2007-01-12 08:56:53
Very nice work updating and enhancing in_mad for Winamp. MAD has been the only mp3 plugin that I have used since I discovered it on its seemingly abandoned homepage, and now I can continue to enjoy it with the added comforts that you have provided through your efforts. Thank you!

I was fortunate enough to find your version of MAD, and I want to give at least a little bit back. Unfortunately, this comes in the form of a bug report. It's nothing big, but when "Prevent ID3v2.3 to v2.4 conversion" is checked, some songs won't have their ID3v2 tag information displayed, neither in the playlist nor the Properties window. With the option unchecked, the info is displayed. I don't know if it applies specifically to files using the ID3v2.3 tag or not, since I don't know how to check the tag version.

There seems to be a problem with the Title Format naming scheme, too; I can't get it to change the appearance of songs in the playlist at all, whatever I try.

I also have a request, which I suppose may actually be another bug report. Whenever an mp3's Properties window is open, I can't scroll the playlist or select any of the displayed files (I use the Classic mode of Winamp). I use plugins (for other types of files) that don't have this limitation, and I'm hoping that you could make this small improvement--to allow manipulation of the playlist while the Properties are open.

Thanks again. :)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-01-12 11:00:05
Hey, thanks for posting your findings. 

The ID3v2.3 support is a bit experimental, and I only roughly tested it, so I'll have a proper look into it.

With the Title Formatting, Winamp uses Advanced or Basic TF. If your changing it within the plug-in and nothing is happening, chances are Winamp is using its Advanced TF - to change these settings you need to goto the Winamp preferences -> General preferences -> Titles and you'll find Advanced Title Formatting at the bottom.

The property window takes control as a pop-up dialog box, I'll have a look into making it not block the Playlist editor window.

Thanks again for posting your findings. My workload has increased for the next 3 weeks, but I'm doing bits of the plug-in as a hobby break.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: AspiringSquire on 2007-01-12 21:12:46
With the Title Formatting, Winamp uses Advanced or Basic TF. If your changing it within the plug-in and nothing is happening, chances are Winamp is using its Advanced TF - to change these settings you need to goto the Winamp preferences -> General preferences -> Titles and you'll find Advanced Title Formatting at the bottom.

Disabling Winamp's Advanced Title Formatting fixed it; thanks.

Do you think you might expand the available parameters to encompass more of the options that are in Winamp's Advanced TF (though I don't think I would actually use all of them)? Right now, the main advantage of using MAD's formatting is the ability to include an ELSE with the IF. ...Well, no, I just saw the equivalent in Advanced TF.

Is there a specific advantage to using the MAD formatting editor? Does Winamp (for its TF) check the tags via MAD (and therefore use the tag priority order in MAD), or does it have an independent check? After witnessing the non-display of some info with the ID3v2.3 option (while still using Advanced TF), I believe the former to be the case.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-01-12 22:40:53
Winamp does use the in_mad plug-in to read the tags for its advanced Title Formatting and it uses the tag preference in the plug-in configuration for reading titles. The basic Title Formatting is there for compatiblity with older versions of Winamp 2.x. If your using a newer version of Winamp, its best to use the advanced formatting as it will make the titles match what other advanced TF compatible plug-ins show. Updating the basic TF to be a bit more advanced is on the to-do list.

Cheers and thanks for testing the plug-in 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: AspiringSquire on 2007-01-14 05:58:55
I have discovered another small bug. An mp3 with an ID3v1 tag that has no track number will incorrectly display a 0 in the playlist (if track numbers are allocated in title formatting) if the comment has exactly 29 characters in it. I just recently read the specification for ID3v1.1 (and v1.0) tags on ID3.org, and it says that the byte preceding the track number should always be binary 0 (and thus comments are restricted to 28 characters). This means that if a comment contains 29 characters, there can't be a track number supported by the tag because it would then be using the ID3v1.0 standard, which allows comments up to 30 characters long.

I also have a few requests. Could you include an option (or make it standard) to update a file's appearance in the playlist when opening its properties window, so the file won't have to be modified or played in order to refresh it?

If something is typed or changed in the ID3v2 Basic mode, it is lost when switching to Advanced mode. This isn't the case if something is updated in Advanced mode then switching to Basic. Could you please have it keep track of the changed Basic data in Advanced mode?

And could you also cause the Advanced mode for ID3v2 tags to update the input box, etc. by using the arrow keys in the list of existing tags, rather than just when clicking on them with the mouse?

I assume that some (or all) of the things related to Advanced mode that I mentioned would apply to both ID3v2 and APE tags.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Domin on 2007-01-28 08:41:22
Is there any way to make the in_mad plugin able to play this stream:

http://serv1.mmradio.se:8000 (http://serv1.mmradio.se:8000) <-- its an AAC+V2 encoded stream.

If it cant play it is there a way to make it default to the normal winamp playback, so i can still use aac streams without having to rename the 2 .dll files every time i have to use a specific one of them?

Hope this is possible and thanks for all your greate work on this plugin 

Regards Domin
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-01-28 12:15:44
If it cant play it is there a way to make it default to the normal winamp playback, so i can still use aac streams without having to rename the 2 .dll files every time i have to use a specific one of them?


There never was any need to rename anything. You simply have to remove "MP3" from the file associations found in the "Nullsoft MPEG Audio Decoder's" configuration and enable the MAD plug-in. Both inputs are set to do their work this way, with MP3 audio being played back by MAD, while any extensions left in the Nullsoft decoder, including raw AAC, keep being its job to process.

To check whether everything worked out as intended, restart Winamp after changing the input settings as described above, then view the file info of an MP3 thingamabob. If the MAD properties window pops up, everything's fine.

Have a look at this screenie if anything shouldn't work out properly yet. One picture sometimes says more than a hundred words:

(http://s6.bilder-hosting.de/tbnl/ZL8FU.png) (http://www.bilder-hosting.de/show/ZL8FU.html)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Domin on 2007-01-28 12:31:35
Hmm, i did not know that but even after i tryed the above setting it still wont play it, seems like the in_mad dont turn over the handeling to the in_mp3 plugin.

Thanks for the help, now i can at least have both dll running ;-)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-01-28 17:22:26
Hi Domin, can you try this for me,

In Winamp Preferences under General Preferences -> Playlist, under the Advanced Playback Setting where it states "Assume file extension of unknown files is to be" change this from "mp3" to "dummy", and then in Winamp in_mp3 Input Preferences, add "dummy" as a file association extension.

If this works, it is likely to be because the stream doesn't identify what type it is so no plug-in is claiming it for itself and trying to play it back.

Because of the length of time its taking for me to rebuild the plug-in, I'll release bug fixed version of the old code within the next week hopefully for everyone. Thanks for your bug reports 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Domin on 2007-01-29 20:19:50
Greate, this works 

Thanks for greate and lightning fast support ;-)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2007-01-30 23:55:34
APEv2 tag basic editor: I think the date and track number fields are wrong.  If I put in a date in the basic editor, it saves it under the 'date' tag instead of 'year' as it should be.  Similar issue with the track number.
(at least I think thats how it was, I just know 2 of the ape tag fields in the basic editor were incorrect)

Still no icecast2 title support?

I'm glad to see you are still making improvements MoSPDude
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: kyousuke on 2007-02-14 14:20:49
Can anyone tell me which or where is the link for the best and latest MAD MP3 winamp plugin?  I find there is a lot of fix in the post, but I never know which 1 should I use. Thank you.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-02-14 14:28:00
Can anyone tell me which or where is the link for the best and latest MAD MP3 winamp plugin?  I find there is a lot of fix in the post, but I never know which 1 should I use. Thank you.


Click the link in this topic's first post.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: kyousuke on 2007-02-28 13:00:32
Can anyone tell me which or where is the link for the best and latest MAD MP3 winamp plugin?  I find there is a lot of fix in the post, but I never know which 1 should I use. Thank you.


Click the link in this topic's first post.


Yes, I did it.. but my current version is 0.15.1(beta) which is a lot newer than the version 0.14.1b from the 1st post. There is so many updated version inside this forum.. I really confuse about which one is the best and updated.. Alt. I love MAD, but anyone tell me which one is the best MP3 decoder for winamp? I'm still confuse about it too...

MAD decode in 24-bit wavefrom
mpg123 decode in 16bit wavefrom with 24-bit output..
there is few of them too.. but I really dunno which I should use.

correct me if any of my information r wrong m I hope if there is anyone can really answer my question.. thank you!!!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-02-28 14:36:07
correct me if any of my information r wrong m I hope if there is anyone can really answer my question.. thank you!!!


I did really answer your question. The file linked to in the first post is always replaced by the most current version, which is dated 2007-01-02 12:04 at the moment.

About the MAD or mpg123 question: I wasn't ever able to hear any differences between their decoding capabilities, and neither of them caused noticeable issues concerning CPU usage, hence it's a matter of personal preference which one to use. MP3 decoders are long-lived ones these days, with a lot of optimizations having been done in the past. Additional plug-in features, like good tagging capabilities, streaming and Unicode support might be more crucial for most users to come to a decision.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: cemoy on 2007-02-28 18:50:31
Which is the latest mad plug-in ? Where can I download ?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-02-28 19:13:58
As Junon said, the link on the first post will always be the latest version.

Here is the link again,

http://www.zen23652.zen.co.uk/in_mad.zip (http://www.zen23652.zen.co.uk/in_mad.zip)

I'm sorry for not having time to do many things with the plug-in now. I don't want to release my remade (very buggy) code yet, and I've not had time to back port some of the other changes. Please keep testing and posting your problems. Trust me, I'm not fully happy with the plug-in yet so its far from being dropped!

Thanks to all 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: vasser on 2007-04-06 13:37:24
I'm sorry for not having time to do many things with the plug-in now. I don't want to release my remade (very buggy) code yet, and I've not had time to back port some of the other changes. Please keep testing and posting your problems. Trust me, I'm not fully happy with the plug-in yet so its far from being dropped!

Thanks to all 

How is it going with the final?

We haven't heard from you for months, have you forgotten about it or that 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-04-07 17:13:23
Hi,

Its coming along slowly, I've rewritten most of it from scratch into C++ integrating Unicode support from the start. Hopefully this won't impact older Winamp version support, but will certainly benefit the newer Winamp versions now the move to Unicode is completed. I'm also aiming to have the plug-in use the global Winamp 5 preferences. In terms of features, I'm not planning for anything new yet until I've got this new code working properly.

Cheers for still being interested

As a side point, do you think I should provide options to enable/disable ID3v1 UTF-8 read/write support, or just have it fixed enabled?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: eevan on 2007-04-09 17:12:26
As a side point, do you think I should provide options to enable/disable ID3v1 UTF-8 read/write support, or just have it fixed enabled?

Hi,

I think that you should make these options configurable, mainly for compatibility with hardware and/or older software players.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Nick63 on 2007-04-18 02:30:20
When I unzip the mad file I get the in_mad.dll and a folder called in_mad with subfolders and loose files. I put the in_mad.dll file in winamp plugins folder and it works fine. I have been using it for a long time. My question is, what what do I do with the in_mad folder? Am I missing some functionality by not putting that folder somewhere? Could someone enlighten me?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: QHOBBES 2.0 on 2007-04-18 03:12:02
Quote
I've included source code


in_mad folder is source code
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Nick63 on 2007-04-18 03:39:47
It is nice to get such a quick reply, thanks. So, I will only have use for the source code if I want to tinker with how the in_mad.dll functions or works with various programs? That is not something I can do yet, but I am very pleased withe the dll as it is and will let the experts make it better if that's possible.


Quote

I've included source code


in_mad folder is source code
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: fragmer on 2007-05-11 05:14:00
It's been more then a month since we've last heard from you, MoSPDude. How is the development going?
Quote
As a side point, do you think I should provide options to enable/disable ID3v1 UTF-8 read/write support, or just have it fixed enabled?

I think it would be good to provide an option, if it's not too much work.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-05-12 10:36:44
Slowly....

Once I've got this work project finished (hopefully mid-June) and recovered properly from computer failure, I'll have a lot more time to work on the plug-in. I currently end up doing odd bits every week but not much unfortunately. I've got so much unfinished code in, that the last build I disabled the GUI just to ensure the thing did still play files back! I just hope this new structure is worth it and that the Unicode stuff does work properly out of the box.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gocsa on 2007-05-16 17:27:35
Do I need to uninstall the Nullsoft MPEG Audio Decoder or any other default plug-ins from Winamp to use the MAD plug-in? I'm using Winamp 5.33.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-05-16 17:43:25
Do I need to uninstall the Nullsoft MPEG Audio Decoder or any other default plug-ins from Winamp to use the MAD plug-in? I'm using Winamp 5.33.

Nope. In the Nullsoft decoder's configuration there's a line displaying all file extensions which should be handled by the plug-in. Simply remove MP3 from this line, enable MAD and restart Winamp. Having done so, Winamp should play MP3 through MAD, checking an MP3's properties will make sure it actually does. The new plug-in uses an own GUI for metadata editing.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: dave2002 on 2007-05-17 19:23:45
Do I need to uninstall the Nullsoft MPEG Audio Decoder or any other default plug-ins from Winamp to use the MAD plug-in? I'm using Winamp 5.33.

Nope. In the Nullsoft decoder's configuration there's a line displaying all file extensions which should be handled by the plug-in. Simply remove MP3 from this line, enable MAD and restart Winamp. Having done so, Winamp should play MP3 through MAD, checking an MP3's properties will make sure it actually does. The new plug-in uses an own GUI for metadata editing.

I'm now using two versions of Winamp - Version 2.95 with MAD and a newer 5.x version with the standard plugins. From reading this thread it looks as though I could now update to use the latest 5.x version with the latest MAD plugin. I have actually been fairly sure that the 2.95+MAD combination provides better sound  - and I'm using a 16 bit sound card (Creative MP3+) and I often use Winamp also to play MP2 files encoded from broadcasts. Whether my perception of better sound is real, or really due to improved MP3 (MP2) decoding, or possibly due to other subtle factors, such as a slightly different frequency response curve, I can't really say - though I do think it is substantially better and makes some output from DAB radios bearable.

One other interest is using Winamp with aac+ plugins, so that I can listen to stations from sites such as http://www.tuner2.com (http://www.tuner2.com)

I'm looking for any advice about the compatibility of the various plug-ins. Can I have a configuration of Winamp (the latest perhaps?) which will (a) use the MAD decoder for preference, and (b) switch to aac+ automatically where needed, or does this all have to be done manually?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-05-18 01:35:35
One other interest is using Winamp with aac+ plugins, so that I can listen to stations from sites such as http://www.tuner2.com (http://www.tuner2.com)

I'm looking for any advice about the compatibility of the various plug-ins. Can I have a configuration of Winamp (the latest perhaps?) which will (a) use the MAD decoder for preference, and (b) switch to aac+ automatically where needed, or does this all have to be done manually?

There's no need for switching between anything, because the decoders don't interfere with each other in any way. MAD handles MP3, AAC in its common MP4 container is decoded by in_mp4, raw .aac (which is extremely rare) is a case for Nullsoft's MPEG audio decoder. Removing the .mp3 extension doesn't completely disable the latter, it still works for any other format found in its configuration, including AAC.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: [JAZ] on 2007-05-18 17:57:52
[...] AAC in its common MP4 container is decoded by in_mp4, raw .aac (which is extremely rare) is a case for Nullsoft's MPEG audio decoder. [...]



Afaik, the in_mp4 of nullsoft is just a MPEG-4 container parser, which outputs the raw aac to the in_mp3 codec.
There existed one in_mp4 from audiocoding which decoded the audio itself, but that's not the case now.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gocsa on 2007-05-18 23:23:39
Another question. I tried the 32 < 24 decoder setting because i couldn't find anywhere if my soundcard is 16 or 24 or what bit (even in the control őanel->sound thing), and it worked, i mean it doesn't crashed, or there was no error, it plays the music. This means that my soundcard is 24 or 32 bit or what? If it was a 16 bit card than it wouldn't play the music, right? In the directsound status menu it says '32 bits per sample, 2 channels'.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gocsa on 2007-05-19 23:04:23
Also, what is the difference between 24 bit padded to 32 and 24 bit? Is the padded one better or no difference?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: [JAZ] on 2007-05-19 23:32:00
24bit padded is a 32bit signal, where only 24 of them carry information. the other 8 are just zeroed in order to maintain bit aligment.
So there is no difference in quality. The hardware might require one format or the other, and if storage matters, the 24bits is smaller than the 24bit padded one.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gocsa on 2007-05-23 20:06:31
So, I have a 16 bit soundcard, is it better or the best quality if I set Noise Shaping and Rectangular dither?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: eevan on 2007-05-23 22:57:26
So, I have a 16 bit soundcard, is it better or the best quality if I set Noise Shaping and Rectangular dither?

If you don't use any additional (usually non dithered) attenuation, or EQ than it's ok. That's why it's best to use the MAD plugin with kernel streaming output and without any processing in winamp. Otherwise, they're going to truncate the samples, so there's no point in dithering the output of the decoder.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Ivan B. on 2007-05-25 18:08:47
i have MAD 0.15.1 beta, is that the latest? the given links doesnt say much about that.

and another question, im using MAD with XM Play, is that plugin fully functional with it as with winamp?
tnx.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-05-27 12:13:39
Hi Ivan,

The MAD decoding library (libmad) 0.15.1b is the latest version, the library itself hasn't been updated since early 2004 (I think!). The ID3 tag library (libid3tag) is also at version 0.15.1b, however I had to patch and fix parts which can be found in the source with the plugin.

As far as I know, XM Play should if it takes Winamp input plugins work ok with this, but I've not tested it - so if you could try it and report if it works or not, that'll be great. I had been testing it with MediaMonkey and looking at problems with compatibility.

Cheers
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Ivan B. on 2007-05-28 19:34:47
Hi Ivan,

The MAD decoding library (libmad) 0.15.1b is the latest version, the library itself hasn't been updated since early 2004 (I think!). The ID3 tag library (libid3tag) is also at version 0.15.1b, however I had to patch and fix parts which can be found in the source with the plugin.

As far as I know, XM Play should if it takes Winamp input plugins work ok with this, but I've not tested it - so if you could try it and report if it works or not, that'll be great. I had been testing it with MediaMonkey and looking at problems with compatibility.

Cheers



im using MAD with XM Play for quite a long time.
I cant tell much because I didnt make any compares with Winamp.
Plugin can be configured like it should be with winamp.
When a song is played I can see ID3, APE tags and LAME tag (if the audio file is encoded with lame) through the plugin (view plugin file info), so it's obviously doing something. 
But what interests me is behavior of some applied options.
Im not sure that they are really functional.
For example, in "output" tab (in plugins config) option "Enable internal EQ".
Or "Link to Winamp EQ", I suppose that nothing will happen on XM Play because plugin cant detect XMs EQ.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: gameplaya15143 on 2007-05-29 22:36:59
One other interest is using Winamp with aac+ plugins, so that I can listen to stations from sites such as http://www.tuner2.com (http://www.tuner2.com)

Winamp handles shoutcast streams horribly.

In Winamp's options, there is a place to set the 'default extension for unknown file types', the default for this is 'MP3'.  If you set this to 'OGG', when you try to play a typical shoutcast stream (http;//host:8000), in_vorbis will try to decode it, and fail.  Because shoutcasters don't set the stream extension, winamp has no idea what format the stream is in.  The workaround for this problem if you remove 'mp3' from in_mp3's extension list is to create a new fake default extension in its place for unknown/shoutcast streams.  I used "strm" for the defaut extension and added "strm" to in_mp3's extension list.  Then in_mp3 will decode all shoutcast streams.  If the stream has a mountpoint (http;//host:8000/stream.mp3) then the proper mp3 decoder (MAD in this case) will be used instead of in_mp3.  The problem here is that in_mad has problems with icecast2's metadata 

It's a mess
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: nemoW on 2007-06-20 20:14:14
Could you please add option "Ignore ReplayGain info in LAME tag"?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Kjn_Wds on 2007-06-21 18:01:45
MoSPDude, you're a damn genius, I love your work.
It is indeed the best decoder of all (until now I used the old one though O.O)!!
You changed the way I listen to music, so thanks, really!

Waiting for new updates \ news.

Cheers ^^
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-06-22 23:01:34
I can't take all credit, I only decided something had to be done with it being heavily out of date, and combined a lot of best bits from other sources with fixes. The main credit goes with the author of libmad and libid3tag. As for a "Ignore ReplayGain info in LAME tag" option, it'll be in the new plugin.

I'm currently working on the GUI section of the new plug-in, and in the interest of internationalisation I'm thinking of making the plugin read strings in UTF-8 format for the GUI from a "in_mad.lng" or "in_mad.ini" file for each language if its present. Is this a good idea? or is there a better way, rather than having to rebuild the plugin with growing resources in the DLL?

Other than that, the new C++ code is using some blocks from the old C (especially the playback) and decodes files and streams quite happily. New sections have be written to handle Unicode only from scratch and libid3tag seems ok with it at the moment. I'm hoping to have more time now to push things along.

Opinions and comments are always welcome 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Kjn_Wds on 2007-07-02 12:16:53
I'm having problems with Last.fm scrobbling system, is the actual MAD plugin fully compatible with it and it's my problem or it's not (and maybe you can manage to add compatibility with it)?

Greetz ^^
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-07-04 13:14:51
The plug-in should be compatible, though I've not tested if Unicode characters work with it. I use last.fm now regularly and seem to have no problem with scrobbling. There was a problem with it a while ago, but that was solved. What kind of problem is occuring, and what winamp and last.fm version are you using?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Kjn_Wds on 2007-07-04 15:18:21
Solved, I was using the last vv of both Last.FM and MAD, but there was something very wrong with my hardware, actually, guess my motherboard is ** up.

Don't know exactly how it managed to compromise scrobbling, but, e.g. I notice d that "something" was checking  the Floppy each time a song was played.
And somehow this + other random things [read: the ghost in the machine] prevented from scrobbling -.-

I know that with this post your consideration of me may be nuked, but I swear I have no way for explaining how my PC escapes from my control, lol
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Domin on 2007-07-21 15:19:59
MoSPDude wouldt there be any way of fixing that annoying OK promth that comes up when winamp drops connection to a stream, so i dont have to click ok.

I just want it to skip to next number without me having to click ok, since there is really no need for me to click ok to it :-)

The OK box just says the following:

Error Reading Data
An unknown error occurred.

and then there is an clickbox with OK in it thats all

Great work you are doing on this plugin, keep it up ;-)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: donkey7 on 2007-07-21 16:00:06
is there a way to synchronize bitrate display with current position in file? on my system bitrate display is delayed by the length of output buffer (i'm using dsound output plugin).

for example if you set buffer length to 20 seconds (max) then winamp will show bitrate of current position + 20 sec in file. it's very annoying to me.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-07-22 18:18:58
I'll remove that OK prompt completely, and leave a notice on the Statistics page of the stream info box with a reason for the stream error. As for the bitrate display at current output position I'll have a look into it.

I'm making a change to the advanced ID3v2 tag editor. Rather than have the fields for the frame appear in one Edit box, I'm hoping for it to open a dialog box with a list of the fields and one Edit box for changes to be made per field. I'm also testing having multiple file info boxes open at once, and allowing Winamp Playlist Editor to continue when one is open.

Its getting near to being complete, its just time consuming 'wiring' up these bits of code to do individual things that the old plug-in code did.

Thanks for your interest still. 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Domin on 2007-08-02 09:51:19
I'll remove that OK prompt completely, and leave a notice on the Statistics page of the stream info box with a reason for the stream error



Your the best 
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: mrinferno on 2007-08-09 19:29:25
I've just recently stumbled on this plugin, so far I really like it.

I have tried to look through this entire post and I don't see any reference to someone requesting the ReplayGain options below.

I use Rockbox on my IAudio X5L mp3 player.  Rockbox has the awesome option below for applying ReplayGain settings:

Quote
Track Gain if Shuffling.
    Maintains a constant volume between tracks if Shuffle is set to Yes. Reverts to album mode if Shuffle is set to No.
Source -> Rockbox Manual (http://download.rockbox.org/manual/rockbox-iaudiox5/rockbox-buildch7.html#x10-1030007.1) (see Section 7.1 Playback -> ReplayGain.)

Is that a possible addition to the in_mad plugin?  I don't think it is possible with the Winamp ReplayGain plugin either.  I've looked in foobar2000 as well, couldn't figure it out there either.

I've been using Mp3Gain for years to manage my ReplayGain values, but I would really like to fully switch over to LAME ReplayGain tags and undo/then remove the Mp3Gain APE tags from my files. 

Any thoughts?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: greynol on 2007-08-09 19:38:22
I've been using Mp3Gain for years to manage my ReplayGain values, but I would really like to fully switch over to LAME ReplayGain tags and undo/then remove the Mp3Gain APE tags from my files.
IIRC, the Lame header does not provide for album gain.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-08-09 20:14:29
I've been using Mp3Gain for years to manage my ReplayGain values, but I would really like to fully switch over to LAME ReplayGain tags and undo/then remove the Mp3Gain APE tags from my files.
IIRC, the Lame header does not provide for album gain.

True. Adding ReplayGain values to ID3v2 tags is a much better choice using foobar's scanner. They can hold both track and album gain infos and are much more widely supported than LAME's internal solution. Besides, this course of action wouldn't implicitly require undoing the MP3Gain modifications, given the fact that album gain had been applied to the files before. If all of them were equally loud, due to having applied track gain to the data, then scanning the files without undoing the changes first would be pointless, of course.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: mrinferno on 2007-08-09 20:16:24
IIRC, the Lame header does not provide for album gain.


Maybe I'm just confused about the "other" ReplayGain implementations.  I know that Mp3Gain writes APE tags to the mp3's.  I thought Foobar/Winamp used the LAME ID3v2 tags to store the ReplayGain analysis info.

When I view the tag details via in_mad of a Foobar/Winamp processed file the ReplayGain info shows up in the LAME ID3v2 Tab under the fields below:
Type: TXXX
1: ISO 8859
2: replaygain_album_gain / replaygain_album_peek / mp3gain_undo

Viewing the same files in Mp3Gain shows nothing, as expected.


Either way, I would still like to see if MoSPDude can comment on whether or not "Track Gain if Shuffling" option is possible.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: greynol on 2007-08-09 20:24:08
I thought Foobar/Winamp used the LAME ID3v2 tags to store the ReplayGain analysis info.
The Lame header is a different animal from ID3v2 tags.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: mrinferno on 2007-08-09 20:31:43
I thought Foobar/Winamp used the LAME ID3v2 tags to store the ReplayGain analysis info.
The Lame header is a different animal from ID3v2 tags.


Ok,  .  Thanks for straightening me out on the terminology.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-08-10 19:12:24
It should be possible to add an option so that Track ReplayGain is applied when shuffle is on, and Album ReplayGain when shuffle is off. I think I'll put it in the drop down list next to the enable checkbox. I'm also adding a "Ignore ReplayGain info in LAME tag" option from a previous request by nemoW.

I'm sidetracking myself from getting tag writing running, and looking into improving the ID3v2.3 tag support by playing with the Winamp 5.3 global configuration. I think I might omit the graphical EQU2 editor and work on improving it as well. Unicode is both a blessing and a curse  .
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: greynol on 2007-08-10 20:48:36
I'm also adding a "Ignore ReplayGain info in LAME tag" option from a previous request by nemoW.
I'd avoid the term LAME tag.  It's more properly described as a header.

This might help stem future misconceptions.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: mrinferno on 2007-08-10 21:36:43
awesome news, glad to hear your considering the option.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-08-11 14:16:02
I'm sidetracking myself from getting tag writing running, and looking into improving the ID3v2.3 tag support by playing with the Winamp 5.3 global configuration.

While you're at it, you could also have a look at a possible bug in the ID3v2.3 handling of the "Year" tag. TYER is completely ignored by Winamp 5.35's Advanced Title Formatting. I just tested this line...
Quote
[%artist% - ]['['%year%']'] [%album% - ][$num(%tracknumber%,1) - ]$if2(%title%,$filepart(%filename%))

... in the settings, which should look like this:
Quote
Amon Amarth - [2006] With Oden on Our Side - 1 - Cry of the Black Birds

I noticed that the [2006] is only displayed if a ID3v1 "Year" or APEv2 "Date" tag exists. With nothing but ID3v2.3 tags found in a file, Winamp leaves an empty space instead.

Besides, some more extensive research revealed that the corresponding "Recording time" TDRC information in ID3v2.4 works well, this issue obviously only relates to ID3v2.3's TYER type.

Update: Adding TDRC to ID3v2.3 works too. Problem is, any application I use writes TYER tags instead. The whole lot of different ID3 standards is a serious mess.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: eevan on 2007-08-11 15:45:27
Yes, there are some issues with TYER frame handiling.
I've tagged a file with mp3tag 2.39 and built-in WinAmp 5.35 tag editor using UTF-16 ID3v2.3, writing only "Year" info.
In both cases, mad plugin showed 2 frames in that file: ZOBS (obsolete frame) with values TYER and the actual year a wrote in the tag and TDRC frame with the ISO encoding and year I entered.

BTW, TDRC is not defined in ID3v2.3. So it looks like a bug.

EDIT: Ah, it seems that everything is fine. There is one option in the plugin's Title/Tags tab that I've missed! "Prevent ID3v2.3 to v2.4 conversion" prevents libid3tag from upgrading v2.3 to v2.4. When checked, the plugin shows only TYER tag.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-08-11 15:52:56
In both cases, mad plugin showed 2 frames in that file: ZOBS (obsolete frame) with values TYER and the actual year a wrote in the tag and TDRC frame with the ISO encoding and year I entered.

This happens with ID3v2.3 tags, when "Enable ID3v2.3 tag writing" and "Prevent ID3v2.3 to v2.4 conversion" are unckecked. Checking them causes the TYER frame to be displayed correctly inside the advanced ID3v2 editor, but Winamp still fails at reading it.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: eevan on 2007-08-11 16:07:35
I'm not sure, but maybe Advanced Title Formating works only with built-in MPEG decoder?

Have you tried to use the title formating in the mad plugin? Although it has only if-then-else.



EDIT: Yes, I've just reproduced all the issues you mentioned. There's something wrong with v2.3 tag handling...
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-08-11 17:28:28
There's something wrong with v2.3 tag handling...

Might be caused by id3frame.h and /libid3tag-0.15.1b/id3tag.h. Both don't contain any definitions for TYER, but only point to TDRC instead.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-08-11 20:57:21
The main problem is that libid3tag was designed to only support v2.4 tags, and so a small piece of code translates any previous ones (including the v1 tag if no v2 tag is found) to v2.4. This results in the ZOBS frames, which contain information about the old frame which is erased when the tag is written by the library. My modification came about by adding the definitions of the v2.3 frames to libid3tag, inhibiting this automatic upgrade of the tag, and improving on a previous modification to write v2.3 tags to specification to the file. This seemed to work ok within the library, although can allow v2.4 frames to slip into v2.3 tags.

The code is very rough, and the plug-in side of the library doesn't look for any other frames than the ID3v2.4 types hence why the problems with v2.3 TYER and v2.4 TDRC frames. This also brings up the issue of strict ID3 tag specification, as I know some taggers do allow a "compatibility mode" where v2.4 frames slip into a v2.3 tag.

It is a mess, and with the introduction of Unicode I ned to sort it out. I've removed both the options and replaced with a single "Enable ID3v2.3 tag support". I was thinking keep ID3v2.3 as v2.3, v2.4 as v2.4, and to keep the library happy have new tags a v2.4.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Junon on 2007-08-12 02:19:53
Thanks for the clarification, this explains quite a lot. For the moment I guess I'll simply workaround the ID3v2 mess by adding APE tags to the files. ID3v2.3 ISO 8859-1 will stay for compatibility reasons, while the few applications supporting APEv2 in MP3 will go for this format instead, which has proven being the least troublesome of them all. Most of the files already contain basic APE tags anyway, since they were processed by aacgain.

Edit: Certainly, I'm a complete idiot. Never process 1041 MP3 files without testing a single file for what MP3tag actually does to the tags. With my setting it entirely rewrote APEv2 instead of updating it with the ID3v2 contents, removing aacgain's undo tags. Of course, I noticed this when it was too late to reverse the rewrite. Better keep my fingers of APEv2 in MP3's case, it's not foolproof.

Oh well... not the big deal, since usually there's no need to undo the Album Gain appliance anyway. Would've been another thing if I had used Track Gain instead, but luckily I never use the latter.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: nemoW on 2007-09-13 16:50:20
For unknown reason MAD plugin cannot play some MP3 files. Resaving with mp3DirectCut don't help, but repacking with MP3Packer help. Other decoders also work fine. Here (http://kvadrograf.by/temp/01-In%20Poison%20Sleep_cut.mp3) is small cut from beginning of problem file.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: robert on 2007-09-13 17:01:20
For unknown reason MAD plugin cannot play some MP3 files. Resaving with mp3DirectCut don't help, but repacking with MP3Packer help. Other decoders also work fine. Here (http://kvadrograf.by/temp/01-In%20Poison%20Sleep_cut.mp3) is small cut from beginning of problem file.
Did you MP3Gain some files which were encoded with CRC protection?

Code: [Select]
robert@sly:~> madplay 01-In\ Poison\ Sleep_cut.mp3
MPEG Audio Decoder 0.15.2 (beta) - Copyright © 2000-2004 Robert Leslie et al.
error: frame 0: CRC check failed
error: frame 2: CRC check failed
error: frame 3: CRC check failed
error: frame 4: CRC check failed
error: frame 5: CRC check failed
error: frame 6: CRC check failed
error: frame 7: CRC check failed
error: frame 8: CRC check failed
error: frame 9: CRC check failed
error: frame 10: CRC check failed
error: frame 11: CRC check failed
error: frame 12: CRC check failed
error: frame 13: CRC check failed
error: frame 14: CRC check failed
error: frame 15: CRC check failed
error: frame 16: CRC check failed
error: frame 17: CRC check failed
error: frame 18: CRC check failed
error: frame 19: CRC check failed
error: frame 20: CRC check failed
error: frame 21: CRC check failed
error: frame 22: CRC check failed
error: frame 23: CRC check failed
error: frame 24: CRC check failed
error: frame 25: CRC check failed
error: frame 26: CRC check failed
error: frame 27: CRC check failed
error: frame 28: CRC check failed
error: frame 29: CRC check failed
error: frame 30: CRC check failed
error: frame 31: CRC check failed
error: frame 32: CRC check failed
error: frame 33: CRC check failed
error: frame 34: CRC check failed
error: frame 35: CRC check failed
error: frame 36: CRC check failed
error: frame 37: CRC check failed
error: frame 38: CRC check failed
error: frame 39: CRC check failed
error: frame 40: CRC check failed
error: frame 41: CRC check failed
error: frame 42: CRC check failed
error: frame 43: CRC check failed
error: frame 44: CRC check failed
error: frame 45: CRC check failed
error: frame 46: CRC check failed
error: frame 47: CRC check failed
error: frame 48: CRC check failed
error: frame 49: CRC check failed
error: frame 50: CRC check failed
error: frame 51: CRC check failed
error: frame 52: CRC check failed
error: frame 53: CRC check failed
error: frame 54: CRC check failed
error: frame 55: CRC check failed
error: frame 56: CRC check failed
error: frame 57: CRC check failed
error: frame 58: CRC check failed
error: frame 59: CRC check failed
error: frame 60: CRC check failed
error: frame 61: CRC check failed
error: frame 62: CRC check failed
error: frame 63: CRC check failed
error: frame 64: CRC check failed
error: frame 65: CRC check failed
error: frame 66: CRC check failed
error: frame 67: CRC check failed
error: frame 68: CRC check failed
error: frame 69: CRC check failed
error: frame 70: CRC check failed
error: frame 71: CRC check failed
error: frame 72: CRC check failed
error: frame 73: CRC check failed
error: frame 74: CRC check failed
error: frame 75: CRC check failed
error: frame 76: CRC check failed
error: frame 77: CRC check failed
error: frame 78: CRC check failed
error: frame 79: CRC check failed
error: frame 80: CRC check failed
error: frame 81: CRC check failed
error: frame 82: CRC check failed
error: frame 83: CRC check failed
error: frame 84: CRC check failed
error: frame 85: CRC check failed
error: frame 86: CRC check failed
error: frame 87: CRC check failed
error: frame 88: CRC check failed
error: frame 89: CRC check failed
error: frame 90: CRC check failed
error: frame 91: CRC check failed
error: frame 92: CRC check failed
error: frame 93: CRC check failed
error: frame 94: CRC check failed
error: frame 95: CRC check failed
error: frame 96: CRC check failed
error: frame 97: CRC check failed
error: frame 98: CRC check failed
error: frame 99: CRC check failed
error: frame 100: CRC check failed
error: frame 101: CRC check failed
error: frame 102: CRC check failed
error: frame 103: CRC check failed
error: frame 104: CRC check failed
error: frame 105: CRC check failed
error: frame 106: CRC check failed
error: frame 107: CRC check failed
error: frame 108: CRC check failed
error: frame 109: CRC check failed
error: frame 110: CRC check failed
error: frame 111: CRC check failed
error: frame 112: CRC check failed
error: frame 113: CRC check failed
error: frame 114: CRC check failed
error: frame 115: CRC check failed
error: frame 116: CRC check failed
error: frame 117: CRC check failed
error: frame 118: CRC check failed
error: frame 119: CRC check failed
error: frame 120: CRC check failed
error: frame 121: CRC check failed
error: frame 122: CRC check failed
error: frame 123: CRC check failed
error: frame 124: CRC check failed
error: frame 125: CRC check failed
error: frame 126: CRC check failed
error: frame 127: CRC check failed
error: frame 128: CRC check failed
error: frame 129: CRC check failed
error: frame 130: CRC check failed
error: frame 131: CRC check failed
error: frame 132: CRC check failed
error: frame 133: CRC check failed
error: frame 134: CRC check failed
error: frame 135: CRC check failed
error: frame 136: CRC check failed
error: frame 137: CRC check failed
error: frame 138: CRC check failed
error: frame 139: CRC check failed
error: frame 140: CRC check failed
error: frame 141: CRC check failed
error: frame 142: CRC check failed
error: frame 143: CRC check failed
error: frame 144: CRC check failed
error: frame 145: CRC check failed
error: frame 146: CRC check failed
error: frame 147: CRC check failed
error: frame 148: CRC check failed
error: frame 149: CRC check failed
error: frame 150: CRC check failed
error: frame 151: CRC check failed
error: frame 152: CRC check failed
error: frame 153: CRC check failed
error: frame 154: CRC check failed
error: frame 155: CRC check failed
error: frame 156: CRC check failed
error: frame 157: CRC check failed
error: frame 158: CRC check failed
error: frame 159: CRC check failed
error: frame 160: CRC check failed
error: frame 161: CRC check failed
error: frame 162: CRC check failed
error: frame 163: CRC check failed
error: frame 164: CRC check failed
error: frame 165: CRC check failed
error: frame 166: CRC check failed
error: frame 167: CRC check failed
error: frame 168: CRC check failed
error: frame 169: CRC check failed
error: frame 170: CRC check failed
error: frame 171: CRC check failed
error: frame 172: CRC check failed
error: frame 173: CRC check failed
error: frame 174: CRC check failed
error: frame 175: CRC check failed
error: frame 176: CRC check failed
error: frame 177: CRC check failed
error: frame 178: CRC check failed
error: frame 179: CRC check failed
error: frame 180: CRC check failed
error: frame 181: CRC check failed
error: frame 182: CRC check failed
error: frame 183: CRC check failed
error: frame 184: CRC check failed
error: frame 185: CRC check failed
error: frame 186: CRC check failed
error: frame 187: CRC check failed
error: frame 188: CRC check failed
error: frame 189: CRC check failed
error: frame 190: CRC check failed
error: frame 191: CRC check failed
error: frame 192: CRC check failed
error: frame 193: CRC check failed
error: frame 194: CRC check failed
error: frame 195: CRC check failed
error: frame 196: CRC check failed
error: frame 197: CRC check failed
error: frame 198: CRC check failed
error: frame 199: CRC check failed
error: frame 200: CRC check failed
error: frame 201: CRC check failed
error: frame 202: CRC check failed
error: frame 203: CRC check failed
error: frame 204: CRC check failed
error: frame 205: CRC check failed
error: frame 206: CRC check failed
error: frame 207: CRC check failed
error: frame 208: CRC check failed
error: frame 209: CRC check failed
error: frame 210: CRC check failed
error: frame 211: CRC check failed
error: frame 212: CRC check failed
error: frame 213: CRC check failed
error: frame 214: CRC check failed
error: frame 215: CRC check failed
error: frame 216: CRC check failed
error: frame 217: CRC check failed
error: frame 218: CRC check failed
error: frame 219: CRC check failed
error: frame 220: CRC check failed
error: frame 221: CRC check failed
error: frame 222: CRC check failed
error: frame 223: CRC check failed
error: frame 224: CRC check failed
error: frame 225: CRC check failed
error: frame 226: CRC check failed
error: frame 227: CRC check failed
error: frame 228: CRC check failed
error: frame 229: CRC check failed
error: frame 230: CRC check failed
error: frame 231: CRC check failed
error: frame 232: CRC check failed
error: frame 233: CRC check failed
error: frame 234: CRC check failed
error: frame 235: CRC check failed
error: frame 236: CRC check failed
error: frame 237: CRC check failed
error: frame 238: CRC check failed
error: frame 239: CRC check failed
error: frame 240: CRC check failed
error: frame 241: CRC check failed
error: frame 242: CRC check failed
error: frame 243: CRC check failed
error: frame 244: CRC check failed
error: frame 245: CRC check failed
error: frame 246: CRC check failed
error: frame 247: CRC check failed
error: frame 248: CRC check failed
error: frame 249: CRC check failed
error: frame 250: CRC check failed
error: frame 251: CRC check failed
error: frame 252: CRC check failed
error: frame 253: CRC check failed
error: frame 254: CRC check failed
error: frame 255: CRC check failed
error: frame 256: CRC check failed
error: frame 257: CRC check failed
error: frame 258: CRC check failed
error: frame 259: CRC check failed
error: frame 260: CRC check failed
error: frame 261: CRC check failed
error: frame 262: CRC check failed
error: frame 263: CRC check failed
error: frame 264: CRC check failed
error: frame 265: CRC check failed
error: frame 266: CRC check failed
error: frame 267: CRC check failed
error: frame 268: CRC check failed
error: frame 269: CRC check failed
error: frame 270: CRC check failed
error: frame 271: CRC check failed
error: frame 272: CRC check failed
error: frame 273: CRC check failed
error: frame 274: CRC check failed
error: frame 275: CRC check failed
error: frame 276: CRC check failed
error: frame 277: CRC check failed
error: frame 278: CRC check failed
error: frame 279: CRC check failed
error: frame 280: CRC check failed
error: frame 281: CRC check failed
error: frame 282: CRC check failed
error: frame 283: CRC check failed
error: frame 284: CRC check failed
error: frame 285: CRC check failed
error: frame 286: CRC check failed
error: frame 287: CRC check failed
error: frame 288: CRC check failed
error: frame 289: CRC check failed
error: frame 290: CRC check failed
error: frame 291: CRC check failed
error: frame 292: CRC check failed
error: frame 293: CRC check failed
error: frame 294: CRC check failed
error: frame 295: CRC check failed
error: frame 296: CRC check failed
error: frame 297: CRC check failed
error: frame 298: CRC check failed
error: frame 299: CRC check failed
error: frame 300: CRC check failed
error: frame 301: CRC check failed
error: frame 302: CRC check failed
error: frame 303: CRC check failed
error: frame 304: CRC check failed
error: frame 305: CRC check failed
error: frame 306: CRC check failed
error: frame 307: CRC check failed
error: frame 308: CRC check failed
error: frame 309: CRC check failed
error: frame 310: CRC check failed
error: frame 311: CRC check failed
error: frame 312: CRC check failed
error: frame 313: CRC check failed
error: frame 314: CRC check failed
error: frame 315: CRC check failed
error: frame 316: CRC check failed
error: frame 317: CRC check failed
error: frame 318: CRC check failed
error: frame 319: CRC check failed
error: frame 320: CRC check failed
error: frame 321: CRC check failed
error: frame 322: CRC check failed
error: frame 323: CRC check failed
error: frame 324: CRC check failed
error: frame 325: CRC check failed
error: frame 326: CRC check failed
error: frame 327: CRC check failed
error: frame 328: CRC check failed
error: frame 329: CRC check failed
error: frame 330: CRC check failed
error: frame 331: CRC check failed
error: frame 332: CRC check failed
error: frame 333: CRC check failed
error: frame 334: CRC check failed
error: frame 335: CRC check failed
error: frame 336: CRC check failed
error: frame 337: CRC check failed
error: frame 338: CRC check failed
error: frame 339: CRC check failed
error: frame 340: CRC check failed
error: frame 341: CRC check failed
error: frame 342: CRC check failed
error: frame 343: CRC check failed
error: frame 344: CRC check failed
error: frame 345: CRC check failed
error: frame 346: CRC check failed
error: frame 347: CRC check failed
error: frame 348: CRC check failed
error: frame 349: CRC check failed
error: frame 350: CRC check failed
error: frame 351: CRC check failed
error: frame 352: CRC check failed
error: frame 353: CRC check failed
error: frame 354: CRC check failed
error: frame 355: CRC check failed
error: frame 356: CRC check failed
error: frame 357: CRC check failed
error: frame 358: CRC check failed
error: frame 359: CRC check failed
error: frame 360: CRC check failed
error: frame 361: CRC check failed
error: frame 362: CRC check failed
error: frame 363: CRC check failed
error: frame 364: CRC check failed
error: frame 365: CRC check failed
error: frame 366: CRC check failed
error: frame 367: CRC check failed
error: frame 368: CRC check failed
error: frame 369: CRC check failed
error: frame 370: CRC check failed
error: frame 371: CRC check failed
error: frame 372: CRC check failed
error: frame 373: CRC check failed
error: frame 374: CRC check failed
error: frame 375: CRC check failed
error: frame 376: CRC check failed
error: frame 377: CRC check failed
error: frame 378: CRC check failed
error: frame 379: CRC check failed
error: frame 380: CRC check failed
error: frame 381: CRC check failed
error: frame 382: CRC check failed
error: frame 383: CRC check failed
error: frame 384: CRC check failed
error: frame 385: CRC check failed
error: frame 386: CRC check failed
error: frame 387: CRC check failed
error: frame 388: CRC check failed
error: frame 389: CRC check failed
error: frame 390: CRC check failed
error: frame 391: CRC check failed
error: frame 392: CRC check failed
error: frame 393: CRC check failed
error: frame 394: CRC check failed
error: frame 395: CRC check failed
error: frame 396: CRC check failed
error: frame 397: CRC check failed
error: frame 398: CRC check failed
error: frame 399: CRC check failed
error: frame 400: CRC check failed
error: frame 401: CRC check failed
error: frame 402: CRC check failed
error: frame 403: CRC check failed
error: frame 404: CRC check failed
error: frame 405: CRC check failed
error: frame 406: CRC check failed
error: frame 407: CRC check failed
error: frame 408: CRC check failed
error: frame 409: CRC check failed
error: frame 410: CRC check failed
error: frame 411: CRC check failed
error: frame 412: CRC check failed
error: frame 413: CRC check failed
error: frame 414: CRC check failed
error: frame 415: CRC check failed
error: frame 416: CRC check failed
error: frame 417: CRC check failed
error: frame 418: CRC check failed
error: frame 419: CRC check failed
error: frame 420: CRC check failed
error: frame 421: CRC check failed
error: frame 422: CRC check failed
error: frame 423: CRC check failed
error: frame 424: CRC check failed
error: frame 425: CRC check failed
error: frame 426: CRC check failed
error: frame 427: CRC check failed
error: frame 428: CRC check failed
error: frame 429: CRC check failed
error: frame 430: CRC check failed
error: frame 431: CRC check failed
431 frames decoded (0:00:11,2), -80,8 dB peak amplitude, 0 clipped samples
Code: [Select]
robert@sly:~> madplay --ignore-crc 01-In\ Poison\ Sleep_cut.mp3
MPEG Audio Decoder 0.15.2 (beta) - Copyright © 2000-2004 Robert Leslie et al.
431 frames decoded (0:00:11,2), -11,9 dB peak amplitude, 0 clipped samples
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: nemoW on 2007-09-13 18:01:15
Did you MP3Gain some files which were encoded with CRC protection?
No. I obtained this files "as is".
Code: [Select]
robert@sly:~> madplay --ignore-crc 01-In\ Poison\ Sleep_cut.mp3
MPEG Audio Decoder 0.15.2 (beta) - Copyright © 2000-2004 Robert Leslie et al.
431 frames decoded (0:00:11,2), -11,9 dB peak amplitude, 0 clipped samples
Hmm, is there any way to remove/hide CRC info besides using MP3packer?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-10-09 09:10:01
I could add an "Ignore CRC" option to the plug-in, but this wouldn't help with the fact the files are at fault.

I'm currently interested in specifically what problems people are experiencing with ID3v2.3 support. I know and have fixed the TYER/TDRC problem. Are there any others?

I've read quite a way back through this thread to catch and fix most the previous problems in this new code, including Icecast2 streams, a more WA5-like basic title formatting and a few hidden RelayGain ones.

Thanks for all your help
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: j7n on 2007-10-09 14:54:27
I'm sorry if I missed something in this very long thread.

What is the status of UTF-8 encoded text from APEv2? Is it in principle impossible to do that in Winamp or does it require one of the most recent Winamp versions? At the moment UTF-8 special characters are displayed as two bytes.

I am using the in_mad.dll dated 2007-01-02 downloaded from your link.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2007-10-09 20:46:18
Hi j7n,

The current plug-in still treated it as ANSI, however this re-written version which I'm close to putting out interprets all the text correctly as UTF-8. It includes a nearly completely rewritten APEv2 tag support enabling binary data too.

The only sections left on my todo list are the ID3v2.3 support and the EQU2 editor. I'm happy with the rest and its effect on my files then
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Mr.Asia on 2007-11-22 03:07:28
so good! i like it and have given in_mp3 up!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: nemoW on 2007-11-22 17:47:48
Is it possible to add support for unicode symbols in path/filename?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: bilbo on 2007-12-01 18:51:34
Hi j7n,

The current plug-in still treated it as ANSI, however this re-written version which I'm close to putting out interprets all the text correctly as UTF-8. It includes a nearly completely rewritten APEv2 tag support enabling binary data too.

The only sections left on my todo list are the ID3v2.3 support and the EQU2 editor. I'm happy with the rest and its effect on my files then


Have you made any progress with your update?
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: MoSPDude on 2008-01-14 13:01:28
I figured I'd post here as well for those who get email notifications on this topic.

I've release an updated version of the plug-in, the new forum topic for it is currently in News Submission forum. The post over there contains the link and information about it.
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: LCtheDJ on 2008-05-09 20:09:29
I figured I'd post here as well for those who get email notifications on this topic.

I've release an updated version of the plug-in, the new forum topic for it is currently in News Submission forum. The post over there contains the link and information about it.


Just to save some search time for anyone trying to find the new topic, it's no longer in News Submission. It's now in Validated News:

http://www.hydrogenaudio.org/forums/index....showtopic=60454 (http://www.hydrogenaudio.org/forums/index.php?showtopic=60454)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: Marzman on 2008-07-17 16:19:09
Hi, I've been listening with in_mad for about a week now. I have a couple of questions... 

1. If I am not dithering and keep at 16-bit, do I even need to use MAD? I just want to make the most of my sound. Even without dsp and eq, i *thought* MAD sounded better than in_mp3.

2. I am unable to find a workaround for listening to AAC+ shoutcast streams. I have deleted the mp3 extension from in_mp3 and winamp will play mp3s and mp3 streams just fine, but no aac streams. 'AAC' is still listed in the file extensions of in_mp3. Any suggestions? Again, I don't use the dither feature of MAD, but thought maybe the internal eq was helping my sound.
Thanks,
Mike
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: benski on 2008-08-12 20:29:13
This decoder fails the MP3 compliance test with 16bit output.
See: http://www.hydrogenaudio.org/forums/index....st&p=582487 (http://www.hydrogenaudio.org/forums/index.php?s=&showtopic=64098&view=findpost&p=582487)
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: weaker on 2008-08-12 21:59:51
Why I use the MAD decoder is the auto-attenuation when clipping occurs. If the Winamp decoder had that, there would be no need for me to use MAD.
Just my 2c
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: j7n on 2008-08-13 06:05:50
Quote
I am unable to find a workaround for listening to AAC+ shoutcast streams. I have deleted the mp3 extension from in_mp3 and winamp will play mp3s and mp3 streams just fine, but no aac streams. 'AAC' is still listed in the file extensions of in_mp3.

Maybe your HTTP streams have no extensions and therefore winamp can't assign them to a specific decoder?

There is little point to use the MAD decoder in Winamp 5.52+. The only unique things it still provides are the interesting stats for stereo mode and clipping. While using the MAD plugin I discovered why some streaming unicasters sound so terrible: simple stereo and clipping by as much as 3 dB due to insufficient bitrate and 0 dB(FS) source.

In Winamp 2 I also decided not to replace the MP3 decoder. We still need the old one for (HE-)AAC, and the built-in in_MP3 has a beautiful spectrum analysis.  Besides no final version with APEv2 support was ever released, only something like betas with confusing version numbers where EQ won't work and there's dependance upon Unicode.

And then both original and MOSPDude's versions have terrible performance. They try to scan the whole file for average bitrate or other stats.

I dare anybody to present examples where in practice we can feel the precision jump from -140 dB to 147 dB!
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: deinlandel on 2008-10-03 07:11:55
I like this decoder, but unfortunately it has very buggin internetional TAGs support, how do i can return that from original MAD plugin, or fix it? It seemed to work normally in original MAD plugin...
Title: Updated in_mad Winamp MAD MP3 input plugin
Post by: hidn on 2008-10-21 04:19:35
try
http://www.hydrogenaudio.org/forums/index....4&hl=in_mad (http://www.hydrogenaudio.org/forums/index.php?showtopic=60454&hl=in_mad)