Help - Search - Members - Calendar
Full Version: foo_dsp_gapless
Hydrogenaudio Forums > Hosted Forums > foobar2000 > 3rd Party Plugins - (fb2k)
Acropolis
discontinued, integrated in crossfader

finally, here it is, no need to explain.
but again, this is my own version, different from what you used before.

changelog

0.2
- a rewrite, now behaves like the one in 0.8.3, even the setting (you should remove the setting in foobar to aviod unexpected errors)

0.1.3
- white noise will be produced when some kind of buffer length value is set, now fixed. if you use crossfader, you should update to 0.1.7.2

0.1.2
- gaps will not be removed after seeking

0.1.1
- fixed the common bug with foo_dsp_crossfader, which produce noise, if you use crossfader, you should update to 0.1.7.1

* VC8 SP1 runtime libraries needed *
Squeller
You are my hero! smile.gif BUT it doesn't work. It consumes a lot of cpu, tracks don't play, the spectrum analyser does show full power after a short click etc...

I'm on w2k here, latest fb2k of course. I guess I've installed the vc8 runtimes because your other components work.

EDIT. Hmm, I removed it, put it back into dsp prefs, now it works.
EDIT2: if I put the slider towards 200 ms, it very soon outputs noise.
Acropolis
yes, I just realise there was a bug in crossfader, it never happened before this component comes out.
please update, as well as crossfader if you use it.
Squeller
Now it works. AFAICS currently your gapless plugin is rather a skip dsp, which does also jump over gaps in the middle of a track, i.e. permanently watches out for gaps. This is the job which is done by the skip_silence plugin.
IMO a pure, simple and effective gap killer should only be active at track ending/beginning and use the least cpu time in between. This way you could also allow to make it only kill gaps which are smaller than e.g. 100 ms (or doesn't the buffer setting refer to the max cut length?). I mean mostly we need this plugin for not properly gaplessly ripped/converted files, which have gaps of just a few milliseconds.

Thanks anyway smile.gif smile.gif smile.gif
Acropolis
no, it will not kill gaps in the middle of a song. it will, only if you do a seeking, because i chose not to detect if it is a new start or just a seek (I assume seeking is a new start, because you may seek to the position that it is still part of the gap should be killed at start, probably this is unwanted?). so it basically only kill the gap at start and at the end.

the buffer length is not the max cut length, it is for the detection of the gaps at the end, larger this value will have more accurate gap detection.
the amount of gaps to kill depends on the value of the threshold and the buffer length.

I think that max cut length is quite useless, if the gap is more than e.g. 100ms, do you want to kill it still? or do I misunderstand what gapless means?

EDIT: update to 0.1.2, now will not kill gaps after seeking
Squeller
QUOTE(Acropolis @ Feb 15 2007, 21:35) *
no, it will not kill gaps in the middle of a song. it will, only if you do a seeking, because i chose not to detect if it is a new start or just a seek (I assume seeking is a new start, because you may seek to the position that it is still part of the gap should be killed at start, probably this is unwanted?). so it basically only kill the gap at start and at the end.

I'm not at home, but I assumed it kills gaps anywhere, because if I set the threshold to a high volume, it permanently skips over a track.

QUOTE
I think that max cut length is quite useless, if the gap is more than e.g. 100ms, do you want to kill it still? or do I misunderstand what gapless means?
I think we just need a threshold value and a max cut length which must be somewhere between >0 and 500 ms or even more, depending on the users need. This would be transparent to the user. The default value could be maybe 100 ms, because the typical gaps are just some milliseconds.

Maybe have a look at the winamp gapkiller. AFAIR it even hasn't a threshold ruler, it simply kills digital silence only. This would also be OK I think. Keep it simple.
Acropolis
providing the threshold as setting is more flexible, those killer without threshold use a fixed value.
try to set the threshold to -40dB, and buffer length to 3000ms or more, will have a good result, as I test it my own.

removing the silence at the end of a song really depends on the buffer length (for my component), so I mostly use 6000ms.
and set crossfader buffer length to 1000ms after this component in the dsp chain.
Chaser
Checking for silcence of 2000ms or more is sometimes useful, if you habe songs, that were recorded with (unwanted) silence at the beginning.

But this is propably not the goal of this pluging?! Rather make gapless albums really gapless?!
Acropolis
I don't quite understand what you mean.

if gapless is meant to remove the gaps at the start and at the end, then "the max. silence to remove" is pointless.
and if an album is gapless, this component won't do anything at the beginning or the end, this is detected by the dB.
Chaser
Hm.
I rephrase my question: Is foo_dsp_gapless able to remove gaps of let's say 3 seconds at the beginning/end of a song?
Acropolis
there's no exact time to remove.
if you set the threshold to -40dB, and the start of the song has 5 sec of samples that < -40dB, it will be removed.
if the end of the song has 2 sec, 2 sec of samples will be removed too.
it all depends on the threshold. of course, if the end of song has 2 sec of silence but you set the buffer length < 2000ms, it will only remove your (buffer length / 1000) sec.
cartman(2vd)
advice me pls how should the dsp chain with gapless and skip silence look.
should gapkiller be before skip silence or it really doesnt matter?
Acropolis
remove skip silence, place gapless before crossfader if you use it.
I put gapless at the first then crossfader, then the others.
cartman(2vd)
QUOTE(Acropolis @ Feb 16 2007, 19:30) *

remove skip silence, place gapless before crossfader if you use it.
I put gapless at the first then crossfader, then the others.


im using skip_silence for skipping long silences often in mp3 with unsevere bonus tracks and gapless for mp3 with 2s gaps on end (yeah someone dont kills those gaps in EAC) and shorter gaps which derivate from mp3 standard. i dont need crossfader so i dont use it biggrin.gif i was just thinking if "gapless" can somehow colide with skip_silence. i understand from your posts that it shuldnt but i was curious biggrin.gif
fluffy
I just found this component, THANK YOU!!!!
Acropolis
QUOTE(cartman(2vd) @ Feb 17 2007, 08:25) *

im using skip_silence for skipping long silences often in mp3 with unsevere bonus tracks and gapless for mp3 with 2s gaps on end (yeah someone dont kills those gaps in EAC) and shorter gaps which derivate from mp3 standard. i dont need crossfader so i dont use it biggrin.gif i was just thinking if "gapless" can somehow colide with skip_silence. i understand from your posts that it shuldnt but i was curious biggrin.gif

for most of the situations if you put skip silence before gapless, it will make gapless useless.
so if you have to use them both, you should put gapless before skip silence.
Chaser
QUOTE(Acropolis @ Feb 16 2007, 12:34) *

there's no exact time to remove.
if you set the threshold to -40dB, and the start of the song has 5 sec of samples that < -40dB, it will be removed.
if the end of the song has 2 sec, 2 sec of samples will be removed too.
it all depends on the threshold. of course, if the end of song has 2 sec of silence but you set the buffer length < 2000ms, it will only remove your (buffer length / 1000) sec.


Thank you! This answered all my questions!
cartman(2vd)
QUOTE(Acropolis @ Feb 17 2007, 04:04) *

for most of the situations if you put skip silence before gapless, it will make gapless useless.
so if you have to use them both, you should put gapless before skip silence.


may i understand it so that skip_silence kills gaps between tracks in same manner as gapless? now im thinking really hard smile.gif ... you wrote both components if i am somehow lost in their functionality pls guide in right direction smile.gif
Acropolis
if you want to kill silence anywhere in a song too, not just the start of and end of a song, you don't need gapless, just use skip silence.
I think most people don't want to remove the silence in the middle of the song.
I said you should put gapless before skip silence is just because you want to use them both, but this is quite stupid.
cartman(2vd)
QUOTE(Acropolis @ Feb 18 2007, 05:16) *

if you want to kill silence anywhere in a song too, not just the start of and end of a song, you don't need gapless, just use skip silence.
I think most people don't want to remove the silence in the middle of the song.
I said you should put gapless before skip silence is just because you want to use them both, but this is quite stupid.


thanks... i didnt know skip_silence kill gaps between tracks... now i see the light at the end thanks.
Squeller
Thx for fixing the white noise issue.
I've got a typical b0rken album which is starving for a gapless plugin, i.e. it has some milliseconds of silence at the beginning and the end of tracks. Your plugin does not handle the files properly, there are sometimes more, sometimes less audible clicks.

Here I've uploaded files to test for you (different from those I sent you over PM), where a terrible click is produced.

http://www.hydrogenaudio.org/forums/index....st&p=473052

The threshold value is set to -40. If you put the files into winamp and have winamps gapkiller turned on, they play really gapless there.

Another problem is: There's no track in fb2k playing, then I double click a track: Your plugin makes it start playing maybe at 500 ms. Not only gap is deleted, but also part of the track. What also makes it start with an audible click. Setting is -40/1000. I could also upload a sample if you want me to.
Acropolis
ok, i think now i quite understand what gapless should do.
I need to reimplement it.
Acropolis
try the new version, now I've made it work like the one in 0.8.3.
I think this is the correct implementation.
Scidd0w
Thank you very much for this plugin Acropolis!!
I've been waiting for you to write this wink.gif

2 questions though.
- I normally use foo_dsp_crossfader with a buffer length of 10000. Should I put foo_dsp_gapples also at 10000
or more?
- What does the seamless option do?

DustMagnet
QUOTE(Acropolis @ Feb 19 2007, 07:30) *

try the new version, now I've made it work like the one in 0.8.3.
I think this is the correct implementation.


Thanks, Acropolis, I think you have it this time. I've been playing music for hours, and the plugin seems to work as I expect.
Squeller
QUOTE(DustMagnet @ Feb 19 2007, 13:16) *
Thanks, Acropolis, I think you have it this time. I've been playing music for hours, and the plugin seems to work as I expect.


Agreed. My "problem album" is now being played as expected.

2 questions:

a) "why is there a 'seemless' toggle, what is the difference, technically? I realized if I don't set it, the result is a short crackle at some points. Does it overlay unique or almost unique samples?

b) Is the buffer length now the precise maximum gap length, which would be deleted?

Thanks for this plugin, there were a lot of demandings for this in the past! Those were difficult discussions, but I better don't want to criticize anyone here.

Edit: Rather a crossfader problem:

I've got your crossfader in the dsp chain, after uie_gapless. In disabled mode. If the crossfader is in the chain, the transition between some tracks is not very fluently.. Without the crossfader, it's perfect. You can use the samples I uploaded, they produce a perfect crackle if the crossfader is in the chain.
Acropolis
QUOTE(Scidd0w @ Feb 20 2007, 06:26) *

2 questions though.
- I normally use foo_dsp_crossfader with a buffer length of 10000. Should I put foo_dsp_gapples also at 10000
or more?
- What does the seamless option do?

seamless actually makes the transition to the next song more fluently, e.g. big volume difference between end of song A and start of song B.
try the 2 files (1.flac and 2.flac) provided by Squeller. it is basically the same as the smooth option in version 0.8.3.

since there's a technical limitation in the foobar architecture, you have 2 options of putting gapless and crossfader in the dsp chain:
if: gapless -> crossfader, then seamless option will not work.
if: crossfader -> gapless, then crossfader will not work when track change (manual track change will work though)
what I can see is you can only put gapless before crossfader to make them useful, or just use one of them only.
btw, 10000ms for crossfader seems too much, that is the fading length!

you can set the buffer length to anything upon your need, it is the max gap length to remove in fact.

QUOTE(Squeller @ Feb 20 2007, 18:35) *

2 questions:

a) "why is there a 'seemless' toggle, what is the difference, technically? I realized if I don't set it, the result is a short crackle at some points. Does it overlay unique or almost unique samples?

b) Is the buffer length now the precise maximum gap length, which would be deleted?

Thanks for this plugin, there were a lot of demandings for this in the past! Those were difficult discussions, but I better don't want to criticize anyone here.

Edit: Rather a crossfader problem:

I've got your crossfader in the dsp chain, after uie_gapless. In disabled mode. If the crossfader is in the chain, the transition between some tracks is not very fluently.. Without the crossfader, it's perfect. You can use the samples I uploaded, they produce a perfect crackle if the crossfader is in the chain.

question a: answered above, the crackle sound you hear in your uploaded 1.flac and 2.flac is an example of the usage.
question b: yes
Rather a crossfader problem: also answered above, it is the limitation of the foobar dsp architecture, I know it, and tried to fix, but just can't find a way.

ps. I'm thinking if to combin all my dsp into a single dll and probably make crossfader and gapless in to one dsp, because if so the above problem can be solved.
Squeller
QUOTE(Acropolis @ Feb 20 2007, 04:25) *
ps. I'm thinking if to combin all my dsp into a single dll and probably make crossfader and gapless in to one dsp, because if so the above problem can be solved.
Thank you so much indeed! If you do, please provide the "external interface", I mean e.g. the crossfader main menu...
Acropolis
it is there already, Playback -> Crossfader
Scidd0w
Thank you for your thourough answer!
Although 10000 at the crossfading lenght seems to be perfect here.. I wil put it a bit down though wink.gif

QUOTE

ps. I'm thinking if to combin all my dsp into a single dll and probably make crossfader and gapless in to one dsp, because if so the above problem can be solved.

This sounds like a great solution for the above problems.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.