/* GStreamer
- * Copyright (C) 2013 FIXME <fixme@example.com>
+ * Copyright (C) 2013 David Schleef <ds@schleef.org>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
/**
* SECTION:element-gstvideodiff
*
- * The videodiff element does FIXME stuff.
+ * The videodiff element highlights the difference between a frame and its
+ * previous on the luma plane.
*
* <refsect2>
* <title>Example launch line</title>
* |[
- * gst-launch-1.0 -v fakesrc ! videodiff ! FIXME ! fakesink
+ * gst-launch-1.0 -v videotestsrc pattern=ball ! videodiff ! videoconvert ! autovideosink
* ]|
- * FIXME Describe what the pipeline does.
* </refsect2>
*/
static GstFlowReturn gst_video_diff_transform_frame (GstVideoFilter * filter,
GstVideoFrame * inframe, GstVideoFrame * outframe);
-enum
-{
- PROP_0
-};
-
-/* pad templates */
-
-/* FIXME: add/remove formats you can handle */
#define VIDEO_SRC_CAPS \
GST_VIDEO_CAPS_MAKE("{ I420, Y444, Y42B, UYVY, RGBA }")
-/* FIXME: add/remove formats you can handle */
#define VIDEO_SINK_CAPS \
GST_VIDEO_CAPS_MAKE("{ I420, Y444, Y42B, UYVY, RGBA }")
-/* class initialization */
-
G_DEFINE_TYPE_WITH_CODE (GstVideoDiff, gst_video_diff, GST_TYPE_VIDEO_FILTER,
GST_DEBUG_CATEGORY_INIT (gst_video_diff_debug_category, "videodiff", 0,
"debug category for videodiff element"));
{
GstVideoFilterClass *video_filter_class = GST_VIDEO_FILTER_CLASS (klass);
- /* Setting up pads and setting metadata should be moved to
- base_class_init if you intend to subclass this class. */
gst_element_class_add_pad_template (GST_ELEMENT_CLASS (klass),
gst_pad_template_new ("src", GST_PAD_SRC, GST_PAD_ALWAYS,
gst_caps_from_string (VIDEO_SRC_CAPS)));
gst_caps_from_string (VIDEO_SINK_CAPS)));
gst_element_class_set_static_metadata (GST_ELEMENT_CLASS (klass),
- "FIXME Long name", "Generic", "FIXME Description",
- "FIXME <fixme@example.com>");
+ "Video Diff", "Video/Filter",
+ "Visualize differences between adjacent video frames",
+ "David Schleef <ds@schleef.org>");
video_filter_class->transform_frame =
GST_DEBUG_FUNCPTR (gst_video_diff_transform_frame);
-
}
static void