Skip to main content

Topic: foo_wave_seekbar (Read 517311 times) previous topic - next topic

0 Members and 1 Guest are viewing this topic.
foo_wave_seekbar
Reply #950
That's a rather attractive skin, colagen. Props.

Thanks ! But now, it is really attractive, at least for me  I finally take some hours to learn how to hide the scrollbars and others things. Next step for my next "what the f.. could i do this weekend" would be to learn how to do advanced things with WSH panel, but eh i've already fall too far into the foobar madness skinning.
With waveform + the two chanel spectrum panels i've add in the background (the big brown one is maybe hard to see in the screenshot), it seems that my foobar is now alive



Love to know how you did this please?

  • SmartOne
  • [*]
foo_wave_seekbar
Reply #951
Is there an easy way to edit the HLSL making the waveform look sharp like in Audacity?

And maybe a way to show clipping as a different color, while you're at it.
  • Last Edit: 05 February, 2012, 03:49:49 PM by SmartOne

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #952
That depends entirely on what "sharp like Audacity" means.
As for clipping, predicate the color for a column based on whether the min/max exceeds 1.0 or not.
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • SmartOne
  • [*]
foo_wave_seekbar
Reply #953
Sharp as in the edges aren't faded.  I don't like fading on the waveform or the selection.

  • MDMA
  • [*][*]
foo_wave_seekbar
Reply #954
what would I type in seekbar.fx to add a couple of pixels worth of vertical padding to the top and bottom of my seekbar? I'd like to give it more 'float' space

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #955
In the VS function, on the line before return output; you could add output.tc.y *= 1.2; which would make the range of the display from -1.2 to 1.2 (with 1.0 being full-scale).
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • SmartOne
  • [*]
foo_wave_seekbar
Reply #956
I'm having trouble deciphering the purpose of each of the variables (comments?).  I also don't know HLSL (but who cares, right?).  What is tc?  How can I determine the value of the waveform at an arbitrary point and color it red when it hits the maximum amplitude (indicating clipping)?

After much tinkering, the waveform and seekbar are now sharp (no ugly fading).  That's the extent of my progress.

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #957
Comments? Those are for the weak, I hear. 

The x-component of tc indicates the position along the waveform. 0.0 is snugly against the left side of the window, 1.0 is to the far right of the window. In the PS (pixel shader), a tc.x of 0.25 would be 25% from the left side of the window.

The y-component of tc indicates at what absolute signal level the top and bottom of the window is at. The default of 1.0 makes the vertical range of the window from -fullscale to +fullscale.

The pixel shader function runs once for every pixel (fragment) of the window, with the parameters interpolated from the values set in the corners by the vertex shader.

The way the waveform is rasterised is that the x-component is used to sample the texture representing the amplitude data. The resulting data is then tested against the y-component to see if it's outside or inside the waveform, and coloured appropriately. If you get rid of the interpolations/smoothsteps at that border, you get an aliased sharp edge.

You can have a predicate picking a particular colour for the fragment if the sampled value (min/max) is larger than 1.0, instead of the default color. As for the exact place to do that, you've got to find on your own as I do not use the default shader anymore.
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • MDMA
  • [*][*]
foo_wave_seekbar
Reply #958
In the VS function, on the line before return output; you could add output.tc.y *= 1.2; which would make the range of the display from -1.2 to 1.2 (with 1.0 being full-scale).


Thanks a lot for this but I am pretty clueless on scripting. Would it be possible to just add it in its own line at the end of the config?

  • SmartOne
  • [*]
foo_wave_seekbar
Reply #959
Thank you for the help.  I think I figured it out (at least, it looks accurate):

Code: [Select]
float4 wave;
if(minmaxrms.y > 1.0){
bgColor.r = 1.0;
bgColor.g = 0.0;
bgColor.b = 0.0;
wave=bgColor;
}
else if(outside)
wave = bgColor;
else
wave = textColor;

return wave;

This replaces the if statement at the end of evaluate(), making clipping parts red.

MDMA, I think you need to add the line [font= \"Courier New\"]output.tc.y *= 1.2;[/font] to the end of VS().  The result should look like this:

Code: [Select]
PS_IN VS( VS_IN input )
{
PS_IN output = (PS_IN)0;

float2 half_pixel = float2(1,-1) / viewportSize;
output.pos = float4(input.pos - half_pixel, 0, 1);

if (horizontal)
{
output.tc = float2((input.tc.x + 1.0) / 2.0, input.tc.y);
}
else
{
output.tc = float2((-input.tc.y + 1.0) / 2.0, input.tc.x);
}

if (flipped)
output.tc.x = 1.0 - output.tc.x;

output.tc.y *= 1.2;
return output;
}
  • Last Edit: 08 February, 2012, 10:27:49 PM by SmartOne

  • mforceew
  • [*]
foo_wave_seekbar
Reply #960
Hello everyone. I'm newbie in foobar. How can i make waveform seekbar thinner? Thank you.

  • MDMA
  • [*][*]
foo_wave_seekbar
Reply #961
Thanks, although I have added it in so it is like so:

Code: [Select]
if (horizontal)
        output.tc = float2((input.pos.x + 1.0) / 2.0, input.pos.y);
    else
        output.tc = float2((-input.pos.y + 1.0) / 2.0, input.pos.x);

    output.tc.y *= 1.2;
    return output;
}


and it doesn't seem to be doing anything. Is there a conflict from the output.tc = float lines? thanks

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #962
No, operations are done in sequence. It's probably due to how your PS function uses the texcoords. It does a difference in my shader, and as mentioned, I don't use the default effect anymore.
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • MDMA
  • [*][*]
foo_wave_seekbar
Reply #963
No, operations are done in sequence. It's probably due to how your PS function uses the texcoords. It does a difference in my shader, and as mentioned, I don't use the default effect anymore.


Nor I, here is a copy of my current seekbar.fx config:
https://privatepaste.com/00c389b6a4

  • Dandruff
  • [*][*][*][*][*]
foo_wave_seekbar
Reply #964
SciLexer.dll from http://prdownloads.sourceforge.net/scintil...03.zip?download is at version number 3.0.3.0 while Waveform Seekbar's is at 2.2.6.0. Can we use the 3.0.3.0 one?

  • lvqcl
  • [*][*][*][*][*]
  • Developer
foo_wave_seekbar
Reply #965

  • Dandruff
  • [*][*][*][*][*]
foo_wave_seekbar
Reply #966
I strongly recommend against dropping in a binary build of SciLexer, at least until I remember if I build mine in any special way.


Why do you recommend avoiding the scilexer dll update? Just tried the 3.0.3.0 DLL and it seems to work fine with Waveform Seekbar 0.2.16!
  • Last Edit: 23 February, 2012, 09:16:15 AM by Dandruff

  • enigmatik
  • [*]
foo_wave_seekbar
Reply #967
Is it possible to move wavecache.db to some other location outside foobar's main directory?

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #968
Please don't modify things, even if it "seems to work fine". I've got enough pain in debugging crash dumps without people running things I have not built in unsupported configurations.
I have not seen any reason whatsoever to upgrade, and I don't see why I should change something that works properly for something that most probably is larger, has different semantics and comes with additional maintenance requirements, just because someone feels that "higher is better, lol".

In particular, I use the non-message interface to it, which couples the library built with and the library used at runtime more than the poor message interface.

It's not a matter of "why do you not upgrade",  it should be "why should I upgrade".
  • Last Edit: 23 February, 2012, 04:09:21 PM by Zao
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #969
Is it possible to move wavecache.db to some other location outside foobar's main directory?

Known request, needs thinking.
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #970
Why do you recommend avoiding the scilexer dll update? Just tried the 3.0.3.0 DLL and it seems to work fine with Waveform Seekbar 0.2.16!

I've updated it in my sources for no reason what-so-ever. I redirect all blame for the pointless file size increase to you.

Also, yet again, I do not recommend against building against some particular version. I recommend against replacing DLLs you have no idea about how they are built or what customizations are in place.
Multi-module programming is hard enough without all the unknown variables you cause.
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • tribaljet
  • [*][*]
foo_wave_seekbar
Reply #971
Hello. I've seen foo_wave_seekbar used on many different configs and themes, and I've decided to give it a try, being quite pleased at the result. But I have a small problem, which is being unable to find where seekbar.fx is located. I'm using a portable foobar2000 installation, but the file isn't located on the portable folder nor on the Appdata folder. Switching to a normal installation isn't an option for me, but what boggles my mind is that I did a full search on my HDDs and couldn't locate the file at all.

Can someone shed some light on this?

Thanks in advance

  • Zao
  • [*][*][*][*][*]
  • Developer (Donating)
foo_wave_seekbar
Reply #972
It was moved from being a file to being a per-instance setting many versions ago.
Add a seekbar, right click it to get the configuration dialog and hit the "Frontend settings..." button to get a text editor with the effect source.
This is the same in both portable and non-portable installs.
Zao shang yong zao nong zao rang zao ren zao.
To, early in the morning, use a chisel to build a bathtub makes impatient people hot-tempered.

  • Dandruff
  • [*][*][*][*][*]
foo_wave_seekbar
Reply #973
Why do you recommend avoiding the scilexer dll update? Just tried the 3.0.3.0 DLL and it seems to work fine with Waveform Seekbar 0.2.16!

I've updated it in my sources for no reason what-so-ever. I redirect all blame for the pointless file size increase to you.

Also, yet again, I do not recommend against building against some particular version. I recommend against replacing DLLs you have no idea about how they are built or what customizations are in place.
Multi-module programming is hard enough without all the unknown variables you cause.


Other question: Can we delete the SciLexer DLL savely? I don't need to change the Direct3D Frontend settings here.

  • tribaljet
  • [*][*]
foo_wave_seekbar
Reply #974
It was moved from being a file to being a per-instance setting many versions ago.
Add a seekbar, right click it to get the configuration dialog and hit the "Frontend settings..." button to get a text editor with the effect source.
This is the same in both portable and non-portable installs.


Thanks Zao. Another question. Is there a guide for editing Frontend settings? Because mine is currently empty and I'm not familiar with what I should add there.