media.h
Go to the documentation of this file.00001
00002
00003 #ifndef _CLUTTERMM_MEDIA_H
00004 #define _CLUTTERMM_MEDIA_H
00005
00006
00007 #include <glibmm.h>
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #include <glibmm/interface.h>
00027 #include <glibmm/ustring.h>
00028 #include <clutter/clutter-media.h>
00029
00030
00031 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00032 typedef struct _ClutterMedia ClutterMedia;
00033 typedef struct _ClutterMediaClass ClutterMediaClass;
00034 #endif
00035
00036
00037 namespace Clutter
00038 { class Media_Class; }
00039 namespace Clutter
00040 {
00041
00042
00043 class Media : public Glib::Interface
00044 {
00045
00046 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00047
00048 public:
00049 typedef Media CppObjectType;
00050 typedef Media_Class CppClassType;
00051 typedef ClutterMedia BaseObjectType;
00052 typedef ClutterMediaInterface BaseClassType;
00053
00054 private:
00055 friend class Media_Class;
00056 static CppClassType media_class_;
00057
00058
00059 Media(const Media&);
00060 Media& operator=(const Media&);
00061
00062 protected:
00063 Media();
00064
00071 explicit Media(const Glib::Interface_Class& interface_class);
00072
00073 public:
00074
00075
00076
00077 explicit Media(ClutterMedia* castitem);
00078
00079 protected:
00080 #endif
00081
00082 public:
00083 virtual ~Media();
00084
00085 static void add_interface(GType gtype_implementer);
00086
00087 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00088 static GType get_type() G_GNUC_CONST;
00089 static GType get_base_type() G_GNUC_CONST;
00090 #endif
00091
00093 ClutterMedia* gobj() { return reinterpret_cast<ClutterMedia*>(gobject_); }
00094
00096 const ClutterMedia* gobj() const { return reinterpret_cast<ClutterMedia*>(gobject_); }
00097
00098 private:
00099
00100
00101 public:
00102
00103
00107 void set_uri(const Glib::ustring& uri);
00108
00112 Glib::ustring get_uri() const;
00113
00117 void set_playing(bool playing=true);
00118
00122 bool get_playing() const;
00123
00127 void set_position(int position);
00128
00132 int get_position() const;
00133
00137 void set_volume(double volume);
00138
00142 double get_volume() const;
00143
00147 int get_buffer_percent() const;
00148
00152 void set_filename(const Glib::ustring& filename);
00153
00157 bool get_can_seek() const;
00158
00162 int get_duration() const;
00163
00164
00170 Glib::SignalProxy0< void > signal_eos();
00171
00172
00173
00174
00175 #ifdef GLIBMM_PROPERTIES_ENABLED
00176
00182 Glib::PropertyProxy_ReadOnly<int> property_buffer_percent() const;
00183 #endif //#GLIBMM_PROPERTIES_ENABLED
00184
00185
00186 #ifdef GLIBMM_PROPERTIES_ENABLED
00187
00193 Glib::PropertyProxy_ReadOnly<bool> property_can_seek() const;
00194 #endif //#GLIBMM_PROPERTIES_ENABLED
00195
00196
00197 #ifdef GLIBMM_PROPERTIES_ENABLED
00198
00204 Glib::PropertyProxy_ReadOnly<int> property_duration() const;
00205 #endif //#GLIBMM_PROPERTIES_ENABLED
00206
00207
00208 #ifdef GLIBMM_PROPERTIES_ENABLED
00209
00215 Glib::PropertyProxy<bool> property_playing() ;
00216 #endif //#GLIBMM_PROPERTIES_ENABLED
00217
00218 #ifdef GLIBMM_PROPERTIES_ENABLED
00219
00225 Glib::PropertyProxy_ReadOnly<bool> property_playing() const;
00226 #endif //#GLIBMM_PROPERTIES_ENABLED
00227
00228 #ifdef GLIBMM_PROPERTIES_ENABLED
00229
00235 Glib::PropertyProxy<int> property_position() ;
00236 #endif //#GLIBMM_PROPERTIES_ENABLED
00237
00238 #ifdef GLIBMM_PROPERTIES_ENABLED
00239
00245 Glib::PropertyProxy_ReadOnly<int> property_position() const;
00246 #endif //#GLIBMM_PROPERTIES_ENABLED
00247
00248 #ifdef GLIBMM_PROPERTIES_ENABLED
00249
00255 Glib::PropertyProxy<Glib::ustring> property_uri() ;
00256 #endif //#GLIBMM_PROPERTIES_ENABLED
00257
00258 #ifdef GLIBMM_PROPERTIES_ENABLED
00259
00265 Glib::PropertyProxy_ReadOnly<Glib::ustring> property_uri() const;
00266 #endif //#GLIBMM_PROPERTIES_ENABLED
00267
00268 #ifdef GLIBMM_PROPERTIES_ENABLED
00269
00275 Glib::PropertyProxy<double> property_volume() ;
00276 #endif //#GLIBMM_PROPERTIES_ENABLED
00277
00278 #ifdef GLIBMM_PROPERTIES_ENABLED
00279
00285 Glib::PropertyProxy_ReadOnly<double> property_volume() const;
00286 #endif //#GLIBMM_PROPERTIES_ENABLED
00287
00288
00289 protected:
00290
00291
00292 #ifdef GLIBMM_VFUNCS_ENABLED
00293 virtual void set_uri_vfunc(const Glib::ustring& uri);
00294 #endif //GLIBMM_VFUNCS_ENABLED
00295
00296
00297
00298
00299
00300
00301
00302
00303
00304
00305 #ifdef GLIBMM_VFUNCS_ENABLED
00306 virtual const char* get_uri_vfunc() const;
00307 #endif //GLIBMM_VFUNCS_ENABLED
00308
00309 #ifdef GLIBMM_VFUNCS_ENABLED
00310 virtual void set_playing_vfunc(bool playing);
00311 #endif //GLIBMM_VFUNCS_ENABLED
00312
00313 #ifdef GLIBMM_VFUNCS_ENABLED
00314 virtual bool get_playing_vfunc() const;
00315 #endif //GLIBMM_VFUNCS_ENABLED
00316
00317 #ifdef GLIBMM_VFUNCS_ENABLED
00318 virtual void set_position_vfunc(int position);
00319 #endif //GLIBMM_VFUNCS_ENABLED
00320
00321 #ifdef GLIBMM_VFUNCS_ENABLED
00322 virtual int get_position_vfunc() const;
00323 #endif //GLIBMM_VFUNCS_ENABLED
00324
00325 #ifdef GLIBMM_VFUNCS_ENABLED
00326 virtual void set_volume_vfunc(double volume);
00327 #endif //GLIBMM_VFUNCS_ENABLED
00328
00329 #ifdef GLIBMM_VFUNCS_ENABLED
00330 virtual double get_volume_vfunc() const;
00331 #endif //GLIBMM_VFUNCS_ENABLED
00332
00333 #ifdef GLIBMM_VFUNCS_ENABLED
00334 virtual bool can_seek_vfunc() const;
00335 #endif //GLIBMM_VFUNCS_ENABLED
00336
00337 #ifdef GLIBMM_VFUNCS_ENABLED
00338 virtual int get_buffer_percent_vfunc() const;
00339 #endif //GLIBMM_VFUNCS_ENABLED
00340
00341 #ifdef GLIBMM_VFUNCS_ENABLED
00342 virtual int get_duration_vfunc() const;
00343 #endif //GLIBMM_VFUNCS_ENABLED
00344
00345
00346 public:
00347
00348 public:
00349
00350 #ifdef GLIBMM_VFUNCS_ENABLED
00351 #endif //GLIBMM_VFUNCS_ENABLED
00352
00353 protected:
00354
00355 #ifdef GLIBMM_VFUNCS_ENABLED
00356 #endif //GLIBMM_VFUNCS_ENABLED
00357
00358
00359 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00360 virtual void on_eos();
00361 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00362
00363
00364 };
00365
00366 }
00367
00368
00369
00370 namespace Glib
00371 {
00380 Glib::RefPtr<Clutter::Media> wrap(ClutterMedia* object, bool take_copy = false);
00381
00382 }
00383
00384
00385 #endif
00386