[PyOpenGL-Users] Multisampling for antialiasing inside OpenGL.Tk.Opengl
Brought to you by:
mcfletch
From: Robin F. <rob...@gm...> - 2005-12-30 00:28:24
|
I'd like to get multisampling working in my current 3D project. It is currently based on the Opengl class found in the OpenGL.Tk module. I have hunted round in the PyOpenGL modules, and found likely looking modules under OpenGL.GL.ARB.multisample and OpenGL.WGL.ARB.multisample. I have got to the stage where I can call either glInitMultisampleARB() or wglInitMultisampleARB() and get a return value of 1, and the string 'GL_ARB_multisample' appears in the GL_EXTENSIONS string returned from glGetString(). I understand that it is not as simple as just calling glEnable(GL_MULTISAMPLE_ARB), and that I need to set up the correct pixelformats first? I am unsure where and how I should do this since up until now I have just used the Tk Opengl widget. Where is it all going wrong? I can see several possibilities: 1. My OpenGL implementation is as far as I know the bog standard microsoft 1.1 version - do I need to update this or can I get at the ARB routines for my hardware through the extensions? 2. Is the Tk widget (based on Togl I think) incapable of handling extensions? If so, then how else can I get an OpenGL canvas to draw on and yet still surround it with Tk buttons and so on? 3. I just need to setup pixel formats correctly somewhere in what I have got so far. Any help on where to start would be much appreciated. |