472,123 Members | 1,481 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,123 software developers and data experts.

How to setup pyOpenGL3.0.a6 for window xp?

Hi,
I've already download the pyOpenGL3..0.a6 for python2.4 and installed
python2.4,

Is it necessary to install OpenGL? And if need, which version of
OpenGL should be
installed?

Thanks!

Aug 18 '07 #1
5 1197
On Aug 17, 8:07 pm, math2life <QJing...@gmail.comwrote:
Hi,
I've already download the pyOpenGL3..0.a6 for python2.4 and installed
python2.4,

Is it necessary to install OpenGL? And if need, which version of
OpenGL should be
installed?
Windows comes with OpenGL libraries. However, before you can use
OpenGL you'll need a package that can provide an OpenGL context, which
PyOpenGL doesn't do (easily).

PyGame is the typical choice for most uses. If all you need is a
simple window to draw on, this is the package you want.

However, it doesn't (easily) work with common GUIs like GTK and Wx.
If you want to use use OpenGL in a GUI app, then you'll want to find
an "OpenGL canvas widget" for that GUI.
Carl Banks

Aug 18 '07 #2
On Aug 17, 5:42 pm, Carl Banks <pavlovevide...@gmail.comwrote:
On Aug 17, 8:07 pm, math2life <QJing...@gmail.comwrote:
Hi,
I've already download the pyOpenGL3..0.a6 for python2.4 and installed
python2.4,
Is it necessary to install OpenGL? And if need, which version of
OpenGL should be
installed?

Windows comes with OpenGL libraries. However, before you can use
OpenGL you'll need a package that can provide an OpenGL context, which
PyOpenGL doesn't do (easily).

PyGame is the typical choice for most uses. If all you need is a
simple window to draw on, this is the package you want.

However, it doesn't (easily) work with common GUIs like GTK and Wx.
If you want to use use OpenGL in a GUI app, then you'll want to find
an "OpenGL canvas widget" for that GUI.

Carl Banks
ye!I made it.
The OpenGL context should be pre-installed.

I want PyOpenGL can work with Wx, but it is good idea to start with
PyGame for the newbie to OpenGL.

Thank you , Carl

Aug 18 '07 #3
On Aug 17, 6:42 pm, Carl Banks <pavlovevide...@gmail.comwrote:
Windows comes with OpenGL libraries. However, before you can use
OpenGL you'll need a package that can provide an OpenGL context, which
PyOpenGL doesn't do (easily).

PyGame is the typical choice for most uses. If all you need is a
simple window to draw on, this is the package you want.

However, it doesn't (easily) work with common GUIs like GTK and Wx.
If you want to use use OpenGL in a GUI app, then you'll want to find
an "OpenGL canvas widget" for that GUI.

Carl Banks
Sorry Carl, but I'm a bit confused with your third paragraph. Do you
mean that PyGame doesn't work easily with Wx/GTK, or that OpenGL
doesn't work easily with Wx/GTK?

If it's the second, then I must disagree. wxPython comes with an
OpenGL widget in the "wx.glcanvas" module. The widget only requires
PyOpenGL. The wxPython Demo shows how to set up and program the
widget quite easily. Another example is at: "http://
aspn.activestate.com/ASPN/Cookbook/Python/Recipe/325392".

Unfortunately, I don't have much experience with PyGTK. Their FAQ
does indicate that you need an extension to add OpenGL support.

--Jason

Aug 19 '07 #4
Jason wrote:
On Aug 17, 6:42 pm, Carl Banks <pavlovevide...@gmail.comwrote:
>Windows comes with OpenGL libraries. However, before you can use
OpenGL you'll need a package that can provide an OpenGL context, which
PyOpenGL doesn't do (easily).

PyGame is the typical choice for most uses. If all you need is a
simple window to draw on, this is the package you want.
If you want an *easy* way to create an OpenGL window and context, you
could try FLTK, and it's Python wrapper PyFLTK. It's a simple (nice,
very small, well featured and consistent) widget toolkit with OpenGL
support. Once the window is open, PyOpenGL (versions 2xx or 3xx) work
perfectly on the window.

See http://www.fltk.org/

Gary Herron
>However, it doesn't (easily) work with common GUIs like GTK and Wx.
If you want to use use OpenGL in a GUI app, then you'll want to find
an "OpenGL canvas widget" for that GUI.

Carl Banks

Sorry Carl, but I'm a bit confused with your third paragraph. Do you
mean that PyGame doesn't work easily with Wx/GTK, or that OpenGL
doesn't work easily with Wx/GTK?

If it's the second, then I must disagree. wxPython comes with an
OpenGL widget in the "wx.glcanvas" module. The widget only requires
PyOpenGL. The wxPython Demo shows how to set up and program the
widget quite easily. Another example is at: "http://
aspn.activestate.com/ASPN/Cookbook/Python/Recipe/325392".

Unfortunately, I don't have much experience with PyGTK. Their FAQ
does indicate that you need an extension to add OpenGL support.

--Jason

Aug 19 '07 #5
Gary Herron wrote:
Jason wrote:
>On Aug 17, 6:42 pm, Carl Banks <pavlovevide...@gmail.comwrote:
>>Windows comes with OpenGL libraries. However, before you can use
OpenGL you'll need a package that can provide an OpenGL context, which
PyOpenGL doesn't do (easily).

PyGame is the typical choice for most uses. If all you need is a
simple window to draw on, this is the package you want.
If you want an *easy* way to create an OpenGL window and context, you
could try FLTK, and it's Python wrapper PyFLTK.
The simplest method by far uses pyglet from http://www.pyglet.org/

from pyglet import window
w = window.Window(200, 200)
while not w.has_exit:
w.dispatch_events()
... do OpenGL stuff

pyglet has no compilation and no dependencies and works on Linux, OS X and
Windows. You can use PyOpenGL with it just fine, or use its own gl layer
(which is intentionally less pythonic)
Richard

Aug 19 '07 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

6 posts views Thread by Joăo Santa Bárbara | last post: by
3 posts views Thread by Richard L Rosenheim | last post: by
reply views Thread by Deemar | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.