Easy resonant lp filter?
@ddw_music here https://github.com/pure-data/pure-data/tree/master/extra/bob~ miller refers to the "cutoff frequency" which would be an odd term to use for a bandpass filter.. if you look at bob~ without any resonance it definitely behaves like a a lowpass.. I think that as the resonance goes up the pass-band might get attenuated? most discussions of the moog ladder filter refer to the lowpass filter (rather than the High-pass one) and since this certainly is not a high-pass filter I would say that in all likelihood it's an emulation of the lowpass species.
If you want to go for instructional clarity I agree that maybe other filters look more like "lowpass" filters in spectrograms tho (but bob~ still sounds like a lowpass to me imho)
Easy resonant lp filter?
This screenshot of a spectrogram recorded by alternating bob~ with a biquad low pass filter shows:
- bob~ attenuates both low and high frequencies somewhat.
- The biquad attenuates high frequencies significantly, but not low (the stronger band in the middle is resonance from Q).
bob~ doesn't sound to me like low pass, nor does its observed frequency response look like low pass.
hjh
Ofelia rendered Spectrogram?
Hi @Kitty Dyson. I tried to port a spectrogram shader to ofelia. Just updated it for Ofelia v3. You need to change it a bit for your desired result.
You can download it here (it is the sonogram patch): https://forum.pdpatchrepo.info/topic/12168/3-shader-adaptions-sonogram-vectorscope-and-conway
But I am sure you can implement a spectrogram without shaders too.
3 shader adaptions: sonogram / vectorscope and conway
in tried to implement three shaders that could be useful with pure data.
the shaders are not my work, but i had to adapt and to learn a lot to make them work with pure data.
would be nice to improve them further.
i put the links from the shaders as comments into the frag. files.
ofelia_conway_sonogram_vectorscope.zip
the spectrogram works quite well, but i do not know if i implemented the best fft algorithm for that case / and in the right way...).
the vectorscope is quite gpu expensive. from the comment:
"GLSL is the absolutely worst medium for rendering this,
but Shadertoy seemed like a good place to find people who
might have ideas about this.
On the left is a return diagram. It is an X-Y plot of a
function against itself at a constant offset. The offset is
a tunable parameter. If it is set to one fourth of the
period of a certain frequency, then waves at that frequency
will cause the diagram to draw circles. Other frequencies
will cause some kind of ellipses.
On the right is a phase space diagram of the signal. It is
an X-Y plot of the signal against its differential. The
scaling factor applied to the differential is a sort of
tunable paramater too, which again allows you to choose one
frequency to form perfect circles.
These both draw kind of neat patterns, but not really neat
enough to work as visualization. How could this be improved?
(You'd probably have to do it in something other than a single
shader, though, to be able to draw more points, or lines.
Having access to more of the signal might also be a good thing.)"
The conway shader works good, but i do not understand it enough to change the rules or even the size of the cells...
unexpected spectrogram?
@leech If you reduce the dynamic range of the spectrogram, or increase the resolution, or both, you can get it to show a line at 80Hz.
40dB and about 16384 bins should give you a red line with standard colours.
Although a sine wave has a constant frequency the rate of change of amplitude varies over the cycle.
Windowing functions are used with FFTs. These transform the signal block-by-block into a spectral representation whose resolution (accuracy) in both the frequency and time domains are proportional to their size.
Unless the window "width" ...... time....... matches the width of a cycle or cycles of the sine wave you will get spectral leakage.
http://download.ni.com/evaluation/pxi/Understanding FFTs and Windowing.pdf
David.
unexpected spectrogram?
Hey guys, I just tried to record a simple osc~ 80 Hz in a wav file.
When I open the file in sonic visualiser to get the spectrogram I wasn't expecting it to be like this but to clearly show a red line at 80Hz and nothing else..? What am I missing? Spectrogram attached.
Thanks
Analyzing & Synthesizing a Cowbell
In Sonic Visualizer, there's a spectrogram option called 'Bins' that, when I set it to 'Frequencies', seems to show precise frequencies like SPEAR, but with a higher resolution/more info. I'll try using that for a new analysis and see if it helps...
I guess I should read through the SV documentation at some point.
Hearing Loss Simulation
@Azoso Hello and welcome to the forum.
It can all be done of course.
I would recommend starting with an installation of Pd extended if possible, rather than Vanilla, as at least one of the tools that you need (spectrum analyser) is then immediately available in the download.
If you are using a recent 64-bit mac os then that will not be possible, and things get more complicated.
You will then need to use "help" "find externals" from the Menu of Pd and download all the externals.
You can always switch to Vanilla later when you know more about the workings of Pd "under the hood".
The spectrum analyser (probably the most difficult part of your project) can then be created instantly by placing an object [spectrogram~-help] in your patch. Then right-click it to open it.
You can see it working by connecting an [adc~] to the [spectrogram~] object instead of the [noise~] object...... and you will be inspired to continue.
Then change [spectrogram~-help] to [spectrogram~] so as to use it in your patch.
Come back when you get stuck!
David.
generate audio from image as spectogram
I misread the question. Forget the part about the histogram and just fit the spectrogram in a [rifft~] window.
Phaser / Chorus / Flanger
@Pierre-Guillot super thanks
btw is the spectrogram object available in pd, or is it pd-extended stuff or a plugin... ?