gstreamermm TagList



Hi,

     I’m a bit confused by the gstreamermm TagList class. A TagList seems to be a collection of key value pairs. Though there are a fixed set of tags it is still essentially a container. From a C++ perspective it is an odd one. It has an is_empty() method and a size() method but there obvious C++ way to iterate over the tags contained. There is no begin() or end() like an STL container would have. All the get methods assume you know the tag you want, even the get_value() one that takes an index.

 

I would expect to be able to do something like:

 

    Gst::TagList foo = <createme>;

    for(const auto& kv: foo)

   {

       const Tag tag = kv.tag;

       Glib::RefPtr<Glib::Value> value = kv.value;

   }

 

It looks like you can do:

 

         for(int i = 0 i != tagList->size();++i)

         {

             ???

             Profit();

         }

 

But how do you get the key and value given the index ?

 

Regards,

 

Bruce.



Kantar Disclaimer


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