Gstreamermm parsing question


I'm new to gstreamer; I'm developing a C++ game and I need to apply a
FFT to the microphone input in order to get the pitch. Previously I
was using Portaudio and a separate fft library, but now that I'm
trying to switch to GStreamer looks like the "spectrum" element could
do the job. I've managed to set up an example that creates a small
program that links a pulsesrc with a spectrum and the to pulsesink,
but I don't know how to parse the messages that spectrum sends.

In the spectrum reference [1], it says that the structure has an
attribute called "magnitudes", which is a "GstValueList of gfloat",
but I don't know how to parse it, because Gst::Structure [2] hasn't
got any appropiate get_field method. However, there's the method
called get_field_type, but I don't know what to do with the GType it

As a side question, would it be possible to get the raw stream for me
to manually parse it?



José Tomás Tocino García

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]