Re: ANNOUNCE: gstreamermm-0.10.5



Hi, I have another question about gstreamermm. Trying to print the volume
of the given tracks:

  // List the tracks of the mixer.
  typedef std::list<Glib::RefPtr<Gst::MixerTrack> > tracks_type;
  tracks_type tracks = mixer->list_tracks();

  for (tracks_type::iterator iter = tracks.begin(); iter != tracks.end(); ++iter)
  {
    Glib::RefPtr<Gst::MixerTrack const>& track = *iter;
    std::cout << track->get_label() << ' ' << mixer->get_volume(track) << std::endl;
  }


This doesn't work... First I tried  get_volume(*iter)  but that can't find
a 'get_volume', because the only get_volume that is there demands a
Glib::RefPtr<Gst::MixerTrack const> (note the 'const').

So, I tried to convert *iter (which is a Glib::RefPtr<Gst::MixerTrack>)
to a Glib::RefPtr<Gst::MixerTrack const> in the line before, and indeed,
that fails.

How am I supposed to get the volume of the tracks now?

-- 
Carlo Wood <carlo alinoe com>


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