Frame By Frame Tags

Brian Panneton brian.panneton at gmail.com
Tue Jun 14 19:44:10 UTC 2016


Hello,

I currently am stepping frame by frame in PAUSED mode with the following
python code and pulling out each frame:

self.elements['innersink'].send_event(Gst.Event.new_step(Gst.Format.BUFFERS,
1, 1, True, False))
        self.inner_sample = self.elements['innersink'].emit('pull-preroll')
        self.inner_buffer = self.inner_sample.get_buffer()

I am struggling to get tags out without being in PLAYING mode. Is there any
way to get the Tags out while in PAUSED mode? From what I can tell, the
only way to get the streaming tags is to listen for them on the bus similar
to how one would listen for the EOS. I attempted this as I stepped through,
but I couldn't seem to get anything.

While in paused mode I do something like this to get some tags off the
beginning:

        while(True):
            msg =
self.pipeline_front.get_bus().pop_filtered(Gst.MessageType.TAG |
Gst.MessageType.ERROR | Gst.MessageType.ASYNC_DONE)
            print "TAG TYPE", msg, type(msg), msg.type
            if msg.type != Gst.MessageType.TAG:
                print 'Done:', msg.type
                break
            tags = msg.parse_tag()
            print tags.to_string()
            for tag in range(tags.n_tags()):
                name = tags.nth_tag_name(tag)
                print tag, name, tags.get_string(name)


It seems to work, but I only get a few tags like the following. I assume
these are metadata tags.

taglist, video-codec=(string)H264;
taglist, container-format=(string)Matroska;
taglist, video-codec=(string)H.264;

When I run 'strings <file>' command on the file I find these, so I know
there are more tags.
matroska
GStreamer plugin version 1.2.4
GStreamer Matroska muxer
Video
V_MPEG4/ISO/AVC

The one I'm trying to pull out is the encoder tag (encoder=GStreamer plugin
version 1.2.4) but I can't for the life of me find it. Any help would be
appreciated!

Thanks,
Brian Panneton
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20160614/5f8e4f3e/attachment.html>


More information about the gstreamer-devel mailing list