iTunes Visualizer Plugin in C# - Energy Function
Posted
by James D
on Stack Overflow
See other posts from Stack Overflow
or by James D
Published on 2010-03-14T16:08:45Z
Indexed on
2010/03/14
16:15 UTC
Read the original article
Hit count: 467
Hi,
iTunes Visualizer plugin in C#.
Easiest way to compute the "energy level" for a particular sample?
I looked at this writeup on beat detection over at GameDev and have had some success with it (I'm not doing beat detection per se, but it's relevant). But ultimately I'm looking for a stupid-as-possible, quick-and-dirty approach for demo purposes.
For those who aren't familiar with how iTunes structures visualization data, basically you're given this:
struct VisualPluginData
{
/* SNIP */
RenderVisualData renderData;
UInt32 renderTimeStampID;
UInt8 minLevel[kVisualMaxDataChannels]; // 0-128
UInt8 maxLevel[kVisualMaxDataChannels]; // 0-128
};
struct RenderVisualData
{
UInt8 numWaveformChannels;
UInt8 waveformData[kVisualMaxDataChannels][kVisualNumWaveformEntries];
// 512-point FFT
UInt8 numSpectrumChannels;
UInt8 spectrumData[kVisualMaxDataChannels][kVisualNumSpectrumEntries];
};
Ideally, I'd like an approach that a beginning programmer with little to no DSP experience could grasp and improve on. Any ideas?
Thanks!
© Stack Overflow or respective owner