]> git.saurik.com Git - wxWidgets.git/blame - wxPython/contrib/glcanvas/mac/glcanvas.py
new encoding constants
[wxWidgets.git] / wxPython / contrib / glcanvas / mac / glcanvas.py
CommitLineData
e6056257 1# This file was created automatically by SWIG.
d14a1e28 2# Don't modify this file, modify the SWIG interface instead.
e6056257 3
d14a1e28 4import _glcanvas
e6056257 5
d14a1e28
RD
6import core
7wx = core
8class GLContext(core.Object):
423f194a
RD
9 def __repr__(self):
10 return "<%s.%s; proxy of C++ wxGLContext instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 11 def __init__(self, *args, **kwargs):
41f1cec7
RD
12 """
13 __init__(bool isRGB, GLCanvas win, wxPalette palette=wxNullPalette,
14 GLContext other=None) -> GLContext
15 """
d14a1e28
RD
16 newobj = _glcanvas.new_GLContext(*args, **kwargs)
17 self.this = newobj.this
18 self.thisown = 1
19 del newobj.thisown
20 def __del__(self, destroy=_glcanvas.delete_GLContext):
423f194a 21 """__del__()"""
d14a1e28
RD
22 try:
23 if self.thisown: destroy(self)
24 except: pass
423f194a
RD
25
26 def SetCurrent(*args, **kwargs):
27 """SetCurrent()"""
28 return _glcanvas.GLContext_SetCurrent(*args, **kwargs)
29
30 def SetColour(*args, **kwargs):
cbd72d4f 31 """SetColour(String colour)"""
423f194a
RD
32 return _glcanvas.GLContext_SetColour(*args, **kwargs)
33
34 def SwapBuffers(*args, **kwargs):
35 """SwapBuffers()"""
36 return _glcanvas.GLContext_SwapBuffers(*args, **kwargs)
37
38 def GetWindow(*args, **kwargs):
39 """GetWindow() -> Window"""
40 return _glcanvas.GLContext_GetWindow(*args, **kwargs)
41
e6056257 42
d14a1e28
RD
43class GLContextPtr(GLContext):
44 def __init__(self, this):
e6056257 45 self.this = this
d14a1e28
RD
46 if not hasattr(self,"thisown"): self.thisown = 0
47 self.__class__ = GLContext
48_glcanvas.GLContext_swigregister(GLContextPtr)
cbd72d4f
RD
49cvar = _glcanvas.cvar
50GLCanvasNameStr = cvar.GLCanvasNameStr
d14a1e28
RD
51
52WX_GL_RGBA = _glcanvas.WX_GL_RGBA
53WX_GL_BUFFER_SIZE = _glcanvas.WX_GL_BUFFER_SIZE
54WX_GL_LEVEL = _glcanvas.WX_GL_LEVEL
55WX_GL_DOUBLEBUFFER = _glcanvas.WX_GL_DOUBLEBUFFER
56WX_GL_STEREO = _glcanvas.WX_GL_STEREO
57WX_GL_AUX_BUFFERS = _glcanvas.WX_GL_AUX_BUFFERS
58WX_GL_MIN_RED = _glcanvas.WX_GL_MIN_RED
59WX_GL_MIN_GREEN = _glcanvas.WX_GL_MIN_GREEN
60WX_GL_MIN_BLUE = _glcanvas.WX_GL_MIN_BLUE
61WX_GL_MIN_ALPHA = _glcanvas.WX_GL_MIN_ALPHA
62WX_GL_DEPTH_SIZE = _glcanvas.WX_GL_DEPTH_SIZE
63WX_GL_STENCIL_SIZE = _glcanvas.WX_GL_STENCIL_SIZE
64WX_GL_MIN_ACCUM_RED = _glcanvas.WX_GL_MIN_ACCUM_RED
65WX_GL_MIN_ACCUM_GREEN = _glcanvas.WX_GL_MIN_ACCUM_GREEN
66WX_GL_MIN_ACCUM_BLUE = _glcanvas.WX_GL_MIN_ACCUM_BLUE
67WX_GL_MIN_ACCUM_ALPHA = _glcanvas.WX_GL_MIN_ACCUM_ALPHA
68class GLCanvas(core.Window):
423f194a
RD
69 def __repr__(self):
70 return "<%s.%s; proxy of C++ wxGLCanvas instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,)
d14a1e28 71 def __init__(self, *args, **kwargs):
41f1cec7
RD
72 """
73 __init__(Window parent, int id=-1, Point pos=DefaultPosition,
cbd72d4f
RD
74 Size size=DefaultSize, long style=0, String name=GLCanvasNameStr,
75 int attribList=None, wxPalette palette=wxNullPalette) -> GLCanvas
41f1cec7 76 """
d14a1e28
RD
77 newobj = _glcanvas.new_GLCanvas(*args, **kwargs)
78 self.this = newobj.this
e6056257 79 self.thisown = 1
d14a1e28 80 del newobj.thisown
e6056257 81 self._setOORInfo(self)
423f194a
RD
82
83 def SetCurrent(*args, **kwargs):
84 """SetCurrent()"""
85 return _glcanvas.GLCanvas_SetCurrent(*args, **kwargs)
86
87 def SetColour(*args, **kwargs):
cbd72d4f 88 """SetColour(String colour)"""
423f194a
RD
89 return _glcanvas.GLCanvas_SetColour(*args, **kwargs)
90
91 def SwapBuffers(*args, **kwargs):
92 """SwapBuffers()"""
93 return _glcanvas.GLCanvas_SwapBuffers(*args, **kwargs)
94
95 def GetContext(*args, **kwargs):
96 """GetContext() -> GLContext"""
97 return _glcanvas.GLCanvas_GetContext(*args, **kwargs)
98
e6056257 99
d14a1e28
RD
100class GLCanvasPtr(GLCanvas):
101 def __init__(self, this):
102 self.this = this
103 if not hasattr(self,"thisown"): self.thisown = 0
104 self.__class__ = GLCanvas
105_glcanvas.GLCanvas_swigregister(GLCanvasPtr)
e6056257 106
d14a1e28 107def wxGLCanvasWithContext(*args, **kwargs):
41f1cec7
RD
108 """
109 wxGLCanvasWithContext(Window parent, GLContext shared=None, int id=-1, Point pos=DefaultPosition,
110 Size size=DefaultSize,
cbd72d4f 111 long style=0, String name=GLCanvasNameStr,
41f1cec7
RD
112 int attribList=None, wxPalette palette=wxNullPalette) -> GLCanvas
113 """
d14a1e28 114 val = _glcanvas.new_wxGLCanvasWithContext(*args, **kwargs)
e6056257 115 val.thisown = 1
d14a1e28 116 val._setOORInfo(val)
e6056257
RD
117 return val
118
119