glupload

glupload — A from video to GL flow filter

Synopsis

                    GstGLUpload;

Object Hierarchy

  GObject
   +----GstObject
         +----GstElement
               +----GstBaseTransform
                     +----GstGLUpload

Properties

  "external-opengl-context"  gulong                : Write

Description

upload video frames video frames into opengl textures.

Color space conversion

Depends on the driver and when needed, the color space conversion is made in a fragment shader using one frame buffer object instance, or using mesa ycbcr .


Examples

gst-launch -v videotestsrc ! "video/x-raw-rgb" ! glupload ! glimagesink
A pipeline to test hardware scaling. No special opengl extension is used in this pipeline, that's why it should work with OpenGL >= 1.1. That's the case if you are using the MESA3D driver v1.3.
gst-launch -v videotestsrc ! "video/x-raw-yuv, format=(fourcc)I420" ! glupload ! glimagesink
A pipeline to test hardware scaling and hardware colorspace conversion. When your driver supports GLSL (OpenGL Shading Language needs OpenGL >= 2.1), the 4 following format YUY2, UYVY, I420, YV12 and AYUV are converted to RGB32 through some fragment shaders and using one framebuffer (FBO extension OpenGL >= 1.4). If your driver does not support GLSL but supports MESA_YCbCr extension then the you can use YUY2 and UYVY. In this case the colorspace conversion is automatically made when loading the texture and therefore no framebuffer is used.
gst-launch -v videotestsrc ! "video/x-raw-rgb, width=320, height=240" ! glupload ! \
   "video/x-raw-gl, width=640, height=480" ! glimagesink
A pipeline to test hardware scaling. Frame buffer extension is required. Inded one FBO is used bettween glupload and glimagesink, because the texture needs to be resized.
gst-launch -v videotestsrc ! "video/x-raw-yuv, width=320, height=240" ! glupload ! \
   "video/x-raw-gl, width=640, height=480" ! glimagesink
A pipeline to test hardware scaling. Frame buffer extension is required. Inded one FBO is used bettween glupload and glimagesink, because the texture needs to be resized. Depends on your driver the color space conversion is made in a fragment shader using one frame buffer object instance, or using mesa ycbcr .

Synopsis

Element Information

plugin

opengl

author

Julien Isorce <julien.isorce@gmail.com>

class

Filter/Effect

Element Pads

name

sink

direction

sink

presence

always

details

video/x-raw-rgb, bpp=(int)24, depth=(int)24, endianness=(int)4321, red_mask=(int)16711680, green_mask=(int)65280, blue_mask=(int)255, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)24, endianness=(int)4321, red_mask=(int)-16777216, green_mask=(int)16711680, blue_mask=(int)65280, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)32, endianness=(int)4321, red_mask=(int)-16777216, green_mask=(int)16711680, blue_mask=(int)65280, alpha_mask=(int)255, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)24, depth=(int)24, endianness=(int)4321, red_mask=(int)255, green_mask=(int)65280, blue_mask=(int)16711680, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)24, endianness=(int)4321, red_mask=(int)65280, green_mask=(int)16711680, blue_mask=(int)-16777216, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)32, endianness=(int)4321, red_mask=(int)65280, green_mask=(int)16711680, blue_mask=(int)-16777216, alpha_mask=(int)255, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)24, endianness=(int)4321, red_mask=(int)16711680, green_mask=(int)65280, blue_mask=(int)255, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)24, endianness=(int)4321, red_mask=(int)255, green_mask=(int)65280, blue_mask=(int)16711680, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)32, endianness=(int)4321, red_mask=(int)16711680, green_mask=(int)65280, blue_mask=(int)255, alpha_mask=(int)-16777216, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-rgb, bpp=(int)32, depth=(int)32, endianness=(int)4321, red_mask=(int)255, green_mask=(int)65280, blue_mask=(int)16711680, alpha_mask=(int)-16777216, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

video/x-raw-yuv, format=(fourcc){ I420, YV12, YUY2, UYVY, AYUV }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

name

src

direction

source

presence

always

details

video/x-raw-gl, width=(int)[ 1, 8000 ], height=(int)[ 1, 6000 ], pixel-aspect-ratio=(fraction)1/1, framerate=(fraction)[ 0/1, 100/1 ]

Details

GstGLUpload

typedef struct _GstGLUpload GstGLUpload;

Property Details

The "external-opengl-context" property

  "external-opengl-context"  gulong                : Write

Give an external OpenGL context with which to share textures.