basesink.h

Go to the documentation of this file.
00001 // -*- c++ -*-
00002 // Generated by gtkmmproc -- DO NOT MODIFY!
00003 #ifndef _GSTREAMERMM_BASESINK_H
00004 #define _GSTREAMERMM_BASESINK_H
00005 
00006 
00007 #include <glibmm.h>
00008 
00009 // -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*-
00010 
00011 /* gstreamermm - a C++ wrapper for gstreamer
00012  *
00013  * Copyright 2008 The gstreamermm Development Team
00014  *
00015  * This library is free software; you can redistribute it and/or
00016  * modify it under the terms of the GNU Library General Public
00017  * License as published by the Free Software Foundation; either
00018  * version 2 of the License, or (at your option) any later version.
00019  *
00020  * This library is distributed in the hope that it will be useful,
00021  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00022  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00023  * Library General Public License for more details.
00024  *
00025  * You should have received a copy of the GNU Library General Public
00026  * License along with this library; if not, write to the Free
00027  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00028  */
00029 
00030 #include <gstreamermm/element.h>
00031 #include <gstreamermm/buffer.h>
00032 #include <gstreamermm/pad.h>
00033 
00034 
00035 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00036 typedef struct _GstBaseSink GstBaseSink;
00037 typedef struct _GstBaseSinkClass GstBaseSinkClass;
00038 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
00039 
00040 
00041 namespace Gst
00042 { class BaseSink_Class; } // namespace Gst
00043 namespace Gst
00044 {
00045 
00147 class BaseSink
00148 : public Element
00149 {
00150   
00151 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00152 
00153 public:
00154   typedef BaseSink CppObjectType;
00155   typedef BaseSink_Class CppClassType;
00156   typedef GstBaseSink BaseObjectType;
00157   typedef GstBaseSinkClass BaseClassType;
00158 
00159 private:  friend class BaseSink_Class;
00160   static CppClassType basesink_class_;
00161 
00162 private:
00163   // noncopyable
00164   BaseSink(const BaseSink&);
00165   BaseSink& operator=(const BaseSink&);
00166 
00167 protected:
00168   explicit BaseSink(const Glib::ConstructParams& construct_params);
00169   explicit BaseSink(GstBaseSink* castitem);
00170 
00171 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
00172 
00173 public:
00174   virtual ~BaseSink();
00175 
00176 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00177   static GType get_type()      G_GNUC_CONST;
00178   static GType get_base_type() G_GNUC_CONST;
00179 #endif
00180 
00182   GstBaseSink*       gobj()       { return reinterpret_cast<GstBaseSink*>(gobject_); }
00183 
00185   const GstBaseSink* gobj() const { return reinterpret_cast<GstBaseSink*>(gobject_); }
00186 
00188   GstBaseSink* gobj_copy();
00189 
00190 private:
00191 
00192 
00193 public:
00194   
00213   bool query_latency(bool& live, bool& upstream_live, ClockTime& min_latency, ClockTime& max_latency);
00214   
00220   ClockTime get_latency();
00221   
00233   FlowReturn wait_preroll();
00234   
00235   ClockReturn wait_clock(ClockTime time, ClockTimeDiff& jitter);
00236   
00252   FlowReturn wait_eos(ClockTime time, ClockTimeDiff& jitter);
00253   
00263   void set_sync(bool sync);
00264   
00271   bool get_sync();
00272   
00281   void set_max_lateness(gint64 max_lateness);
00282   
00291   gint64 get_max_lateness();
00292   
00298   void set_qos_enabled(bool enabled);
00299   
00306   bool is_qos_enabled();
00307   
00316   void set_async_enabled(bool enabled); 
00317   
00325   bool is_async_enabled();
00326   
00335   void set_ts_offset(ClockTimeDiff offset);
00336   
00342   ClockTimeDiff get_ts_offset();
00343 
00344   //TODO: Doesn't compile with GStreamer 0.10.20:
00345   //_WRAP_METHOD(void set_render_delay(ClockTime delay), gst_base_sink_set_render_delay)
00346 
00347   //TODO: Doesn't compile with GStreamer 0.10.20:
00348   //_WRAP_METHOD(ClockTime get_render_delay(), gst_base_sink_get_render_delay)
00349 
00350   
00361   Glib::RefPtr<Buffer> get_last_buffer();
00362 
00365    Glib::RefPtr<Pad> get_sink_pad() const;
00366  
00367   #ifdef GLIBMM_PROPERTIES_ENABLED
00368 
00374   Glib::PropertyProxy<bool> property_async() ;
00375 #endif //#GLIBMM_PROPERTIES_ENABLED
00376 
00377 #ifdef GLIBMM_PROPERTIES_ENABLED
00378 
00384   Glib::PropertyProxy_ReadOnly<bool> property_async() const;
00385 #endif //#GLIBMM_PROPERTIES_ENABLED
00386 
00387   #ifdef GLIBMM_PROPERTIES_ENABLED
00388 
00394   Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Buffer> > property_last_buffer() const;
00395 #endif //#GLIBMM_PROPERTIES_ENABLED
00396 
00397 
00398   #ifdef GLIBMM_PROPERTIES_ENABLED
00399 
00405   Glib::PropertyProxy<gint64> property_max_lateness() ;
00406 #endif //#GLIBMM_PROPERTIES_ENABLED
00407 
00408 #ifdef GLIBMM_PROPERTIES_ENABLED
00409 
00415   Glib::PropertyProxy_ReadOnly<gint64> property_max_lateness() const;
00416 #endif //#GLIBMM_PROPERTIES_ENABLED
00417 
00418   #ifdef GLIBMM_PROPERTIES_ENABLED
00419 
00425   Glib::PropertyProxy<guint> property_preroll_queue_len() ;
00426 #endif //#GLIBMM_PROPERTIES_ENABLED
00427 
00428 #ifdef GLIBMM_PROPERTIES_ENABLED
00429 
00435   Glib::PropertyProxy_ReadOnly<guint> property_preroll_queue_len() const;
00436 #endif //#GLIBMM_PROPERTIES_ENABLED
00437 
00438   #ifdef GLIBMM_PROPERTIES_ENABLED
00439 
00445   Glib::PropertyProxy<bool> property_qos() ;
00446 #endif //#GLIBMM_PROPERTIES_ENABLED
00447 
00448 #ifdef GLIBMM_PROPERTIES_ENABLED
00449 
00455   Glib::PropertyProxy_ReadOnly<bool> property_qos() const;
00456 #endif //#GLIBMM_PROPERTIES_ENABLED
00457 
00458   #ifdef GLIBMM_PROPERTIES_ENABLED
00459 
00465   Glib::PropertyProxy<bool> property_sync() ;
00466 #endif //#GLIBMM_PROPERTIES_ENABLED
00467 
00468 #ifdef GLIBMM_PROPERTIES_ENABLED
00469 
00475   Glib::PropertyProxy_ReadOnly<bool> property_sync() const;
00476 #endif //#GLIBMM_PROPERTIES_ENABLED
00477 
00478   #ifdef GLIBMM_PROPERTIES_ENABLED
00479 
00485   Glib::PropertyProxy<gint64> property_ts_offset() ;
00486 #endif //#GLIBMM_PROPERTIES_ENABLED
00487 
00488 #ifdef GLIBMM_PROPERTIES_ENABLED
00489 
00495   Glib::PropertyProxy_ReadOnly<gint64> property_ts_offset() const;
00496 #endif //#GLIBMM_PROPERTIES_ENABLED
00497 
00498 
00501   #ifdef GLIBMM_VFUNCS_ENABLED
00502   virtual Glib::RefPtr<Caps> get_caps_vfunc();
00503 #endif //GLIBMM_VFUNCS_ENABLED
00504 
00505 
00508   #ifdef GLIBMM_VFUNCS_ENABLED
00509   virtual bool set_caps_vfunc(const Glib::RefPtr<Caps>& caps);
00510 #endif //GLIBMM_VFUNCS_ENABLED
00511 
00512 
00513 //TODO: #m4 __CONVERSION(`Glib::RefPtr<Buffer>&', `GstBuffer**', `*($3)')
00514   //_WRAP_VFUNC(FlowReturn buffer_alloc(guint64 offset, guint size, Glib::RefPtr<Buffer>& buffer), "buffer_alloc")
00515 
00516  
00520   #ifdef GLIBMM_VFUNCS_ENABLED
00521   virtual void get_times_vfunc(const Glib::RefPtr<Buffer>& buffer, ClockTime& start, ClockTime& end);
00522 #endif //GLIBMM_VFUNCS_ENABLED
00523 
00524 
00527   #ifdef GLIBMM_VFUNCS_ENABLED
00528   virtual bool start_vfunc();
00529 #endif //GLIBMM_VFUNCS_ENABLED
00530 
00531 
00534   #ifdef GLIBMM_VFUNCS_ENABLED
00535   virtual bool stop_vfunc();
00536 #endif //GLIBMM_VFUNCS_ENABLED
00537 
00538 
00542   #ifdef GLIBMM_VFUNCS_ENABLED
00543   virtual bool unlock_vfunc();
00544 #endif //GLIBMM_VFUNCS_ENABLED
00545 
00546 
00549   #ifdef GLIBMM_VFUNCS_ENABLED
00550   virtual bool event_vfunc(const Glib::RefPtr<Event>& event);
00551 #endif //GLIBMM_VFUNCS_ENABLED
00552 
00553 
00556   #ifdef GLIBMM_VFUNCS_ENABLED
00557   virtual FlowReturn preroll_vfunc(const Glib::RefPtr<Buffer>& buffer);
00558 #endif //GLIBMM_VFUNCS_ENABLED
00559 
00560 
00564   #ifdef GLIBMM_VFUNCS_ENABLED
00565   virtual FlowReturn render_vfunc(const Glib::RefPtr<Buffer>& buffer);
00566 #endif //GLIBMM_VFUNCS_ENABLED
00567 
00568 
00573   #ifdef GLIBMM_VFUNCS_ENABLED
00574   virtual StateChangeReturn async_play_vfunc();
00575 #endif //GLIBMM_VFUNCS_ENABLED
00576 
00577 
00584   #ifdef GLIBMM_VFUNCS_ENABLED
00585   virtual bool activate_pull_vfunc(bool active);
00586 #endif //GLIBMM_VFUNCS_ENABLED
00587 
00588 
00594   #ifdef GLIBMM_VFUNCS_ENABLED
00595   virtual void fixate_vfunc(const Glib::RefPtr<Caps>& caps);
00596 #endif //GLIBMM_VFUNCS_ENABLED
00597 
00598 
00602   #ifdef GLIBMM_VFUNCS_ENABLED
00603   virtual bool unlock_stop_vfunc();
00604 #endif //GLIBMM_VFUNCS_ENABLED
00605 
00606 
00607 public:
00608 
00609 public:
00610   //C++ methods used to invoke GTK+ virtual functions:
00611 #ifdef GLIBMM_VFUNCS_ENABLED
00612 #endif //GLIBMM_VFUNCS_ENABLED
00613 
00614 protected:
00615   //GTK+ Virtual Functions (override these to change behaviour):
00616 #ifdef GLIBMM_VFUNCS_ENABLED
00617 #endif //GLIBMM_VFUNCS_ENABLED
00618 
00619   //Default Signal Handlers::
00620 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00621 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00622 
00623 
00624 };
00625 
00626 } //namespace Gst
00627 
00628 
00629 namespace Glib
00630 {
00639   Glib::RefPtr<Gst::BaseSink> wrap(GstBaseSink* object, bool take_copy = false);
00640 }
00641 
00642 
00643 #endif /* _GSTREAMERMM_BASESINK_H */
00644 

Generated on Sun Jul 27 17:07:20 2008 for gstreamermm by  doxygen 1.5.4