Re: Difficulty with the shaders tutorial

Ian Mallett <[email protected]>
Newsgroups gmane.comp.python.opengl.user
Message-ID <CAG4NV=spEVsOo0CvYFVinc6sFonNhuAbLqfgpuNjd0ggV9Ffww@mail.gmail.com>
On Thu, Feb 16, 2012 at 12:09 PM, Derakon <[email protected]> wrote:

> On further investigation, those functions weren't available because I
> didn't have an OpenGL context yet. My bad. Moving the set-up to later
> on in the program (the first paint call) instead gives these errors:
>
> RuntimeError: ('Shader compile failure (0): 0(3) : error C7533: global
> variable gl_ModelViewProjectionMatrix is deprecated after version
> 120\n0(3) : error C7533: global variable gl_Vertex is deprecated after
> version 120\n', ['#version 330\n            void main() {\n
>    gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;\n
>  }'], GL_VERTEX_SHADER)
>
> Feel free to correct me, but it looks like this means that the
> tutorial is using deprecated concepts? GL_VERSION is 3.3.0 and
> GL_SHADER_VERSION is "3.30 NVIDIA via Cg compiler", for what it's
> worth.

In later versions of OpenGL, the hardware matrix support was dropped.  I
think this is a mistake.  But the practical upshot is, to make your code
work, try using something like "#version 120" or something.
Ian

------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/

_______________________________________________
PyOpenGL Homepage
http://pyopengl.sourceforge.net
_______________________________________________
PyOpenGL-Users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pyopengl-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.