how to get the pat info from the tsdemux

trinadh Pala me_wavelet at yahoo.co.uk
Wed Jun 26 14:21:40 PDT 2013



Just repeating the message, hoping to get some help.


Hello all,

I am working on transport stream analyzer using QtGstreamer Library.

I have implemented a pipeline with "tsdemux" for decoding transport stream.

The application is able to capture syncrhonous message structure with "pat" name

Trying to extract the info in the "pat". How to parse the info from this property. The examples given on QtGstreamer freedesktop does not suggest any method to parsing this pat structure.  The pat info is in the Message QGst::Structure. I can retrieve only the top level name and programs fields. But do not know how to reference the pid value and program numbers inside the fields. It is a list but there is no list construct mentioned in QtGstreamer classes. Tried using QGst::Value , not successful. All the information on the internet points to some list of Value elements,
 but could not find any in the QGst library. 

I have tried using QGst::ProbeProperty but that did not help either. it could not find the pat or pat-info property in tsdemux

 if (QString(message->internalStructure()->name())==QString("pat"))
    {
        qDebug() << "pat table values";

        qDebug() << message->typeName();

        qDebug() << message->internalStructure()->toString();

       
 QGst::StructurePtr xyz;
        xyz= message->internalStructure();
        qDebug() << xyz->value("transport-stream-id").toInt(); // works ok

        qDebug() << xyz->value("programs"); // works ok


        qDebug() <<"number of fields" << xyz->numberOfFields(); // works ok

        for (int i=1;i <= xyz->numberOfFields();i++)
        {
            QString fieldname=xyz->fieldName(i);            // works o.k
            qDebug() <<
 fieldname;
         //   QGlib::Type fieldtype=xyz->fieldType("programs").;    // not able to understand how to get the program numbers and pids based on these fields?
          //  qDebug() << fieldtype;                                                    // or how to use the field type to get the elements. 

         //   QList<QGlib::Value> prg=xyz->value("programs");

        }

output of this program shown below. Could not understand how to map this GstValueList in QtGstreamer wrappers. Or is there a easy way to get the pat info. 

 
"element" 
"pat, transport-stream-id=(uint)5, programs=(structure){ "program-4\,\ program-number\=\(uint\)4\,\ pid\=\(uint\)32\;", "program-0\,\ program-number\=\(uint\)0\,\ pid\=\(uint\)16\;" };" 
5 
QGlib::Value("GstValueList", "{ program-4, program-number=(uint)4, pid=(uint)32;, program-0, program-number=(uint)0, pid=(uint)16; }") 
number of fields 2 
"programs" 
"" 

Please help.

Thanks and regards
Trinadh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20130626/d6fc3095/attachment.html>


More information about the gstreamer-devel mailing list