TGLAdapter.h

Go to the documentation of this file.
00001 // @(#)root/gl:$Id: TGLAdapter.h 20882 2007-11-19 11:31:26Z rdm $
00002 // Author:  Timur Pocheptsov, Jun 2007
00003 
00004 /*************************************************************************
00005  * Copyright (C) 1995-2004, Rene Brun and Fons Rademakers.               *
00006  * All rights reserved.                                                  *
00007  *                                                                       *
00008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
00009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
00010  *************************************************************************/
00011 
00012 #ifndef ROOT_TGLAdapter
00013 #define ROOT_TGLAdapter
00014 
00015 #ifndef ROOT_TVirtualGL
00016 #include "TVirtualGL.h"
00017 #endif
00018 
00019 class TGLAdapter : public TGLPaintDevice {
00020 private:
00021    Int_t fGLDevice;
00022 
00023 public:
00024    explicit TGLAdapter(Int_t glDevice = -1);
00025 
00026    Bool_t            MakeCurrent();
00027    void              SwapBuffers();
00028    const TGLFormat  *GetPixelFormat()const{return 0;}
00029    const TGLContext *GetContext()const{return 0;}
00030 
00031    void SetGLDevice(Int_t glDevice)
00032    {
00033       fGLDevice = glDevice;
00034    }
00035 
00036    void ReadGLBuffer();
00037    void SelectOffScreenDevice();
00038    void MarkForDirectCopy(Bool_t isDirect);
00039    void ExtractViewport(Int_t *vp)const;
00040 
00041 private:
00042    TGLAdapter(const TGLAdapter &);
00043    TGLAdapter &operator = (const TGLAdapter &);
00044 
00045    void AddContext(TGLContext *){}
00046    void RemoveContext(TGLContext *){}
00047 
00048    ClassDef(TGLAdapter, 0) // Allow plot-painters to be used for gl-inpad and gl-viewer.
00049 };
00050 
00051 #endif

Generated on Tue Jul 5 14:16:42 2011 for ROOT_528-00b_version by  doxygen 1.5.1