[Bug 748163] New: crop handling in gl plugins (gleffect, glimagesink, glshader, .....)

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Sun Apr 19 22:52:18 PDT 2015


https://bugzilla.gnome.org/show_bug.cgi?id=748163

            Bug ID: 748163
           Summary: crop handling in gl plugins (gleffect, glimagesink,
                    glshader, .....)
    Classification: Platform
           Product: GStreamer
           Version: 1.4.5
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: Normal
         Component: gst-plugins-bad
          Assignee: gstreamer-bugs at lists.freedesktop.org
          Reporter: lj.qfy.sh at gmail.com
        QA Contact: gstreamer-bugs at lists.freedesktop.org
     GNOME version: ---

Is there a plan to support video cropping in gl plugins? 
Although this can be done when you uploading the pixel data into texture, there
is still cases that you can use some extension to bind a buffer to the texture,
such as eglimage, dma-bufer or some private extensions. If decoder needs
padding or alignment when output video into this buffer, the gl plugins need to
handle it correctly.

I tried to support it, but have below question:

1. How to get the video buffer width and height?

I can get crop info from GstVideoCropMeta, but how can I get the buffer width
and height? We can get real video width/height from GstVideoInfo, but can't get
the buffer widht/height after padding/aligned. One way I found is like below
for I420 and NV12 video: 

videometa = gst_buffer_get_video_meta (buf);
bufw = videometa->stride[0];
bufh = videometa->offset[1] / bufw;

Is there a better way to get this info?

2. Supporting crop handling only need to recalculate the texture coordinate,
but I found every gl plugin has their own vertices definition, this means I
need to modify everywhere to support this.
Is there a plan to make it into a common module?

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list