foo_dsp_vlevel, dynamic compressor which amplifies the q |
![]() ![]() |
foo_dsp_vlevel, dynamic compressor which amplifies the q |
May 29 2004, 17:13
Post
#1
|
|
|
Group: Members Posts: 5 Joined: 24-May 04 Member No.: 14297 |
Hi,
I'm developing VLevel foobar2000 plugin. VLevel is a dynamic compressor which amplifies the quiet parts of music developing by Tom Felker. VLevel's site is http://vlevel.sourceforge.net/ . Unfortunately, current version of foo_dsp_vlevel plugin will crash foobar2000 player when you inactive this plugin. I want to fix this stupid bug, but I cat't find what is wrong. If you know the solution, please send me patch. You can download and debug my foo_dsp_vlevel plugin from here: http://wore.ma.cx/foobar2k/ Have fun, wore (info@wore.ma.cx) |
|
|
|
May 29 2004, 17:55
Post
#2
|
|
|
Group: Developer (Donating) Posts: 2040 Joined: 19-October 01 From: Finland Member No.: 322 |
It should help if you move "vl=0;" behind "delete vl;" line in cleanup_buffers function.
|
|
|
|
May 29 2004, 18:06
Post
#3
|
|
|
Group: Members Posts: 5 Joined: 24-May 04 Member No.: 14297 |
QUOTE (Case @ May 29 2004, 08:55 AM) It should help if you move "vl=0;" behind "delete vl;" line in cleanup_buffers function. Thanks. I've remove vl=0; in cleanup_buffers and tested it, but still crashes. |
|
|
|
May 30 2004, 03:32
Post
#4
|
|
|
Group: Members Posts: 273 Joined: 9-August 03 From: MI, USA Member No.: 8257 |
It's kind of odd... at first, the plugin crashed on a bad delete every time I went into the DSP window, but then it abruptly stopped crashing no matter what I did. I guess what you should do is to do more pointer checking, so try checking each pointer individually before deleting them and stuff instead of assuming that all must be valid if vl is. I think it's better to add a few possibly unnecessary if statements than to risk crashing. Initialize your other pointers to 0 in the constructor, too.
Also, you'll want to put vl=0; after (not before) delete vl; in cleanup_buffers(), since otherwise, vl won't get re-initialized to a valid pointer if this line CODE if (vl!=0 && (chunk->get_channels()!=nch || chunk->get_srate()!=srate)) somehow evaluates to true.
|
|
|
|
May 30 2004, 05:21
Post
#5
|
|
|
Group: Members Posts: 5 Joined: 24-May 04 Member No.: 14297 |
QUOTE (bleh @ May 29 2004, 06:32 PM) I think it's better to add a few possibly unnecessary if statements than to risk crashing. Initialize your other pointers to 0 in the constructor, too. I rewrote constructor and cleanup_buffers to correct deletes. But, the reason of crashes is not in constructor and cleanup_buffers. I've fprintf debug to find why Access violation occured. Normally, on_chunk is called with 1024 samples. But, when fb2k crash, on_chunk is called with more than 88200 samples. Buffers allocated only 44100 or 48000 samples. I'll upload fixed version of foo_dsp_vlevel and announce in next 12 hours. Thanks. |
|
|
|
May 30 2004, 17:58
Post
#6
|
|
|
Group: Members Posts: 273 Joined: 9-August 03 From: MI, USA Member No.: 8257 |
Glad you got it fixed. Sorry I was completely wrong about what was causing the problem.
|
|
|
|
May 30 2004, 22:30
Post
#7
|
|
|
Group: Members Posts: 5 Joined: 24-May 04 Member No.: 14297 |
QUOTE (bleh @ May 30 2004, 08:58 AM) Glad you got it fixed. Sorry I was completely wrong about what was causing the problem. Your advice was very helpful for making my plug-in more stable. I appreciate it. |
|
|
|
Jun 6 2004, 07:47
Post
#8
|
|
|
Group: Members Posts: 149 Joined: 6-May 04 Member No.: 13926 |
is the plugin coming anytime soon?
sorry if that sounds rude, its not meant to be This post has been edited by spaceships: Jun 6 2004, 07:48 |
|
|
|
Jun 6 2004, 13:59
Post
#9
|
|
|
Group: Members Posts: 2 Joined: 27-May 03 Member No.: 6839 |
QUOTE (spaceships @ Jun 5 2004, 10:47 PM) is the plugin coming anytime soon? sorry if that sounds rude, its not meant to be Check out the url in wores first post, there is a working version there spaceships. I have tried it out and had no major problems with it. This looks really promising, I have removed it for now as it seems to be a bit of a resource hog and I do like to do other, CPU intensive things while listening to music. |
|
|
|
Jun 6 2004, 18:03
Post
#10
|
|
|
Group: Members Posts: 149 Joined: 6-May 04 Member No.: 13926 |
QUOTE (chichiri @ Jun 6 2004, 04:59 AM) QUOTE (spaceships @ Jun 5 2004, 10:47 PM) is the plugin coming anytime soon? sorry if that sounds rude, its not meant to be Check out the url in wores first post, there is a working version there spaceships. I have tried it out and had no major problems with it. This looks really promising, I have removed it for now as it seems to be a bit of a resource hog and I do like to do other, CPU intensive things while listening to music. oh thanks, i thought he was going to put it as an attachment my apologizes |
|
|
|
Jun 7 2004, 15:32
Post
#11
|
|
|
Group: Members Posts: 3 Joined: 4-June 03 Member No.: 6998 |
You may have noticed problems with seeking before, but I worked on the code a bit and this should fix them. I've sent this to wore, but in case anyone else finds it useful, here it is. This is a debugging build, so it's big, and I don't have an optimizing compiler, so it may be too slow.
http://mtco.com/~tcfelker/foobar2000-vlevel/ |
|
|
|
Jun 7 2004, 16:39
Post
#12
|
|
![]() Group: Developer (Donating) Posts: 1203 Joined: 10-February 02 From: Endless Water Member No.: 1305 |
release compile of foo_dsp_vlevel (as modified by Tom Felker):
http://www.stud.uni-karlsruhe.de/~uybc/foo_dsp_vlevel.dll (I checked it out briefly and it seemed to work - didn't do any rigid testing though, so no guarantees. -------------------- A riddle is a short sword attached to the next 2000 years.
|
|
|
|
Jun 7 2004, 18:31
Post
#13
|
|
![]() Group: Developer (Donating) Posts: 1203 Joined: 10-February 02 From: Endless Water Member No.: 1305 |
For giggles I just added a configuration dialog for the two main VLevel parameters (effect strength and max sample amplification) to foo_dsp_vlevel. oh yea, and a useless about box too.
http://www.stud.uni-karlsruhe.de/~uybc/foo_dsp_vlevel.zip have fun (plugin and source included in zip file) -------------------- A riddle is a short sword attached to the next 2000 years.
|
|
|
|
Jun 11 2004, 03:55
Post
#14
|
|
|
Group: Members Posts: 3 Joined: 4-June 03 Member No.: 6998 |
Hi ssamadhi97, wore,
I just released the most recent dll and put some news on Sourceforge.net, so more people may be using this soon. Thanks for your help. The GUI is great, just a few changes could be made. First, we can implement buffer_length, which should vary between .1 and 10 seconds. Second, it would be nice to have more steps on the strength slider, perhaps 50 or 100. (Are the sliders 100px wide?) Third, max multiplier is disabled when set to zero, but we should tell the user this. One way would be to make it go 2 to 40, with a checkbox to enable it (which would set it to 0 when unchecked.) I'd do this myself, but I'm very rusty with Windows GUI stuff, and besides, I have MSVC++ 6 standard, which doesn't have an optimizing compiler, so I suspect my compiles would result in bad performance. I'm probably going to put the source code into the existing vlevel tree to keep everything in sync. That basically means the include should now be ../volumeleveler/volumeleveler.h. Also, I don't think I changed the API, but please use the latest CVS versions, available here (click on the version numbers, then Download). Have fun. |
|
|
|
Jul 25 2004, 20:11
Post
#15
|
|
![]() Group: Members Posts: 297 Joined: 21-September 03 Member No.: 8934 |
Any progress on implementing the buffer length slider? I like this plugin a lot for listening to (overly) dynamic live recordings, but the default length is quite long...
|
|
|
|
Sep 12 2004, 11:45
Post
#16
|
|
|
Group: Members Posts: 20 Joined: 9-April 03 Member No.: 5897 |
i love this plugin... any updates?
The only problem i can see is a little distortion at the end of every track... otherwise it does the job... |
|
|
|
Mar 12 2006, 19:51
Post
#17
|
|
|
Group: Members Posts: 90 Joined: 22-September 01 Member No.: 4 |
Bumpershoot.
I'd also like to see Garf or somebody else give a thorough explanation of his dynamic compressor. It is more complicated than vlevel and I simply don't understand it, but it seems like it should be able to do the same thing as vlevel, but at default settings it seems to actually *increase* dynamics for most classical music. Crimony! This post has been edited by JohnMK: Mar 12 2006, 19:51 |
|
|
|
Mar 22 2006, 14:10
Post
#18
|
|
|
Group: Members Posts: 41 Joined: 9-May 03 Member No.: 6493 |
Hi !
Now that foobaar2000 version 0.9 is out: Could somebody make this plugin working with 0.9 ? Source code to the original plugin: http://www.mtco.com/~tcfelker/foobar2000-vlevel/ I am using Samadhi97's version all the time while listening to classical music, since I have the same problem with Garf's compressor like the previous poster. |
|
|
|
Mar 23 2006, 14:32
Post
#19
|
|
|
Group: Members (Donating) Posts: 62 Joined: 24-December 05 Member No.: 26611 |
Since I'm having fun fiddling with the foobar2000 SDK, I decided to try port some plugins with source available to foobar2000 0.9.
Here's an experimental version of foo_dsp_vlevel for 0.9:
|
|
|
|
Mar 24 2006, 17:47
Post
#20
|
|
|
Group: Members (Donating) Posts: 62 Joined: 24-December 05 Member No.: 26611 |
I've updated this again. The plugin is now configurable like any other DSP component: from the DSP manager(s). Buffer length is configurable, and the strength control now takes steps of 0.01 instead of 0.1. Note that if you've used the previous version you should properly check the strength control. Grab it here:
|
|
|
|
Mar 24 2006, 23:59
Post
#21
|
|
|
Group: Members Posts: 640 Joined: 13-January 03 From: Marseille Member No.: 4552 |
thanks G-Lite, excellent initiative!
work fine for me. question: it is possible to add option to menu in order to activate/disable vlevel without open dspmanager, same for equalizer? regards, melomane -------------------- Music is my first love.
|
|
|
|
Mar 31 2006, 00:18
Post
#22
|
|
|
Group: Members Posts: 90 Joined: 22-September 01 Member No.: 4 |
Thank you very much for all your work -- it's sincerely appreciated.
Somewhat off-topic: is there a way to apply some kind of dynamic compression to all my mp3s so that when I transfer them to my iPod I can avoid having to change the volume so often between loud/soft parts? |
|
|
|
Jan 24 2007, 16:59
Post
#23
|
|
|
Group: Members Posts: 1 Joined: 21-August 06 Member No.: 34307 |
Thank you very much for all your work -- it's sincerely appreciated. Somewhat off-topic: is there a way to apply some kind of dynamic compression to all my mp3s so that when I transfer them to my iPod I can avoid having to change the volume so often between loud/soft parts? you could re encode them with foobar and select a compressor as DSP that is applied during compression. |
|
|
|
Mar 25 2007, 07:52
Post
#24
|
|
|
Group: Members Posts: 90 Joined: 22-September 01 Member No.: 4 |
Thank you very much for all your work -- it's sincerely appreciated. Somewhat off-topic: is there a way to apply some kind of dynamic compression to all my mp3s so that when I transfer them to my iPod I can avoid having to change the volume so often between loud/soft parts? you could re encode them with foobar and select a compressor as DSP that is applied during compression. I'm hoping to avoid transcoding. Surely there's a way simply to adjust the volume level of a frame? :-/ |
|
|
|
Mar 26 2007, 01:32
Post
#25
|
|
|
Group: Members Posts: 384 Joined: 2-May 05 Member No.: 21825 |
There is a way to change the volume of mp3 frames. That's how mp3gain works. But that won't be a solution to your problem, since using this to change the volume during tracks would result in noticeable volume steps. In addition I doubt that a programm that can do that has ever been written.
|
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 19th May 2013 - 20:43 |