Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: foo_wave_seekbar (Read 810892 times) previous topic - next topic
0 Members and 2 Guests are viewing this topic.

foo_wave_seekbar

Reply #875
Is there an upper limit on how many samples you scan? Because I have noticed that long podcasts will not scanned (a behavior I like) because of length so I think his sacd files may not be scanned because they are above the sample limit. For instance the file he posted has 504 908 544 samples total.

foo_wave_seekbar

Reply #876
The file he posted decodes perfectly fine with foo_input_dsdiff, and I've scanned 12 hour mp3s before.
The data types involved are much larger (64-bit ints), so there should be no problems in that area.
Stay sane, exile.

foo_wave_seekbar

Reply #877
His file decodes properly with foo_input_sacd as well. Ensure that you're using a sufficiently new seekbar.
Stay sane, exile.

foo_wave_seekbar

Reply #878
Thank you for your answers.

Perhaps you have not deleted the old plugin foo_input_dsdiff so foo_input_sacd and does not work. There exists a pattern of output frequency is set in the plugin settings foo_input_sacd depends on how much will be displayed in seconds, your plugin (44100 Hz - 5 sec, 88 200 Hz - 10 sec, 176 400 Hz - 20 sec, 352 800 Hz - 40 sec).
razor-87.deviantart.com

foo_wave_seekbar

Reply #879
No. These are completely different foobar2000 installations, so there is no plugin order dependencies.

Please explain in plain text what the problem you observe is, and what you expect to see. I still don't know what is wrong for you.
If the amount of displayed waveform is wrong, the component lies about the sample rate and/or track length.
Stay sane, exile.

foo_wave_seekbar

Reply #880
I checked on the standard pure foobar2000 and assemblies, shows the first few seconds of the track.

razor-87.deviantart.com

foo_wave_seekbar

Reply #881
Indeed, there are some problems with seekbar and SACD ISO images.
I'm using Waveform seekbar version 0.2.13.13 and Super Audio CD Decoder version 0.3.9 in foobar v1.1.8.

It seems that the track length reporting is wrong, so the complete waveform of a track is horizontaly (and verticaly) scaled to the certain fixed length, independently of real track length.

Here are the two screenshots that show this behaviour. The first track (highlighted in the screenshot) is 5:37, and the second is 1:48, and the corresponding waveforms occupy the same horizontal space in the seekbar component.

aaa

Cheers
If age or weaknes doe prohibyte bloudletting you must use boxing

foo_wave_seekbar

Reply #882
Apart for multipass scanning, I have no way of knowing the true length of a track.
I trust the metadata they provide to me, and here, it seems that they blatantly lie.
Stay sane, exile.

foo_wave_seekbar

Reply #883



there are no waves in the form for some segments. is it possible to correct it?

foo_wave_seekbar

Reply #884
That depends entirely on what those images are supposed to illustrate, and what graphics card you have.
The analysis phase records full-scale floating point values, and if you have floating point textures, the shader will recieve those exact values.
Stay sane, exile.

foo_wave_seekbar

Reply #885
the images illustrate that the wave seem to be to big for the box it is in so there is no wave to see.
here is my gpu

foo_wave_seekbar

Reply #886
The default effect fits the range -1.0 through 1.0, so if your decoded audio is outside of that range, it will not fit into the window.
You can always scale the visual in there, or use a RG-aware effect.
Stay sane, exile.

foo_wave_seekbar

Reply #887
where can i find those options?

foo_wave_seekbar

Reply #888
0.2.14 released, previous versions apparently tried to create debug factories with Direct2D, resulting in mysterious failure to load that frontend.
Stay sane, exile.

foo_wave_seekbar

Reply #889
Been playing with a new shader that supports ReplayGain and provides a basic estimate of compression via the relationship between RG track peak and RG track gain. This isn't "perfect", but it works pretty great so far! I'm sleepy and done with playing for the night now tho.

Here's an action-shot of a somewhat-compressed (ie. RG of -8dB or so at a peak of 1) track:


The peak/RMS rendering is still jaggy but the ReplayGain functionality is the fun part anyhow.

Code: [Select]
texture tex : WAVEFORMDATA;

sampler sTex = sampler_state
{
Texture = (tex);
MipFilter = LINEAR;
MinFilter = LINEAR;
MagFilter = LINEAR;

    AddressU = Clamp;
};

struct VS_IN
{
float2 pos : POSITION;
float2 tc : TEXCOORD0;
};

struct PS_IN
{
float4 pos : SV_POSITION;
float2 tc : TEXCOORD0;
};


float4 backgroundColor : BACKGROUNDCOLOR;
float4 highlightColor  : HIGHLIGHTCOLOR;
float4 selectionColor  : SELECTIONCOLOR;
float4 textColor      : TEXTCOLOR;
float cursorPos        : CURSORPOSITION;
bool cursorVisible    : CURSORVISIBLE;
float seekPos          : SEEKPOSITION;
bool seeking          : SEEKING;
float4 replayGain      : REPLAYGAIN; // album gain, track gain, album peak, track peak
float2 viewportSize    : VIEWPORTSIZE;
bool horizontal        : ORIENTATION;
bool flipped          : FLIPPED;
bool shade_played      : SHADEPLAYED;

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;

return output;
}

float4 bar( float pos, float2 tc, float4 fg, float4 bg, float width, bool show )
{
float dist = abs(pos - tc.x);
float4 c = (show && dist < width)
? lerp(fg, bg, smoothstep(0, width, dist))
: bg;
return c;
}

float4 faded_bar( float pos, float2 tc, float4 fg, float4 bg, float width, bool show, float vert_from, float vert_to )
{
float dist = abs(pos - tc.x);
float fluff = smoothstep(vert_from, vert_to, abs(tc.y));
float4 c = show
? lerp(fg, bg, max(fluff, smoothstep(0, width, dist)))
: bg;
return c;
}

// #define BORDER_ON_HIGHLIGHT

float4 played( float pos, float2 tc, float4 fg, float4 bg, float alpha)
{
float4 c = bg;
float2 d = 1 / viewportSize;
if (pos > tc.x)
{
#ifdef BORDER_ON_HIGHLIGHT
if (tc.x < d.x || tc.y >= (1 - d.y) || tc.y <= (2 * d.y - 1))
c = selectionColor;
else
#endif
c = lerp(c, fg, saturate(alpha));
}
return c;
}

float4 evaluate( float2 tc )
{
// alpha 1 indicates biased texture
float4 minmaxrms = tex1D(sTex, tc.x);
minmaxrms.rgb -= 0.5 * minmaxrms.a;
minmaxrms.rgb *= 1.0 + minmaxrms.a;
float below = tc.y - minmaxrms.r;
float above = tc.y - minmaxrms.g;
float factor = min(abs(below), abs(above));
bool outside = (below < 0 || above > 0);
bool inside_rms = abs(tc.y) <= minmaxrms.b;

#if 1
float4 bgColor = backgroundColor;
#else
float a = viewportSize.x / viewportSize.y;
float2 aspect = horizontal ? float2(a, 1) : float2(1/a, 1);
float2 tcBg = float2(tc.x, -tc.y / 2 + 0.5) * aspect;
float4 bgColor = tex2D(sTexBg, tcBg);
#endif

float4 wave = outside
? bgColor
: lerp(bgColor, textColor, 7.0 * factor);

return saturate(wave);
}

float4 peak( float2 tc, float4 bg )
{
float4 minmaxrms = tex1D(sTex, tc.x);
minmaxrms.rgb -= 0.5 * minmaxrms.a;
minmaxrms.rgb *= 1.0 + minmaxrms.a;
if(replayGain.a>0)minmaxrms.rgb /= replayGain.a;
float below = (tc.y - minmaxrms.r);
float above = (tc.y - minmaxrms.g);
//float factor = min(abs(below), abs(above));
bool outside = (below < 0 || above > 0);
float4 wave = outside ? bg : textColor;
return saturate(wave);
}

float4 rms( float2 tc , float4 bg )
{
// alpha 1 indicates biased texture
float4 minmaxrms = tex1D(sTex, tc.x);
minmaxrms.rgb -= 0.5 * minmaxrms.a;
minmaxrms.rgb *= 1.0 + minmaxrms.a;
//minmaxrms.rgb -= 0.5 * minmaxrms.a;
//minmaxrms.rgb *= 1.0 + minmaxrms.a;
if(replayGain.a>0)minmaxrms.rgb /= replayGain.a;
float below = tc.y - minmaxrms.r;
float above = tc.y - minmaxrms.g;
float factor = min(abs(below), abs(above));
bool outside = (below < 0 || above > 0);
bool inside_rms = abs(tc.y) <= minmaxrms.b;

float4 bgColor = backgroundColor;
float4 wave = inside_rms ? selectionColor : bg;
return saturate(wave);
}

float4 rg( float2 tc , float4 bg )
{
float gain=pow(10,replayGain.g/20);
float dist=abs(abs(tc.y/replayGain.a)/gain);
float maxdist=abs(1/replayGain.a)/gain;
bool end=(dist/replayGain.a)>1;
//bool end=tc.y>0;
return lerp(bg,backgroundColor,saturate((dist-1)/(maxdist-1)));

}
float4 PS( PS_IN input ) : SV_Target
{
float dx, dy;
if (horizontal)
{
dx = 1/viewportSize.x;
dy = 1/viewportSize.y;
}
else
{
dx = 1/viewportSize.y;
dy = 1/viewportSize.x;
}
float seekWidth = 2.5 * dx;
float positionWidth = seekWidth;//2.5 * dx;

float4 c0 = backgroundColor;

c0 = peak(input.tc, c0);
c0 = rms(input.tc, c0);
c0 = rg(input.tc, c0);
c0 = bar(cursorPos, input.tc, selectionColor, c0, positionWidth, cursorVisible);
c0 = bar(seekPos,  input.tc, selectionColor, c0, seekWidth,    seeking      );
if (shade_played) c0 = played(cursorPos, input.tc, backgroundColor, c0, 0.5);
return c0;
}

technique10 Render10
{
pass P0
{
SetGeometryShader( 0 );
SetVertexShader( CompileShader( vs_4_0, VS() ) );
SetPixelShader( CompileShader( ps_4_0, PS() ) );
}
}

technique Render9
{
pass
{
VertexShader = compile vs_2_0 VS();
PixelShader = compile ps_2_0 PS();
}
}

foo_wave_seekbar

Reply #890
Huh. I can get a basic waveform to display, but i can't customize it in any way.
I've installed everything suggested in the original post (as far as i can tell).

There is no effects folder or seekbar.fx file anywhere on my computer, and clicking "Frontend settings..." in Foobar doesn't do anything, no window, no nothing.

One thing, though, i don't know if my graphics card supports "PS2.0" (What is that, anyway?).

Running Windows 7 Home premium, 64bit
Intel Core 2 Duo T5750 at 2GHz, 3GB RAM.
ATI mobility Radeon HD 3400 series graphics.
System properties say i'm running DirectX 10.

foo_wave_seekbar

Reply #891
System properties say i'm running DirectX 10.


If you scroll through much of this thread you'll note what's sort-of warned about in the original post too: having DirectX 10 does not mean having the functionality of DirectX 9.0c or whatever. They're different. You explicitly need Directx 9.0c as linked from the front post.

Try that. You wouldn't have an effects folder with the latest version - that's what the frontend editing should do, but try the really correct version DirectX first.

foo_wave_seekbar

Reply #892
A bit of clarification here might help.
The "DirectX version" that your OS tells you is rather unhelpful nowadays, as it roughly tells you the max core level the OS supports.
This component requires more than the core library, it requires the D3DX and D3DCompiler components from February 2010.

In order to get those, you've got to install a redistributable that's at least as new as that. When a game or program asks you to install a particular redistributable, install it. You are typically not capable of determining whether it's needed or not, and it will never be a mistake to install one, as they will only install the bits that are not already present.

As for the settings dialog not opening, not quite sure about that. Ensure that you've got all four DLLs in your users-components/foo_wave_seekbar directory, and haven't messed around with them.
PS 2.0 or SM 2.0 is a level of shader capability of a GPU, which you should exceed by far with your HD3400 card as it claims to be a DX10.1 part, thus having SM 4.1, assuming you have proper drivers installed.
Stay sane, exile.

foo_wave_seekbar

Reply #893
@Zao: Small suggestion: Direct3D and Direct2D entries should be removed from the driopdown menu if the related DLLs are not found in the components folder.

foo_wave_seekbar

Reply #894
There shall be no reason really to erase them really. Are you so strapped for disk space you can't have a stray half meg?
Do you go removing integral parts of random applications to see what happens? 

As for handling it in the settings, it's tricky. The code there is fairly brittle already, especially as it's pretty much impossible to detect whether a frontend is usable until you attempt to use it.
Stay sane, exile.

foo_wave_seekbar

Reply #895
Ok. No big problem

foo_wave_seekbar

Reply #896
Thanks frogworth and Zao, i'm going to try all that out when i get back home today

foo_wave_seekbar

Reply #897
The problem is fixed, thank you very much!

Sorry for the double post, by the way... i can't find the edit button anywhere.

foo_wave_seekbar

Reply #898
The edit button disappears after a while due to past abuse. Don't worry about the double-posting.

foo_wave_seekbar

Reply #899
I'm having the same issue with the frontend settings button doing nothing.

The dlls are in the directory and everything is installed.

I know a couple of other people have run into this problem and seemed to fix it, can they give me any ideas please?