jpegenc a theora playbin2 buffer?

Erik Blankinship jedierikb at gmail.com
Mon Sep 19 18:06:08 PDT 2011


>
>
> > I am continuing to have trouble with this.  Most every combination I
> > try ends up with a distorted image.
>
> Distorted in what way? Too narrow/wide? Or every line shifted a bit to
> the left/right of the previous line?
>

Here is the original video:
http://alumni.media.mit.edu/~erikb/tmp/city.ogv

Here is the code I use to extract a pixbuf:

        caps = last_frame.get_caps( )[0]
        width = int(caps["width"])
        height = int(caps["height"])
        r4 = width * 3
        r4 = (r4 + 3) & ~ 3
        pixBuf = gtk.gdk.pixbuf_new_from_data( last_frame.data,
gtk.gdk.COLORSPACE_RGB, False, 8, width, height, r4 )

and here are the results with rowstride set to width * 2:
http://alumni.media.mit.edu/~erikb/tmp/city_width_x2.png

and with width * 3:
http://alumni.media.mit.edu/~erikb/tmp/city_width_x3.png

and with width * 4:
http://alumni.media.mit.edu/~erikb/tmp/city_width_x4.png

Hopefully some can suggest what the rowstride should be based on these
images, or suggest how I would determine what it should be?


> (Though it seems to me that just asking for an image/jpeg in the desired
> width or height via the convert-frame action signal would be the easiest
> way to achieve your goal)
>
>
Yes, this might be a good idea if I can't get the approach I am exploring
above to work.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20110919/7b9d68a5/attachment-0001.htm>


More information about the gstreamer-devel mailing list