From c1cb1e0c5bf6b3b9d71cf68f7cb269a568ac3255 Mon Sep 17 00:00:00 2001 From: Thijs Vermeir Date: Fri, 23 Jan 2009 15:39:46 +0100 Subject: Add aspectratiocrop element. Fixes bug #527951 Add new aspectratiocrop element that crops the video to a specified aspect ratio using videocrop. --- gst/videocrop/gstvideocrop.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'gst/videocrop/gstvideocrop.c') diff --git a/gst/videocrop/gstvideocrop.c b/gst/videocrop/gstvideocrop.c index 781634e2..7c1428c2 100644 --- a/gst/videocrop/gstvideocrop.c +++ b/gst/videocrop/gstvideocrop.c @@ -67,6 +67,7 @@ #include #include "gstvideocrop.h" +#include "gstaspectratiocrop.h" #include @@ -752,8 +753,13 @@ plugin_init (GstPlugin * plugin) { GST_DEBUG_CATEGORY_INIT (videocrop_debug, "videocrop", 0, "videocrop"); - return gst_element_register (plugin, "videocrop", GST_RANK_NONE, - GST_TYPE_VIDEO_CROP); + if (gst_element_register (plugin, "videocrop", GST_RANK_NONE, + GST_TYPE_VIDEO_CROP) + && gst_element_register (plugin, "aspectratiocrop", GST_RANK_NONE, + GST_TYPE_ASPECT_RATIO_CROP)) + return TRUE; + + return FALSE; } GST_PLUGIN_DEFINE (GST_VERSION_MAJOR, -- cgit