]> git.saurik.com Git - wxWidgets.git/blame - wxPython/contrib/glcanvas/msw/glcanvas.py
Another package name fix
[wxWidgets.git] / wxPython / contrib / glcanvas / msw / glcanvas.py
CommitLineData
554f62e9 1# This file was created automatically by SWIG 1.3.29.
d14a1e28 2# Don't modify this file, modify the SWIG interface instead.
325274bb 3
caef1a4d
RD
4"""
5`GLCanvas` provides an OpenGL Context on a `wx.Window`.
6"""
7
d14a1e28 8import _glcanvas
554f62e9
RD
9import new
10new_instancemethod = new.instancemethod
093d3ff1 11def _swig_setattr_nondynamic(self,class_type,name,value,static=1):
554f62e9 12 if (name == "thisown"): return self.this.own(value)
093d3ff1 13 if (name == "this"):
554f62e9
RD
14 if type(value).__name__ == 'PySwigObject':
15 self.__dict__[name] = value
093d3ff1
RD
16 return
17 method = class_type.__swig_setmethods__.get(name,None)
18 if method: return method(self,value)
554f62e9 19 if (not static) or hasattr(self,name):
093d3ff1
RD
20 self.__dict__[name] = value
21 else:
22 raise AttributeError("You cannot add attributes to %s" % self)
23
24def _swig_setattr(self,class_type,name,value):
25 return _swig_setattr_nondynamic(self,class_type,name,value,0)
26
27def _swig_getattr(self,class_type,name):
554f62e9 28 if (name == "thisown"): return self.this.own()
093d3ff1
RD
29 method = class_type.__swig_getmethods__.get(name,None)
30 if method: return method(self)
31 raise AttributeError,name
32
554f62e9
RD
33def _swig_repr(self):
34 try: strthis = "proxy of " + self.this.__repr__()
35 except: strthis = ""
36 return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)
37
093d3ff1
RD
38import types
39try:
40 _object = types.ObjectType
41 _newclass = 1
42except AttributeError:
43 class _object : pass
44 _newclass = 0
45del types
46
47
48def _swig_setattr_nondynamic_method(set):
49 def set_attr(self,name,value):
554f62e9
RD
50 if (name == "thisown"): return self.this.own(value)
51 if hasattr(self,name) or (name == "this"):
093d3ff1
RD
52 set(self,name,value)
53 else:
54 raise AttributeError("You cannot add attributes to %s" % self)
55 return set_attr
56
57
d55e5bfc
RD
58import _core
59wx = _core
c24da6d6 60__docfilter__ = wx.__DocFilter(globals())
d55e5bfc 61class GLContext(_core.Object):
093d3ff1 62 """Proxy of C++ GLContext class"""
554f62e9
RD
63 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
64 __repr__ = _swig_repr
65 def __init__(self, *args, **kwargs):
97ab0f6a 66 """__init__(self, GLCanvas win, GLContext other=None) -> GLContext"""
554f62e9
RD
67 _glcanvas.GLContext_swiginit(self,_glcanvas.new_GLContext(*args, **kwargs))
68 __swig_destroy__ = _glcanvas.delete_GLContext
69 __del__ = lambda self : None;
423f194a 70 def SetCurrent(*args, **kwargs):
97ab0f6a 71 """SetCurrent(self, GLCanvas win)"""
423f194a
RD
72 return _glcanvas.GLContext_SetCurrent(*args, **kwargs)
73
2131d850 74_glcanvas.GLContext_swigregister(GLContext)
d03fd34d
RD
75cvar = _glcanvas.cvar
76GLCanvasNameStr = cvar.GLCanvasNameStr
d14a1e28
RD
77
78WX_GL_RGBA = _glcanvas.WX_GL_RGBA
79WX_GL_BUFFER_SIZE = _glcanvas.WX_GL_BUFFER_SIZE
80WX_GL_LEVEL = _glcanvas.WX_GL_LEVEL
81WX_GL_DOUBLEBUFFER = _glcanvas.WX_GL_DOUBLEBUFFER
82WX_GL_STEREO = _glcanvas.WX_GL_STEREO
83WX_GL_AUX_BUFFERS = _glcanvas.WX_GL_AUX_BUFFERS
84WX_GL_MIN_RED = _glcanvas.WX_GL_MIN_RED
85WX_GL_MIN_GREEN = _glcanvas.WX_GL_MIN_GREEN
86WX_GL_MIN_BLUE = _glcanvas.WX_GL_MIN_BLUE
87WX_GL_MIN_ALPHA = _glcanvas.WX_GL_MIN_ALPHA
88WX_GL_DEPTH_SIZE = _glcanvas.WX_GL_DEPTH_SIZE
89WX_GL_STENCIL_SIZE = _glcanvas.WX_GL_STENCIL_SIZE
90WX_GL_MIN_ACCUM_RED = _glcanvas.WX_GL_MIN_ACCUM_RED
91WX_GL_MIN_ACCUM_GREEN = _glcanvas.WX_GL_MIN_ACCUM_GREEN
92WX_GL_MIN_ACCUM_BLUE = _glcanvas.WX_GL_MIN_ACCUM_BLUE
93WX_GL_MIN_ACCUM_ALPHA = _glcanvas.WX_GL_MIN_ACCUM_ALPHA
d55e5bfc 94class GLCanvas(_core.Window):
093d3ff1 95 """Proxy of C++ GLCanvas class"""
554f62e9
RD
96 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc='The membership flag')
97 __repr__ = _swig_repr
98 def __init__(self, *args, **kwargs):
41f1cec7 99 """
a95a7133 100 __init__(self, Window parent, int id=-1, Point pos=DefaultPosition,
d03fd34d 101 Size size=DefaultSize, long style=0, String name=GLCanvasNameStr,
f460c29d 102 int attribList=None, Palette palette=wxNullPalette) -> GLCanvas
41f1cec7 103 """
554f62e9 104 _glcanvas.GLCanvas_swiginit(self,_glcanvas.new_GLCanvas(*args, **kwargs))
0122b7e3 105 self._setOORInfo(self)
423f194a 106
7f442096
RD
107 def SetCurrent(*args):
108 """
109 SetCurrent(self)
110 SetCurrent(self, GLContext RC)
111 """
112 return _glcanvas.GLCanvas_SetCurrent(*args)
423f194a
RD
113
114 def SetColour(*args, **kwargs):
a95a7133 115 """SetColour(self, String colour)"""
423f194a
RD
116 return _glcanvas.GLCanvas_SetColour(*args, **kwargs)
117
118 def SwapBuffers(*args, **kwargs):
a95a7133 119 """SwapBuffers(self)"""
423f194a
RD
120 return _glcanvas.GLCanvas_SwapBuffers(*args, **kwargs)
121
122 def GetContext(*args, **kwargs):
a95a7133 123 """GetContext(self) -> GLContext"""
423f194a
RD
124 return _glcanvas.GLCanvas_GetContext(*args, **kwargs)
125
126 def SetupPixelFormat(*args, **kwargs):
a95a7133 127 """SetupPixelFormat(self, int attribList=None)"""
423f194a
RD
128 return _glcanvas.GLCanvas_SetupPixelFormat(*args, **kwargs)
129
130 def SetupPalette(*args, **kwargs):
f460c29d 131 """SetupPalette(self, Palette palette)"""
423f194a
RD
132 return _glcanvas.GLCanvas_SetupPalette(*args, **kwargs)
133
134 def CreateDefaultPalette(*args, **kwargs):
f460c29d 135 """CreateDefaultPalette(self) -> Palette"""
423f194a
RD
136 return _glcanvas.GLCanvas_CreateDefaultPalette(*args, **kwargs)
137
138 def GetPalette(*args, **kwargs):
f460c29d 139 """GetPalette(self) -> Palette"""
423f194a
RD
140 return _glcanvas.GLCanvas_GetPalette(*args, **kwargs)
141
e70b4d2d 142 Context = property(GetContext,doc="See `GetContext`")
2131d850 143_glcanvas.GLCanvas_swigregister(GLCanvas)
325274bb 144
83448d71 145def GLCanvasWithContext(*args, **kwargs):
41f1cec7 146 """
83448d71 147 GLCanvasWithContext(Window parent, GLContext shared=None, int id=-1, Point pos=DefaultPosition,
41f1cec7 148 Size size=DefaultSize,
d03fd34d 149 long style=0, String name=GLCanvasNameStr,
f460c29d 150 int attribList=None, Palette palette=wxNullPalette) -> GLCanvas
41f1cec7 151 """
83448d71 152 val = _glcanvas.new_GLCanvasWithContext(*args, **kwargs)
d14a1e28 153 val._setOORInfo(val)
0122b7e3 154 return val
325274bb
RD
155
156
7449af73 157