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_enhanced_spectrum_analyzer (Read 59757 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Re: foo_enhanced_spectrum_analyzer

Reply #125
For anyone who impatient of a big update to this component, I updated one of my CodePen audio visualization (the ones that originally intended for interactive mockup of CQT/VQT spectrum analyzer component for fb2k x64) to add something like this:
X
which is FFT bandpower spectrum with 1/24th octave bands, just like foo_musical_spectrum and audioMotion-analyzer

BTW, I did this ahead of @Crossover updating foo_enhanced_spectrum_analyzer (hopefully, a spectrogram view, non-power of 2 FFT sizes, and linear amplitude scale)

Re: foo_enhanced_spectrum_analyzer

Reply #126
-snip-
The mel scale would be a nice option. I will keep that in mind. But that contradicts the concept I am working on at the moment cause the idea is to display the musical spectrum (notes) together with the frequency spectrum. I have attached a picture for this.
A function that displays different channels individually or simultaneously would also be a good option. For me personally, this function is not a high priority because I mostly listen to music that uses stereo channels.
As for the feature request of letting you visualize all channels as FFTs of each channel, I meant this: (BTW, I've updated this interactive mockup to add this, which already exists on the similar spectrum analyzer plugin for another music player except for the M/S part)
X
And for Mid/Side part (which can be easily done using M/S encoding then doing FFTs of resulting M/S signal for visualization):
X

Re: foo_enhanced_spectrum_analyzer

Reply #127
How about a spectrogram display in-addition to spectrum display like showcqt visualization?

BTW, I made the spectrum analyzer similar to Crossover's component and it features linear amplitude scale, which is useful for easily visualizing peaks
I meant something like this:
X
where spectrum is at top and spectrogram is at bottom, scrolling from top to bottom just like this FFmpeg filter mentioned before

Re: foo_enhanced_spectrum_analyzer

Reply #128
Yet another feature request for this component: Custom colorstop position for each gradient colorstops (which is already possible in audioMotion-analyzer) and infinite number of colorstops like in built-in spectrogram visualization

This makes something like this below possible:
X

As for the UI for customizing color gradients, I like this one from PowerPoint something like this:
X

Re: foo_enhanced_spectrum_analyzer

Reply #129
I will implement something like this:

It can also be configured to show notes and the frequency grid:

FR when comes to the new frequency bands mode @Crossover is working on it above: Adjustable number of bands per-octave (because foo_musical_spectrum don't have it and I realized there are other variations of equal-temperament scales like 24-TET/quarter tone scale (also known as 1/24th octave bands, 240 bands within 20Hz-20kHz range, and of course Arab tone system) as I've read the Wikipedia page about it) and tuning for fractional octave band visualization (nearest note to specific frequency = specific frequency as in my own spectrum analyzer)

Also FR: Being able to enable or disable antialiasing on drawing graphs for nicer looking visualization closer to CanvasRenderingContext2D at the cost of some FPS drops and optional GPU acceleration (as this component uses a lot of my CPU) regardless of antialias setting

BTW, there are one regression I've noticed on the current version (1.9.2.0) is the window function setting does absolutely nothing (it stays using Hann window regardless of the window type they supposed to)

Re: foo_enhanced_spectrum_analyzer

Reply #130
For frequency bands mode @Crossover are working on, a sinc (or more accurately, Lanczos) FFT bin interpolation would be cool to have, however, a proper one requires the use of real/imaginary pairs to look like this (similar to FFT with zero-padding):
X
instead of this:
X
where this second image above looks more like something other than zero-padded FFT or Goertzel

BTW, are the aforementioned dev of foo_enhanced_spectrum_analyzer busy with other stuffs, or just working hard on a massive update? (since there aren't replies to me 4 months ago)

Re: foo_enhanced_spectrum_analyzer

Reply #131
BTW, are the aforementioned dev of foo_enhanced_spectrum_analyzer busy with other stuffs, or just working hard on a massive update? (since there aren't replies to me 4 months ago)
You know, I don't want to seem crass or hurt anyone's feelings, but my own belief is that the developer has been happily using his new updated spectrum for a while now, and the reason he hasn't announced/made it available here is because he doesn't want to be "jumped on" by theorists or others asking him to change/try/replace this that or the other thing.  TF3RDL, I respect your obviously large body of knowledge about the subject, but I believe you should be working on your own spectrum release instead of what might be interpreted as lecturing/pressuring this developer on how to design his.  I'm sorry if this post offends, it's not meant to, but like you and many others I have been awaiting Crossover's Musical Spectrum/Enhanced Spectrum Analyzer hybrid and think we just have to let things "breathe" and give the message that anything he shares will be welcome.

Re: foo_enhanced_spectrum_analyzer

Reply #132
You know, I don't want to seem crass or hurt anyone's feelings, but my own belief is that the developer has been happily using his new updated spectrum for a while now, and the reason he hasn't announced/made it available here is because he doesn't want to be "jumped on" by theorists or others asking him to change/try/replace this that or the other thing.  TF3RDL, I respect your obviously large body of knowledge about the subject, but I believe you should be working on your own spectrum release instead of what might be interpreted as lecturing/pressuring this developer on how to design his.  I'm sorry if this post offends, it's not meant to, but like you and many others I have been awaiting Crossover's Musical Spectrum/Enhanced Spectrum Analyzer hybrid and think we just have to let things "breathe" and give the message that anything he shares will be welcome.
I liked the idea to work on my own spectrum visualization (perhaps a 64-bit remake of Musical Spectrum, Channel Spectrum panel, etc. in similar way to ReFacets) because the development time of the upcoming update on foo_enhanced_spectrum_analyzer would be absurdly long if they decided to implement most if not all of my requests to add these features (remember, do bugfixes first before adding new features is the best, because of the fact that known problematic components are barred from mentioning on component recommendation posts)

However, I don't actually have any experience with C++ nor foobar2000 SDK to actually make the visualization component that I've want and I only have experience with JS and Web Audio API (the latter doesn't exist in SMP component and I don't think adding WebAudio API support to SMP helps), therefore that's why it posted these visualizations on CodePen as a small web app not a fb2k 64-bit component, so good luck with anyone looking for Musical Spectrum and Channel Spectrum panel (with Default UI support) remake for foobar2000 x64

BTW, I also agree with your statement about pressuring the developer to add something that I've want (spectrogram view in-addition to spectrum, adjustable number of bands on frequency bands mode, linear/sqrt amplitude scale, perceptual frequency scales, a feature to display separate channels and even Mid/Side spectrum, etc.) because of reasons that I said before (the more requests the developer accepted and actually working on implementing these, the longer development time is)

Re: foo_enhanced_spectrum_analyzer

Reply #133
another FR: Bring back the crest factor (Peak/RMS) visualization but with same framerate and details (for consistency) as the rest of spectrum visualizations on this component

Re: foo_enhanced_spectrum_analyzer

Reply #134
yet another FR: Frequency weighting functions (A, B, C, D, and M/ITU-R 468) in-addition to frequency tilt, with the amount being adjustable (e.g. a weighting amount of 0.5 is a square root of frequency weighting functions applied to the FFT, setting it to zero applies no weighting (or in other words, Z-weighting), and negative values gets the opposite amount (FFT spectrum prior to log-amplitude transformation divided by weighting functions instead of multiplying by it) of weighting)

Re: foo_enhanced_spectrum_analyzer

Reply #135
A "true RMS" mode (where the averaging is done in squared domain and then take a square root to convert to linear amplitude scale) would be appreciated as currently, the averaging is done in logarithmic amplitude scale instead of linear.

And also, I would appreciate analog-style analyzer mode like this:
X
for new frequency bars visualization mode like in Spectralissime spectrum analyzer app and Seven Phases Spectrum Analyzer VST plugin where it doesn't use FFT and instead uses IIR biquad bandpass filter bank.

Re: foo_enhanced_spectrum_analyzer

Reply #136
Feature Request: any chance to have the option to configure foo_enhanced_spectrum_analyzer to run on a different logical cpu?
(a logical different from the one hosting foobar main thread so as to move the workload away from foobar main thread cpu)

Re: foo_enhanced_spectrum_analyzer

Reply #137
Regarding the performance issue (low FPS on fullscreen mode of this component), did anyone have this same issue?

Since this component needs some optimizations in order to keep up with the performance of my own CodePen project like this and even AudioWorklet-based one (obviously, it is pure JS for both AudioWorklet and actual audio analysis part) on fullscreen mode as of right now, even the 1/48th octave analog-style analyser (even though the actual audio analysis algorithms are done in a main thread) on the aforementioned CodePen project runs faster than Enhanced Spectrum analyzer component for foobar2000

 

Re: foo_enhanced_spectrum_analyzer

Reply #138
BTW, are the aforementioned dev of foo_enhanced_spectrum_analyzer busy with other stuffs, or just working hard on a massive update? (since there aren't replies to me 4 months ago)
You know, I don't want to seem crass or hurt anyone's feelings, but my own belief is that the developer has been happily using his new updated spectrum for a while now, and the reason he hasn't announced/made it available here is because he doesn't want to be "jumped on" by theorists or others asking him to change/try/replace this that or the other thing.  TF3RDL, I respect your obviously large body of knowledge about the subject, but I believe you should be working on your own spectrum release instead of what might be interpreted as lecturing/pressuring this developer on how to design his.  I'm sorry if this post offends, it's not meant to, but like you and many others I have been awaiting Crossover's Musical Spectrum/Enhanced Spectrum Analyzer hybrid and think we just have to let things "breathe" and give the message that anything he shares will be welcome.
You're right sveakul :-) I've been using the V2 of the component since mid-2023, but that doesn't mean I'm going to ignore TF3RDL's posts. I will come back to it later. But for now, I'm going to use my time to take a closer look at the component's "performance problem". I don't think it's really a "performance issue", but rather a superfluous use of "perfectionism". I will analyse this and hopefully I can reduce the CPU consumption.

Re: foo_enhanced_spectrum_analyzer

Reply #139
I'd be patient about optimizations on this component to get 60FPS on fullscreen mode and lower CPU usage, and my proposed analog-style analyzer/IIR filter bank mode (right now, there is no analog-style spectrum analyzer component for fb2k, so I used foo_dsp_vst3 to visualize audio using Voxengo AnSpec) for frequency bands mode can benefit from usage of SIMD instructions (for the case of AVX instruction usage, a fallback to SSE4.2 and SSE2 for stability) and multithreading can benefit the performance of calculating two or more spectrum in this case of multiple graphs (which foo_vis_spectrum_analyzer going to have) and/or overlayed channel spectrum displays right?

Also, add a Gaussian window function (with window parameter of 2.4 to match foobar2000's built-in spectrum visualization method) in-addition to fixing the regression of window function settings not actually applying different windowing functions as well as adding an option to show either the DC label (only shown when used with any frequency scale other than logarithmic), Nyquist frequency marker, or both

BTW, I think the @Crossover's Enhanced Spectrum analyzer (foo_enhanced_spectrum_analyzer, this component) and @pqyt's Spectrum Analyzer (foo_vis_spectrum_analyzer) serves different purposes even though both of them are spectrum analyzers; the former is for something like professional audio analysis and the latter is for eye candy, but still serves more useful purposes than Winamp's Classic Spectrum Analyzer plugin

Re: foo_enhanced_spectrum_analyzer

Reply #140
FRs for this component: Fullscreen mode and UI color scheme integration on a Columns UI panel version of this component as well as an option to actually use gradients when using UI color integration as in Loudness Peakmeter component by the same @Crossover

Also, just because foo_vis_spectrum_analyzer finally added IIR filter bank mode for spectral analysis doesn't mean Enhanced Spectrum analyzer shouldn't get one too especially with upcoming frequency bars mode (hopefully with adjustable number of bands per-octave and an option to use ANSI preferred frequencies)

Re: foo_enhanced_spectrum_analyzer

Reply #141
Installed this a few weeks ago, its AWESOME! Used it to show where a mix was too loud, worked perfectly :-)
Should be in the main foobar repository page in my opinion
cheers
Stu

Re: foo_enhanced_spectrum_analyzer

Reply #142
A "true RMS" mode (where the averaging is done in squared domain and then take a square root to convert to linear amplitude scale) would be appreciated as currently, the averaging is done in logarithmic amplitude scale instead of linear.
Also FR: Infinite averaging mode, where the average spectrum converges to the curve by the time the song reaches the end (and infinite averaging can be reset by either using "Reset Peak and RMS" option or just seeking or playing a next song), and exponential averaging mode, which is behaves similarly to Voxengo SPAN and it is controlled by "Velocity" parameter in dB per second instead of "Average Length" in milliseconds

Re: foo_enhanced_spectrum_analyzer

Reply #143
Honestly, with all of my feature requests for this component (and teases of Musical Spectrum-like bars and piano notes by @Crossover), just let @Crossover cook this update for this component long enough

BTW, if you're optimizing foo_enhanced_spectrum_analyzer with AVX2 instructions (including brand new features or even implementation of my feature requests), don't forget to implement fallbacks to implementations using older SIMD instructions so it won't introduce the same CPU instruction set requirement as PGGB-RT that would be unnecessary for a simple spectrum analyzer component I think

Re: foo_enhanced_spectrum_analyzer

Reply #144
Feature request for @Crossover: Spectrogram display (since I saw the spectrogram display for foo_vis_spectrum_analyzer being worked on)

Something like this:
X
which is similar to built-in spectrogram, but with Hz labels and even time labels (not shown in this image) and I'd prefer the spectrogram display to be added into this component since you don't even need creating a new component dedicated for that and this feature request is a little bit different from combined spectrum/spectrogram as it only display spectrogram, and this (and showcqt-style spectrum/spectrogram display) should work with another feature request (analog-style analyzer mode, which is the closest thing to ever get a realtime constant-Q transform but have better performance I think)

Of course, the option to use more accurate framerate-independent timings (FFT analyzers only as IIR filter bank mode is calculated sample-by-sample just like sliding DFT), toggleable "reset spectrogram upon seek", and "resolution X axis" (Y-axis in case of combined spectrum/spectrogram) when either using framerate-independent timing on FFT mode or use IIR filter bank mode for consistency with Loudness Peakmeter component

BTW, just don't expect these feature requests to be implemented all at once nor even the update would be released much sooner

Re: foo_enhanced_spectrum_analyzer

Reply #145
New version 2.0.0.0 has finally released!
- NEW: Added back crest factor spectrum with various changes to be consistent; it now have same details and FPS for the crest spectrum as the rest
- NEW: Frequency weighting functions (A, B, C, D, and ITU-R 468/M-weighting supported)
  - Can be adjusted by "Weighting amount" parameter in percentages and it can also be set to negative values to do the exact opposite
  - Equal-loudness contour and K-weighting are also supported
- NEW: Mel, Bark, ERB (equivalent rectangular bandwidth), and linear frequency scales
- NEW: Octave bands mode in which details of the visualization are controlled by bands per octave option
  - Can be set to use either an ANSI S1.11-2004 standard (preferred base-10) or equal-tempered scale with arbitrary frequency tuning (not limited to 440Hz or 432Hz) for octave band center frequencies
- NEW: IIR filter bank mode for frequency bars (octave bands) mode for optimal time/frequency resolution tradeoff on logarithmic frequency scale
  - It uses cascaded Butterworth second-order sections for IIR filter design for the filter bank
  - The filter order can be set to higher values to improve rolloff but at the expense of poorer time resolution on bass frequencies
- NEW: Bars drawing mode for both detailed FFT and frequency bands mode
- NEW: An option to decouple FFT calculation from FPS, which is useful for spectrogram displays and better behaved average spectrum and it allows setting the FFT hop size to a set amount in milliseconds to adjust "accuracy" of average spectrum
  - This doesn't apply to IIR filter bank mode, and in this case, it is always on and the hop size parameter only affects spectrogram scrolling speed
- NEW: Spectrogram display, works best with new "Decouple FFT calculation from FPS"
  - Can either be static or scrolling spectrogram
  - Can display both spectrum and spectrogram at the same time
  - Can also be set to display multiple channels by having different colors
  - Scrolling speed is adjustable via "Hop size" parameter, similar to "Resolution X-axis" in Loudness Peakmeter
- NEW: Multiple channels display
  - Can either have separate graphs for each channel or have multiple spectrum of each channel superimposed into a one graph with different colors for each channels
  - Supports Mid/Side representations not just individual channels
- NEW: Non-power of two FFT sizes and FFT size can be set in milliseconds rather than samples (decoupling the time/frequency resolution from sample rate; 100ms is 4800 samples on 48kHz sampling rate), and also 65536 samples FFT
- NEW: Infinite decay rate mode (-inf dB per second falloff) for any graphs including the restored crest spectrum
  - On IIR filter bank mode, the Peak graph is a maximum of latest 576 samples (and below if FPS is high enough) of an absolute value of the output to avoid photosensitive epilepsy in most cases
- NEW: More averaging options
  - There are now three averaging modes; "FIFO" (first-in, first-out) is the simple moving average, "Exponential" is the exponential decay (controlled by "Velocity" parameter on Average spectrum graph in dB/s instead of "Average Time"), and "Infinite" is the average of all frames (samples if IIR filter bank is used) that converges to a particular curve when analyzed for long enough
  - Three averaging domains; "Squared" is true RMS, "Linear" is simply average before log amplitude transform, and "Logarithmic" is the legacy one calculated after log amplitude transformation
- NEW: Piano display
  - Detected peaks can also be displayed on the piano keyboard display
  - Piano center frequency (alongside equal-temperament octave bands) at the closest note to certain frequency can be set via "Pitch Std." parameter in Hz
- NEW: Piano, octaves, and Bark scale critical band grids and note labels
- NEW: The Y-axis dB labels can be displayed on the right side and both sides
- NEW: Fonts and the size of the labels can now be changed
- NEW: Frequency range and dB range are now adjustable
  - When selecting "0Hz" on minimum frequency range while the spectrum frequency scale is logarithmic, the actual minimum range is the center frequency of the second FFT bin and in the case of octave bands, ~1Hz min range
- NEW: Linear amplitude scale
  - The amplitude scale can also be nth root while not in logarithmic (dB) amplitude scale, adjusted by "Nth root index" parameter
  - Minimum dB range is -Inf dB while in linear/nth root amplitude scale
- NEW: DC and Nyquist frequency markers
  - DC frequency marker is only visible if the selected frequency scale is anything other than logarithmic and octave bands
- NEW: An option to use color gradient (consistent with Loudness Peakmeter and built-in visualizations) rather than solid color for UI color integration
- NEW: Gaussian window function, comes with two of the same but with different parameters (2.4 and 3.4 respectively)
- IMPROVEMENT: Overall performance has been improved; it now utilizes AVX2 and even AVX512 instructions when your CPU support these instruction sets, especially the new IIR filter bank mode as well as other optimizations to "fix" performance on fullscreen mode
- IMPROVEMENT: Fullscreen mode and UI color integration for Columns UI panel version
- IMPROVEMENT: Average spectrum is no longer capped at 0dB
- IMPROVEMENT: Expanded and enhanced color gradient editing
  - Number of colorstops are no longer limited to six
  - Colorstop positions now can be changed individually
  - The colorstop position can also be set to be tied to certain dB values, which scales the color gradient accordingly to the current dB range
  - Graph color and even background color can be made reactive; brighter (or darker) parts of the resulting strip indicates higher amplitude at certain frequency
- IMPROVEMENT: Display options (asides color gradient) for graphs no longer reset during a UI color change while UI color integration is enabled
- FIX: Setting the different window function now actually works, e.g. setting it to NONE now applies a rectangular window instead

Just kidding, this post is just an April Fools joke and nothing more! So please don't take this post seriously and happy April Fools day! :))

Re: foo_enhanced_spectrum_analyzer

Reply #146
Even joke cant get lower frequencies in higher resolution at all.
Please remove my account from this forum.

Re: foo_enhanced_spectrum_analyzer

Reply #147
Even joke cant get lower frequencies in higher resolution at all.
Obviously, the Uncertainty Principle means that you can't have higher resolution on both time and frequency axis at the same time, not even IIR filter bank (though the time/frequency resolution varies on each frequency but it is always a tradeoff; on lower frequencies, it have precise frequency resolution but it will always have bad time resolution, and vice versa)

BTW, the filter bank design on my filter bank spectrum analyzer project (and even foo_vis_spectrum_analyzer) is not a Butterworth bandpass filter, instead it is just a stack of exact same biquad bandpass filters cascaded together numerous times, which according to this Desmos graph has wider transition band than typical octave band filter bank (possibly widest possible transition band) on higher orders and its frequency response is multiplied by itself (how many times the response is multiplied by itself depends on the filter order parameter)

Re: foo_enhanced_spectrum_analyzer

Reply #148
In my filter I have low frequencies displayed in high resolution just fine,  it have nothing to do with links you provided above.
Please remove my account from this forum.

Re: foo_enhanced_spectrum_analyzer

Reply #149
In my filter I have low frequencies displayed in high resolution just fine,  it have nothing to do with links you provided above.
Do you mean showcwt or something else? And as I said before, you can't have precise time resolution while having higher resolution on lower frequencies at the same time