void mxf_up_init (void) { mxf_essence_element_handler_register (&mxf_up_essence_element_handler); mxf_up_essence_element_writer.pad_template = gst_pad_template_new ("up_video_sink_%u", GST_PAD_SINK, GST_PAD_REQUEST, gst_caps_from_string (GST_VIDEO_CAPS_RGB "; " GST_VIDEO_CAPS_BGR "; " GST_VIDEO_CAPS_RGBx "; " GST_VIDEO_CAPS_xRGB "; " GST_VIDEO_CAPS_BGRx "; " GST_VIDEO_CAPS_xBGR "; " GST_VIDEO_CAPS_ARGB "; " GST_VIDEO_CAPS_RGBA "; " GST_VIDEO_CAPS_ABGR "; " GST_VIDEO_CAPS_BGRA "; " GST_VIDEO_CAPS_YUV ("AYUV") "; " GST_VIDEO_CAPS_YUV ("v308") "; " GST_VIDEO_CAPS_YUV ("UYVY") "; " GST_VIDEO_CAPS_YUV ("YUY2"))); memcpy (&mxf_up_essence_element_writer.data_definition, mxf_metadata_track_identifier_get (MXF_METADATA_TRACK_PICTURE_ESSENCE), 16); mxf_essence_element_writer_register (&mxf_up_essence_element_writer); }
GstCaps * gst_frei0r_caps_from_color_model (gint color_model) { switch (color_model) { case F0R_COLOR_MODEL_BGRA8888: return gst_caps_from_string (GST_VIDEO_CAPS_BGRA); case F0R_COLOR_MODEL_RGBA8888: return gst_caps_from_string (GST_VIDEO_CAPS_RGBA); case F0R_COLOR_MODEL_PACKED32: return gst_caps_from_string (GST_VIDEO_CAPS_BGRA " ; " GST_VIDEO_CAPS_RGBA " ; " GST_VIDEO_CAPS_ABGR " ; " GST_VIDEO_CAPS_ARGB " ; " GST_VIDEO_CAPS_BGRx " ; " GST_VIDEO_CAPS_RGBx " ; " GST_VIDEO_CAPS_xBGR " ; " GST_VIDEO_CAPS_xRGB " ; " GST_VIDEO_CAPS_YUV ("AYUV")); default: break; } return NULL; }
{GST_DEINTERLACE2_LAYOUT_BFF, "Bottom field first", "bff"}, {0, NULL, NULL}, }; if (!deinterlace2_field_layout_type) { deinterlace2_field_layout_type = g_enum_register_static ("GstDeinterlace2FieldLayout", field_layout_types); } return deinterlace2_field_layout_type; } static GstStaticPadTemplate src_templ = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("YUY2")) ); static GstStaticPadTemplate sink_templ = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("YUY2")) ); static void gst_deinterlace2_finalize (GObject * self); static void gst_deinterlace2_set_property (GObject * self, guint prop_id, const GValue * value, GParamSpec * pspec); static void gst_deinterlace2_get_property (GObject * self, guint prop_id, GValue * value, GParamSpec * pspec); static GstCaps *gst_deinterlace2_getcaps (GstPad * pad);
#ifdef HAVE_CONFIG_H #include "config.h" #endif #include <string.h> #include "gstsmpte.h" #include <gst/video/video.h> #include "paint.h" GST_DEBUG_CATEGORY_STATIC (gst_smpte_debug); #define GST_CAT_DEFAULT gst_smpte_debug static GstStaticPadTemplate gst_smpte_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("I420") ) ); static GstStaticPadTemplate gst_smpte_sink1_template = GST_STATIC_PAD_TEMPLATE ("sink1", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("I420") ) ); static GstStaticPadTemplate gst_smpte_sink2_template = GST_STATIC_PAD_TEMPLATE ("sink2", GST_PAD_SINK, GST_PAD_ALWAYS,
GST_DEBUG_CATEGORY_STATIC (gst_jasper_enc_debug); #define GST_CAT_DEFAULT gst_jasper_enc_debug enum { ARG_0, }; static GstStaticPadTemplate gst_jasper_enc_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_RGB "; " GST_VIDEO_CAPS_BGR "; " GST_VIDEO_CAPS_RGBx "; " GST_VIDEO_CAPS_xRGB "; " GST_VIDEO_CAPS_BGRx "; " GST_VIDEO_CAPS_xBGR "; " GST_VIDEO_CAPS_YUV ("{ I420, YV12, v308 }")) ); static GstStaticPadTemplate gst_jasper_enc_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS ("image/x-j2c, width = " GST_VIDEO_SIZE_RANGE ", height = " GST_VIDEO_SIZE_RANGE ", fourcc = (GstFourcc) { sRGB, sYUV }," "framerate = " GST_VIDEO_FPS_RANGE ", " "fields = (int) 1; " "image/x-jpc, width = " GST_VIDEO_SIZE_RANGE ", height = " GST_VIDEO_SIZE_RANGE ", fourcc = (GstFourcc) { sRGB, sYUV }," "framerate = " GST_VIDEO_FPS_RANGE ", " "fields = (int) 1; " "image/jp2") );
GSTOMX_BOILERPLATE (GstOmxJpegEnc, gst_omx_jpegenc, GstOmxBaseFilter, GST_OMX_BASE_FILTER_TYPE); static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS ("image/jpeg, " "width = (int)[16,4096], " "height = (int)[16,4096], " "framerate = (fraction)[0/1,max];") ); static GstStaticPadTemplate sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ( GSTOMX_ALL_FORMATS)) ); static void type_base_init (gpointer g_class) { GstElementClass *element_class; element_class = GST_ELEMENT_CLASS (g_class); { GstElementDetails details; details.longname = "OpenMAX IL JPEG image encoder"; details.klass = "Codec/Encoder/Image"; details.description = "Encodes image in JPEG format with OpenMAX IL";
#define BLACK 0x80008000 #define GRAY 0x80808080 #define GREEN 0x00800080 #define BG_COLOR BLACK GSTOMX_BOILERPLATE (GstOmxVideoMixerVodalys, gst_omx_videomixer_vodalys, GstOmxBaseFilter21, GST_OMX_BASE_FILTER21_TYPE); static GstStaticPadTemplate sink_template_camera = GST_STATIC_PAD_TEMPLATE ("sink_00", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ( "{YUY2}" )) ); static GstStaticPadTemplate sink_template_slide = GST_STATIC_PAD_TEMPLATE ("sink_01", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ( "{YUY2}" )) ); static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ( "{YUY2}" )) );
#define DEFAULT_DEVICE_INDEX -1 #define DEFAULT_DO_STATS FALSE #define QUEUE_READY_LOCK(instance) GST_OBJECT_LOCK (instance) #define QUEUE_READY_UNLOCK(instance) GST_OBJECT_UNLOCK (instance) #define QUEUE_READY_WAIT(instance) \ g_cond_wait (instance->ready_cond, GST_OBJECT_GET_LOCK (instance)) #define QUEUE_READY_NOTIFY(instance) g_cond_signal (instance->ready_cond) GST_DEBUG_CATEGORY (gst_cel_video_src_debug); #define GST_CAT_DEFAULT gst_cel_video_src_debug static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("NV12") ";" GST_VIDEO_CAPS_YUV ("YUY2")) ); enum { PROP_0, PROP_DEVICE_INDEX, PROP_DO_STATS, PROP_FPS }; typedef struct { guint index;
{ PROP_0, PROP_METHOD, PROP_ADD_BORDERS /* FILL ME */ }; #undef GST_VIDEO_SIZE_RANGE #define GST_VIDEO_SIZE_RANGE "(int) [ 1, 32767]" static GstStaticCaps gst_video_scale_format_caps[] = { GST_STATIC_CAPS (GST_VIDEO_CAPS_RGBA), GST_STATIC_CAPS (GST_VIDEO_CAPS_ARGB), GST_STATIC_CAPS (GST_VIDEO_CAPS_BGRA), GST_STATIC_CAPS (GST_VIDEO_CAPS_ABGR), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("AYUV")), GST_STATIC_CAPS (GST_VIDEO_CAPS_RGBx), GST_STATIC_CAPS (GST_VIDEO_CAPS_xRGB), GST_STATIC_CAPS (GST_VIDEO_CAPS_BGRx), GST_STATIC_CAPS (GST_VIDEO_CAPS_xBGR), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("Y444")), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("v308")), GST_STATIC_CAPS (GST_VIDEO_CAPS_RGB), GST_STATIC_CAPS (GST_VIDEO_CAPS_BGR), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("Y42B")), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("YUY2")), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("YVYU")), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("UYVY")), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("I420")), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("YV12")), GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("Y41B")),
GST_STATIC_CAPS ( GST_VIDEO_CAPS_xRGB_HOST_ENDIAN)); static GstStaticPadTemplate s_rgbPadTemplate = GST_STATIC_PAD_TEMPLATE("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS( GST_VIDEO_CAPS_xRGB_HOST_ENDIAN)); static GstStaticPadTemplate s_yuvPadTemplate = GST_STATIC_PAD_TEMPLATE("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS( GST_VIDEO_CAPS_YUV ("{ IYUV, I420, YV12 }"))); G_DEFINE_TYPE(PGstVideoSink, p_gst_video_sink, GST_TYPE_VIDEO_SINK) static void p_gst_video_sink_init(PGstVideoSink *sink) { } GstCaps *p_gst_video_sink_get_static_caps() { return gst_static_pad_template_get_caps(&s_rgbPadTemplate); } static GstCaps *p_gst_video_sink_get_caps(GstBaseSink *baseSink) {
PROP_QUANT = PROP_MAX }; #define DEFAULT_QUANT -1 /* hashtable, key = gtype, value = filterdetails index */ static GHashTable *global_plugins; /* TODO : add support for the other format supported by libpostproc */ static GstStaticPadTemplate gst_post_proc_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ IYUV, I420, YV12, Y42B, Y41B }")) ); static GstStaticPadTemplate gst_post_proc_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ IYUV, I420, YV12, Y42B, Y41B }")) ); GST_DEBUG_CATEGORY (postproc_debug); #define GST_CAT_DEFAULT postproc_debug static void gst_post_proc_class_init (GstPostProcClass * klass); static void gst_post_proc_base_init (GstPostProcClass * klass); static void gst_post_proc_init (GstPostProc * pproc);
#include <gst/controller/gstcontroller.h> #include <string.h> GST_DEBUG_CATEGORY (frei0r_debug); #define GST_CAT_DEFAULT frei0r_debug static GstStaticCaps bgra8888_caps = GST_STATIC_CAPS (GST_VIDEO_CAPS_BGRA); static GstStaticCaps rgba8888_caps = GST_STATIC_CAPS (GST_VIDEO_CAPS_RGBA); static GstStaticCaps packed32_caps = GST_STATIC_CAPS (GST_VIDEO_CAPS_BGRA " ; " GST_VIDEO_CAPS_RGBA " ; " GST_VIDEO_CAPS_ABGR " ; " GST_VIDEO_CAPS_ARGB " ; " GST_VIDEO_CAPS_BGRx " ; " GST_VIDEO_CAPS_RGBx " ; " GST_VIDEO_CAPS_xBGR " ; " GST_VIDEO_CAPS_xRGB " ; " GST_VIDEO_CAPS_YUV ("AYUV")); GstCaps * gst_frei0r_caps_from_color_model (gint color_model) { switch (color_model) { case F0R_COLOR_MODEL_BGRA8888: return gst_static_caps_get (&bgra8888_caps); case F0R_COLOR_MODEL_RGBA8888: return gst_static_caps_get (&rgba8888_caps); case F0R_COLOR_MODEL_PACKED32: return gst_static_caps_get (&packed32_caps); default: break; }
}; /* pad templates */ static GstStaticPadTemplate gst_y4m_dec_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS ("application/x-yuv4mpeg, y4mversion=2") ); static GstStaticPadTemplate gst_y4m_dec_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{I420,Y42B,Y444}")) ); /* class initialization */ GST_BOILERPLATE (GstY4mDec, gst_y4m_dec, GstElement, GST_TYPE_ELEMENT); static void gst_y4m_dec_base_init (gpointer g_class) { GstElementClass *element_class = GST_ELEMENT_CLASS (g_class); gst_element_class_add_static_pad_template (element_class, &gst_y4m_dec_src_template); gst_element_class_add_static_pad_template (element_class, &gst_y4m_dec_sink_template);
{0, NULL, NULL} }; if (!interlace_pattern_type) { interlace_pattern_type = g_enum_register_static ("GstInterlacePattern", pattern_types); } return interlace_pattern_type; } static GstStaticPadTemplate gst_interlace_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{AYUV,YUY2,UYVY,I420,YV12,Y42B,Y444,NV12,NV21}") ",interlaced=TRUE") ); static GstStaticPadTemplate gst_interlace_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{AYUV,YUY2,UYVY,I420,YV12,Y42B,Y444,NV12,NV21}") ",interlaced=FALSE") ); static void gst_interlace_base_init (gpointer g_class); static void gst_interlace_class_init (GstInterlaceClass * klass); static void gst_interlace_init (GstInterlace * interlace);
#ifdef HAVE_ECORE_X # include <Ecore_X.h> # include <Ecore_Evas.h> # ifdef HAVE_XOVERLAY_H # include <gst/interfaces/xoverlay.h> # endif #endif #include "Emotion.h" #include "emotion_private.h" #include "emotion_gstreamer.h" static GstStaticPadTemplate sinktemplate = GST_STATIC_PAD_TEMPLATE("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS(GST_VIDEO_CAPS_YUV("{ I420, YV12, YUY2, NV12, ST12, TM12 }") ";" GST_VIDEO_CAPS_BGRx ";" GST_VIDEO_CAPS_BGR ";" GST_VIDEO_CAPS_BGRA)); GST_DEBUG_CATEGORY_STATIC(evas_video_sink_debug); #define GST_CAT_DEFAULT evas_video_sink_debug enum { REPAINT_REQUESTED, LAST_SIGNAL }; enum { PROP_0, PROP_EVAS_OBJECT, PROP_WIDTH, PROP_HEIGHT,
#define FRAME_QUEUE_LOCK(instance) g_mutex_lock (instance->qlock) #define FRAME_QUEUE_UNLOCK(instance) g_mutex_unlock (instance->qlock) #define FRAME_QUEUE_WAIT(instance) \ g_cond_wait (instance->qcond, instance->qlock) #define FRAME_QUEUE_NOTIFY(instance) g_cond_signal (instance->qcond) #define GST_MIO_REQUIRED_APIS \ (GST_API_CORE_VIDEO | GST_API_CORE_MEDIA | GST_API_MIO) GST_DEBUG_CATEGORY (gst_mio_video_src_debug); #define GST_CAT_DEFAULT gst_mio_video_src_debug static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("UYVY") ";" GST_VIDEO_CAPS_YUV ("YUY2") ";" "image/jpeg, " "width = " GST_VIDEO_SIZE_RANGE ", " "height = " GST_VIDEO_SIZE_RANGE ", " "framerate = " GST_VIDEO_FPS_RANGE ";") ); enum { PROP_0, PROP_DEVICE_UID, PROP_DEVICE_NAME, PROP_DEVICE_INDEX };
GST_DEBUG_CATEGORY_EXTERN (mxf_debug); #define GST_CAT_DEFAULT mxf_debug static const struct { const gchar *caps; guint32 n_pixel_layout; guint8 pixel_layout[10]; guint32 fourcc; } _rgba_mapping_table[] = { { GST_VIDEO_CAPS_RGB, 3, { 'R', 8, 'G', 8, 'B', 8}, GST_MAKE_FOURCC ('R', 'G', 'B', ' ')}, { GST_VIDEO_CAPS_BGR, 3, { 'B', 8, 'G', 8, 'R', 8}, GST_MAKE_FOURCC ('B', 'G', 'R', ' ')}, { GST_VIDEO_CAPS_YUV ("v308"), 3, { 'Y', 8, 'U', 8, 'V', 8}, GST_MAKE_FOURCC ('v', '3', '0', '8')}, { GST_VIDEO_CAPS_xRGB, 4, { 'F', 8, 'R', 8, 'G', 8, 'B', 8}, GST_MAKE_FOURCC ('x', 'R', 'G', 'B')}, { GST_VIDEO_CAPS_RGBx, 4, { 'R', 8, 'G', 8, 'B', 8, 'F', 8}, GST_MAKE_FOURCC ('R', 'G', 'B', 'x')}, { GST_VIDEO_CAPS_xBGR, 4, { 'F', 8, 'B', 8, 'G', 8, 'R', 8}, GST_MAKE_FOURCC ('x', 'B', 'G', 'R')}, { GST_VIDEO_CAPS_BGRx, 4, { 'B', 8, 'G', 8, 'R', 8, 'F', 8}, GST_MAKE_FOURCC ('B', 'G', 'R', 'x')}, { GST_VIDEO_CAPS_RGBA, 4, { 'R', 8, 'G', 8, 'B', 8, 'A', 8}, GST_MAKE_FOURCC ('R', 'G', 'B', 'A')}, { GST_VIDEO_CAPS_ARGB, 4, { 'A', 8, 'R', 8, 'G', 8, 'B', 8}, GST_MAKE_FOURCC ('A', 'R', 'G', 'B')}, { GST_VIDEO_CAPS_BGRA, 4, { 'B', 8, 'G', 8, 'R', 8, 'A', 8}, GST_MAKE_FOURCC ('B', 'G', 'R', 'A')}, {
#include "gsteglglessink.h" GST_DEBUG_CATEGORY_STATIC (gst_eglglessink_debug); #define GST_CAT_DEFAULT gst_eglglessink_debug /* Input capabilities. */ static GstStaticPadTemplate gst_eglglessink_sink_template_factory = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_RGBA ";" GST_VIDEO_CAPS_BGRA ";" GST_VIDEO_CAPS_ARGB ";" GST_VIDEO_CAPS_ABGR ";" GST_VIDEO_CAPS_RGBx ";" GST_VIDEO_CAPS_BGRx ";" GST_VIDEO_CAPS_xRGB ";" GST_VIDEO_CAPS_xBGR ";" GST_VIDEO_CAPS_YUV ("{ AYUV, Y444, I420, YV12, NV12, NV21, YUY2, YVYU, UYVY, Y42B, Y41B }") ";" GST_VIDEO_CAPS_RGB ";" GST_VIDEO_CAPS_BGR ";" GST_VIDEO_CAPS_RGB_16)); /* Filter signals and args */ enum { /* FILL ME */ LAST_SIGNAL }; enum { PROP_0, PROP_CREATE_WINDOW, PROP_FORCE_ASPECT_RATIO,
/* FILL ME */ }; #define DEFAULT_PROP_GAMMA 1 static const GstElementDetails gamma_details = GST_ELEMENT_DETAILS ("Video gamma correction", "Filter/Effect/Video", "Adjusts gamma on a video stream", "Arwed v. Merkatz <*****@*****.**"); static GstStaticPadTemplate gst_gamma_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ IYUV, I420, YV12 }")) ); static GstStaticPadTemplate gst_gamma_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ IYUV, I420, YV12 }")) ); static void gst_gamma_set_property (GObject * object, guint prop_id, const GValue * value, GParamSpec * pspec); static void gst_gamma_get_property (GObject * object, guint prop_id, GValue * value, GParamSpec * pspec); static gboolean gst_gamma_set_caps (GstBaseTransform * base, GstCaps * incaps,
(GInstanceInitFunc) gst_jpegenc_init, }; jpegenc_type = g_type_register_static (GST_TYPE_ELEMENT, "GstJpegEnc", &jpegenc_info, 0); } return jpegenc_type; } /* *INDENT-OFF* */ static GstStaticPadTemplate gst_jpegenc_sink_pad_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ I420, YV12, YUY2, UYVY, Y41B, Y42B, YVYU, Y444 }") "; " GST_VIDEO_CAPS_RGB "; " GST_VIDEO_CAPS_BGR "; " GST_VIDEO_CAPS_RGBx "; " GST_VIDEO_CAPS_xRGB "; " GST_VIDEO_CAPS_BGRx "; " GST_VIDEO_CAPS_xBGR "; " GST_VIDEO_CAPS_GRAY8) ); /* *INDENT-ON* */ static GstStaticPadTemplate gst_jpegenc_src_pad_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS ("image/jpeg, " "width = (int) [ 16, 65535 ], " "height = (int) [ 16, 65535 ], " "framerate = (fraction) [ 0/1, MAX ]") );
GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS ("video/x-xvid, " "width = (int) [ 0, MAX ], " "height = (int) [ 0, MAX ], " "framerate = (fraction) [ 0/1, MAX ]; " "video/mpeg, " "mpegversion = (int) 4, " "systemstream = (boolean) FALSE, " "width = (int) [ 0, MAX ], " "height = (int) [ 0, MAX ], " "framerate = (fraction) [ 0/1, MAX ]") ); static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ I420, YUY2, YV12, YVYU, UYVY }") "; " RGB_24_32_STATIC_CAPS (32, 0x00ff0000, 0x0000ff00, 0x000000ff) "; " RGB_24_32_STATIC_CAPS (32, 0xff000000, 0x00ff0000, 0x0000ff00) "; " RGB_24_32_STATIC_CAPS (32, 0x0000ff00, 0x00ff0000, 0xff000000) "; " RGB_24_32_STATIC_CAPS (32, 0x000000ff, 0x0000ff00, 0x00ff0000) "; " RGB_24_32_STATIC_CAPS (24, 0x0000ff, 0x00ff00, 0xff0000) "; " GST_VIDEO_CAPS_RGB_15 "; " GST_VIDEO_CAPS_RGB_16) ); GST_DEBUG_CATEGORY_STATIC (xviddec_debug); #define GST_CAT_DEFAULT xviddec_debug static void gst_xviddec_base_init (GstXvidDecClass * klass); static void gst_xviddec_class_init (GstXvidDecClass * klass); static void gst_xviddec_init (GstXvidDec * dec); static void gst_xviddec_reset (GstXvidDec * dec);
#define DEFAULT_PROP_SATURATION 1.0 enum { PROP_0, PROP_CONTRAST, PROP_BRIGHTNESS, PROP_HUE, PROP_SATURATION }; static GstStaticPadTemplate gst_video_balance_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("AYUV") ";" GST_VIDEO_CAPS_ARGB ";" GST_VIDEO_CAPS_BGRA ";" GST_VIDEO_CAPS_ABGR ";" GST_VIDEO_CAPS_RGBA ";" GST_VIDEO_CAPS_YUV ("Y444") ";" GST_VIDEO_CAPS_xRGB ";" GST_VIDEO_CAPS_RGBx ";" GST_VIDEO_CAPS_xBGR ";" GST_VIDEO_CAPS_BGRx ";" GST_VIDEO_CAPS_RGB ";" GST_VIDEO_CAPS_BGR ";" GST_VIDEO_CAPS_YUV ("Y42B") ";" GST_VIDEO_CAPS_YUV ("YUY2") ";" GST_VIDEO_CAPS_YUV ("UYVY") ";" GST_VIDEO_CAPS_YUV ("YVYU") ";" GST_VIDEO_CAPS_YUV ("I420") ";" GST_VIDEO_CAPS_YUV ("YV12") ";" GST_VIDEO_CAPS_YUV ("IYUV") ";" GST_VIDEO_CAPS_YUV ("Y41B") ) );
GST_DEBUG_CATEGORY_STATIC (geometric_transform_debug); #define GST_CAT_DEFAULT geometric_transform_debug static GstStaticPadTemplate gst_geometric_transform_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_ABGR "; " GST_VIDEO_CAPS_ARGB "; " GST_VIDEO_CAPS_BGR "; " GST_VIDEO_CAPS_BGRA "; " GST_VIDEO_CAPS_BGRx "; " GST_VIDEO_CAPS_RGB "; " GST_VIDEO_CAPS_RGBA "; " GST_VIDEO_CAPS_RGBx "; " GST_VIDEO_CAPS_YUV ("AYUV") "; " GST_VIDEO_CAPS_xBGR "; " GST_VIDEO_CAPS_xRGB "; " GST_VIDEO_CAPS_GRAY8 "; " GST_VIDEO_CAPS_GRAY16 ("BIG_ENDIAN") "; " GST_VIDEO_CAPS_GRAY16 ("LITTLE_ENDIAN") ) ); static GstStaticPadTemplate gst_geometric_transform_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_ABGR "; " GST_VIDEO_CAPS_ARGB "; " GST_VIDEO_CAPS_BGR "; "
GstCaps * gst_dshow_new_video_caps (GstVideoFormat video_format, const gchar * name, GstCapturePinMediaType * pin_mediatype) { GstCaps *video_caps = NULL; GstStructure *video_structure = NULL; gint min_w, max_w; gint min_h, max_h; gint min_fr, max_fr; /* raw video format */ switch (video_format) { case GST_VIDEO_FORMAT_BGR: video_caps = gst_caps_from_string (GST_VIDEO_CAPS_BGR); break; case GST_VIDEO_FORMAT_I420: video_caps = gst_caps_from_string (GST_VIDEO_CAPS_YUV ("I420")); break; case GST_VIDEO_FORMAT_YUY2: video_caps = gst_caps_from_string (GST_VIDEO_CAPS_YUV ("YUY2")); break; default: break; } /* other video format */ if (!video_caps) { if (g_ascii_strncasecmp (name, "video/x-dv, systemstream=FALSE", 31) == 0) { video_caps = gst_caps_new_simple ("video/x-dv", "systemstream", G_TYPE_BOOLEAN, FALSE, "format", GST_TYPE_FOURCC, GST_MAKE_FOURCC ('d', 'v', 's', 'd'), NULL); } else if (g_ascii_strncasecmp (name, "video/x-dv, systemstream=TRUE", 31) == 0) { video_caps = gst_caps_new_simple ("video/x-dv", "systemstream", G_TYPE_BOOLEAN, TRUE, NULL); return video_caps; } } if (!video_caps) return NULL; video_structure = gst_caps_get_structure (video_caps, 0); /* Hope GST_TYPE_INT_RANGE_STEP will exits in future gstreamer releases */ /* because we could use : */ /* "width", GST_TYPE_INT_RANGE_STEP, video_default->minWidth, video_default->maxWidth, video_default->granularityWidth */ /* instead of : */ /* "width", GST_TYPE_INT_RANGE, video_default->minWidth, video_default->maxWidth */ /* For framerate we do not need a step (granularity) because */ /* "The IAMStreamConfig::SetFormat method will set the frame rate to the closest */ /* value that the filter supports" as it said in the VIDEO_STREAM_CONFIG_CAPS dshwo doc */ min_w = pin_mediatype->vscc.MinOutputSize.cx; max_w = pin_mediatype->vscc.MaxOutputSize.cx; min_h = pin_mediatype->vscc.MinOutputSize.cy; max_h = pin_mediatype->vscc.MaxOutputSize.cy; min_fr = (gint) (10000000 / pin_mediatype->vscc.MaxFrameInterval); max_fr = (gint)(10000000 / pin_mediatype->vscc.MinFrameInterval); if (min_w == max_w) gst_structure_set (video_structure, "width", G_TYPE_INT, min_w, NULL); else gst_structure_set (video_structure, "width", GST_TYPE_INT_RANGE, min_w, max_w, NULL); if (min_h == max_h) gst_structure_set (video_structure, "height", G_TYPE_INT, min_h, NULL); else gst_structure_set (video_structure, "height", GST_TYPE_INT_RANGE, min_h, max_h, NULL); if (min_fr == max_fr) gst_structure_set (video_structure, "framerate", GST_TYPE_FRACTION, min_fr, 1, NULL); else gst_structure_set (video_structure, "framerate", GST_TYPE_FRACTION_RANGE, min_fr, 1, max_fr, 1, NULL); return video_caps; }
const GValue * value, GParamSpec * pspec); static void gst_cogdownsample_get_property (GObject * object, guint prop_id, GValue * value, GParamSpec * pspec); static GstCaps *gst_cogdownsample_transform_caps (GstBaseTransform * base_transform, GstPadDirection direction, GstCaps * caps); static GstFlowReturn gst_cogdownsample_transform (GstBaseTransform * base_transform, GstBuffer * inbuf, GstBuffer * outbuf); static gboolean gst_cogdownsample_get_unit_size (GstBaseTransform * base_transform, GstCaps * caps, guint * size); static GstStaticPadTemplate gst_cogdownsample_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ I420, YV12, YUY2, UYVY, AYUV }")) ); static GstStaticPadTemplate gst_cogdownsample_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ I420, YV12, YUY2, UYVY, AYUV }")) ); GType gst_cogdownsample_get_type (void) { static GType compress_type = 0; if (!compress_type) {
static GstStaticPadTemplate sink_template = GST_STATIC_PAD_TEMPLATE ( "sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS ("video/x-h265") ); static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ( "src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS ( #if GST_CHECK_VERSION(1,0,0) GST_VIDEO_CAPS_MAKE("{ I420 }") #else GST_VIDEO_CAPS_YUV("{ I420 }") #endif ) ); enum { PROP_0, PROP_MODE, PROP_FRAMERATE, PROP_LAST }; #define DEFAULT_MODE GST_TYPE_LIBDE265_DEC_PACKETIZED #define DEFAULT_FPS_N 0 #define DEFAULT_FPS_D 1
{ PROP_0, PROP_METHOD /* FILL ME */ }; #define PROP_METHOD_DEFAULT GST_VIDEO_FLIP_METHOD_IDENTITY GST_DEBUG_CATEGORY_STATIC (video_flip_debug); #define GST_CAT_DEFAULT video_flip_debug static GstStaticPadTemplate gst_video_flip_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("AYUV") ";" GST_VIDEO_CAPS_ARGB ";" GST_VIDEO_CAPS_BGRA ";" GST_VIDEO_CAPS_ABGR ";" GST_VIDEO_CAPS_RGBA ";" GST_VIDEO_CAPS_YUV ("Y444") ";" GST_VIDEO_CAPS_xRGB ";" GST_VIDEO_CAPS_RGBx ";" GST_VIDEO_CAPS_xBGR ";" GST_VIDEO_CAPS_BGRx ";" GST_VIDEO_CAPS_RGB ";" GST_VIDEO_CAPS_BGR ";" GST_VIDEO_CAPS_YUV ("I420") ";" GST_VIDEO_CAPS_YUV ("YV12") ";" GST_VIDEO_CAPS_YUV ("IYUV") ) ); static GstStaticPadTemplate gst_video_flip_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS,
GST_STATIC_CAPS ("image/x-j2c, " "framerate = " GST_VIDEO_FPS_RANGE ", " "fields = (int) 1; " "image/x-jpc, " "framerate = " GST_VIDEO_FPS_RANGE ", " "fields = (int) 1; " "image/jp2") ); static GstStaticPadTemplate gst_jasper_dec_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_RGB "; " GST_VIDEO_CAPS_BGR "; " GST_VIDEO_CAPS_RGBx "; " GST_VIDEO_CAPS_xRGB "; " GST_VIDEO_CAPS_BGRx "; " GST_VIDEO_CAPS_xBGR "; " GST_VIDEO_CAPS_YUV ("{ I420, YV12, YUY2, UYVY, Y41B, Y42B, v308 }")) ); static void gst_jasper_dec_reset (GstJasperDec * dec); static GstStateChangeReturn gst_jasper_dec_change_state (GstElement * element, GstStateChange transition); static gboolean gst_jasper_dec_sink_setcaps (GstPad * pad, GstCaps * caps); static GstFlowReturn gst_jasper_dec_chain (GstPad * pad, GstBuffer * buffer); static gboolean gst_jasper_dec_src_event (GstPad * pad, GstEvent * event); static gboolean gst_jasper_dec_sink_event (GstPad * pad, GstEvent * event); static void gst_jasper_dec_update_qos (GstJasperDec * dec, gdouble proportion, GstClockTime time); static void gst_jasper_dec_reset_qos (GstJasperDec * dec); static void gst_jasper_dec_read_qos (GstJasperDec * dec, gdouble * proportion, GstClockTime * time);
PROP_PATTERN_COUNT, PROP_PATTERN_DATA_COUNT, PROP_PATTERN_CENTER, PROP_PATTERN_SENSITIVITY, PROP_LEFT_OFFSET, PROP_BOTTOM_OFFSET }; GST_DEBUG_CATEGORY_STATIC (video_detect_debug); #define GST_CAT_DEFAULT video_detect_debug static GstStaticPadTemplate gst_video_detect_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ I420, YV12, Y41B, Y42B, Y444, YUY2, UYVY, AYUV, YVYU }")) ); static GstStaticPadTemplate gst_video_detect_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ I420, YV12, Y41B, Y42B, Y444, YUY2, UYVY, AYUV, YVYU }")) ); static GstVideoFilterClass *parent_class = NULL; static gboolean gst_video_detect_set_caps (GstBaseTransform * btrans, GstCaps * incaps, GstCaps * outcaps)
/* FILL ME */ LAST_SIGNAL }; enum { ARG_0, ARG_SPEED /* FILL ME */ }; static GstStaticPadTemplate gst_videodrop_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ YUY2, I420, YV12, YUYV, UYVY }") ) ); static GstStaticPadTemplate gst_videodrop_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, GST_STATIC_CAPS (GST_VIDEO_CAPS_YUV ("{ YUY2, I420, YV12, YUYV, UYVY }") ) ); static void gst_videodrop_base_init (gpointer g_class); static void gst_videodrop_class_init (GstVideodropClass * klass); static void gst_videodrop_init (GstVideodrop * videodrop); static void gst_videodrop_chain (GstPad * pad, GstData * _data);