QtGStreamer  1.2.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Pages
miniobject.h
1 /*
2  Copyright (C) 2009-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 #ifndef QGST_MINIOBJECT_H
18 #define QGST_MINIOBJECT_H
19 
20 #include "global.h"
21 #include "../QGlib/refpointer.h"
22 #include "../QGlib/type.h"
23 
24 namespace QGst {
25 
29 class QTGSTREAMER_EXPORT MiniObject : public QGlib::RefCountedObject
30 {
31 // expanded QGST_WRAPPER(MiniObject) but without MiniObject_new()
32 // this is to avoid codegen picking it up, since MiniObject has no
33 // GType and cannot be handled properly
34 public:
35  typedef GstMiniObject CType;
36 protected:
37  MiniObject() {}
38  MiniObject(const MiniObject &);
39  MiniObject & operator=(const MiniObject &);
40  ~MiniObject() {}
41 
42 public:
43  MiniObjectPtr copy() const;
44  bool isWritable() const;
45  MiniObjectPtr makeWritable() const;
46 
47 protected:
48  virtual void ref(bool increaseRef);
49  virtual void unref();
50 };
51 
52 
53 namespace Private {
54 
55 QTGSTREAMER_EXPORT QGlib::RefCountedObject *wrapMiniObject(void *miniObject);
56 
57 } //namespace Private
58 } //namespace QGst
59 
60 QGLIB_REGISTER_WRAPIMPL_FOR_SUBCLASSES_OF(QGst::MiniObject, QGst::Private::wrapMiniObject)
61 
62 #endif
Wrapper class for GstMiniObject.
Definition: miniobject.h:29
Smart pointer class for working with wrapper classes that support reference counting.
Definition: global.h:56
Base class for all the reference-counted object wrappers.
Definition: refpointer.h:179