QtGStreamer 1.2.0
Loading...
Searching...
No Matches
pluginfeature.cpp
1/*
2 Copyright (C) 2010 George Kiagiadakis <kiagiadakis.george@gmail.com>
3
4 This library is free software; you can redistribute it and/or modify
5 it under the terms of the GNU Lesser General Public License as published
6 by the Free Software Foundation; either version 2.1 of the License, or
7 (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU Lesser General Public License for more details.
13
14 You should have received a copy of the GNU Lesser General Public License
15 along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#include "pluginfeature.h"
18#include <gst/gst.h>
19
20namespace QGst {
21
22uint PluginFeature::rank() const
23{
24 return gst_plugin_feature_get_rank(object<GstPluginFeature>());
25}
26
27void PluginFeature::setRank(uint rank)
28{
29 gst_plugin_feature_set_rank(object<GstPluginFeature>(), rank);
30}
31
32QString PluginFeature::name() const
33{
34 return QString::fromUtf8(gst_plugin_feature_get_name(object<GstPluginFeature>()));
35}
36
37void PluginFeature::setName(const char *name)
38{
39 gst_plugin_feature_set_name(object<GstPluginFeature>(), name);
40}
41
42bool PluginFeature::isAtLeastVersion(uint major, uint minor, uint micro) const
43{
44 return gst_plugin_feature_check_version(object<GstPluginFeature>(), major, minor, micro);
45}
46
47PluginFeaturePtr PluginFeature::load()
48{
49 return PluginFeaturePtr::wrap(gst_plugin_feature_load(object<GstPluginFeature>()), false);
50}
51
52}
static RefPointer< T > wrap(typename T::CType *nativePtr, bool increaseRef=true)
Definition refpointer.h:328
Wrappers for GStreamer classes.