QtGStreamer 0.10.1
|
00001 /* 00002 Copyright (C) 2010 George Kiagiadakis <kiagiadakis.george@gmail.com> 00003 Copyright (C) 2010 Collabora Multimedia. 00004 @author Mauricio Piacentini <mauricio.piacentini@collabora.co.uk> 00005 00006 This library is free software; you can redistribute it and/or modify 00007 it under the terms of the GNU Lesser General Public License as published 00008 by the Free Software Foundation; either version 2.1 of the License, or 00009 (at your option) any later version. 00010 00011 This program is distributed in the hope that it will be useful, 00012 but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 GNU General Public License for more details. 00015 00016 You should have received a copy of the GNU Lesser General Public License 00017 along with this program. If not, see <http://www.gnu.org/licenses/>. 00018 */ 00019 #include "videoorientation.h" 00020 #include <gst/interfaces/videoorientation.h> 00021 00022 namespace QGst { 00023 00024 bool VideoOrientation::horizontalFlipEnabled() const 00025 { 00026 gboolean flipped; 00027 //Ignoring the gboolean result of the function, can be tested when setting the property 00028 gst_video_orientation_get_hflip(object<GstVideoOrientation>(), &flipped); 00029 return flipped; 00030 } 00031 00032 bool VideoOrientation::verticalFlipEnabled() const 00033 { 00034 gboolean flipped; 00035 //Ignoring the gboolean result of the function, can be tested when setting the property 00036 gst_video_orientation_get_vflip(object<GstVideoOrientation>(), &flipped); 00037 return flipped; 00038 } 00039 00040 int VideoOrientation::horizontalCenter() const 00041 { 00042 int center = 0; 00043 //Ignoring the gboolean result of the function, can be tested when setting the property 00044 gst_video_orientation_get_hcenter(object<GstVideoOrientation>(), ¢er); 00045 return center; 00046 } 00047 00048 int VideoOrientation::verticalCenter() const 00049 { 00050 int center = 0; 00051 //Ignoring the gboolean result of the function, can be tested when setting the property 00052 gst_video_orientation_get_vcenter(object<GstVideoOrientation>(), ¢er); 00053 return center; 00054 } 00055 00056 bool VideoOrientation::enableHorizontalFlip(bool enabled) 00057 { 00058 return gst_video_orientation_set_hflip(object<GstVideoOrientation>(), enabled); 00059 } 00060 00061 bool VideoOrientation::enableVerticalFlip(bool enabled) 00062 { 00063 return gst_video_orientation_set_vflip(object<GstVideoOrientation>(), enabled); 00064 } 00065 00066 bool VideoOrientation::setHorizontalCenter(int center) 00067 { 00068 return gst_video_orientation_set_hcenter(object<GstVideoOrientation>(), center); 00069 } 00070 00071 bool VideoOrientation::setVerticalCenter(int center) 00072 { 00073 return gst_video_orientation_set_hcenter(object<GstVideoOrientation>(), center); 00074 } 00075 00076 } //namespace QGst 00077