- Your Widget Set For OpenGL
Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members | Related Pages

uvideodevice.hpp

00001 /*************************************************************************** 00002 LibUFO - UI For OpenGL 00003 copyright : (C) 2001-2005 by Johannes Schmidt 00004 email : schmidtjf at users.sourceforge.net 00005 ------------------- 00006 00007 file : include/ufo/uvideodevice.hpp 00008 begin : Wed Jul 28 2004 00009 $Id: uvideodevice.hpp,v 1.6 2005/05/21 15:17:23 schmidtjf Exp $ 00010 ***************************************************************************/ 00011 00012 /*************************************************************************** 00013 * This library is free software; you can redistribute it and/or * 00014 * modify it under the terms of the GNU Lesser General Public * 00015 * License as published by the Free Software Foundation; either * 00016 * version 2.1 of the License, or (at your option) any later version. * 00017 * * 00018 * This library is distributed in the hope that it will be useful, * 00019 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00020 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00021 * Lesser General Public License for more details. * 00022 * * 00023 * You should have received a copy of the GNU Lesser General Public * 00024 * License along with this library; if not, write to the Free Software * 00025 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * 00026 ***************************************************************************/ 00027 00028 #ifndef UVIDEODEVICE_HPP 00029 #define UVIDEODEVICE_HPP 00030 00031 #include "uobject.hpp" 00032 #include "util/upoint.hpp" 00033 #include "util/udimension.hpp" 00034 #include "signals/usignal.hpp" 00035 00036 namespace ufo { 00037 00038 class UXFrame; 00039 00046 class UFO_EXPORT UVideoDevice : public UObject { 00047 UFO_DECLARE_ABSTRACT_CLASS(UVideoDevice) 00048 public: // public methods 00049 virtual void setSize(int w, int h) = 0; 00050 virtual UDimension getSize() const = 0; 00051 00052 virtual void setLocation(int x, int y) = 0; 00053 virtual UPoint getLocation() const = 0; 00054 00055 virtual void setTitle(const std::string & title) = 0; 00056 virtual std::string getTitle() const = 0; 00057 00058 virtual void setDepth(int depth) = 0; 00059 virtual int getDepth() const = 0; 00060 00061 virtual void swapBuffers() = 0; 00065 virtual void makeContextCurrent() = 0; 00066 00067 virtual bool show() = 0; 00068 virtual void hide() = 0; 00069 00073 virtual void setFrameStyle(uint32_t frameStyle) = 0; 00074 virtual uint32_t getFrameStyle() const = 0; 00075 00080 virtual void setInitialFrameState(uint32_t frameState) = 0; 00084 virtual uint32_t getFrameState() const = 0; 00085 00086 public: // Public methods, used to notify the device of system changes 00087 virtual void setFrame(UXFrame * frame) = 0; 00097 virtual void notify(uint32_t type, int arg1, int arg2, int arg3, int arg4) = 0; 00098 00099 public: // Public signals 00100 USignal1<UVideoDevice*> & sigMoved(); 00101 USignal1<UVideoDevice*> & sigResized(); 00102 private: // Private signals 00103 USignal1<UVideoDevice*> m_sigMoved; 00104 USignal1<UVideoDevice*> m_sigResized; 00105 }; 00106 00107 // 00108 // inline implementation 00109 // 00110 00111 inline USignal1<UVideoDevice*> & 00112 UVideoDevice::sigMoved() { 00113 return m_sigMoved; 00114 } 00115 00116 inline USignal1<UVideoDevice*> & 00117 UVideoDevice::sigResized() { 00118 return m_sigResized; 00119 } 00120 00121 } // namespace ufo 00122 00123 #endif // UVIDEODEVICE_HPP

The libUFO Project - written by Johannes Schmidt