-
driver problem?
hello all
I have a very easy to describe problem
the following code executes without problems and does what i expect to do in an old laptop of mine, runing win xp
When i run it in my new desktop pc (i7 win7 64bit 8Gb ram) with a NVIDIA Quadro FX 580 graphics card,
when executing glDrawArrays, i get
"0xC0000005: Access violation reading location 0x00000000."
code:
glEnableClientState(GL_VERTEX_ARRAY);
glEnableClientState(GL_NORMAL_ARRAY);
glEnableClientState(GL_TEXTURE_COORD_ARRAY);
glBindTexture(GL_TEXTURE_2D,quadTexture);
glVertexPointer(3,GL_FLOAT,0,&quadVertexesArray[0]);
glNormalPointer(3,0,&quadNormalsArray[0]);
glTexCoordPointer(2,GL_FLOAT,0,&quadTexCoordArray[0]);
glDrawArrays(GL_QUADS,0,noOfQuads*4);//0xC0000005: Access violation reading location 0x00000000.
glDisableClientState(GL_TEXTURE_COORD_ARRAY);
glDisableClientState(GL_NORMAL_ARRAY);
glDisableClientState(GL_VERTEX_ARRAY);
the pointers where initialised using:
quadNormalsArray =(GLfloat *) malloc(sizeof(GLfloat)*quads.count()*3);
quadVertexesArray=(GLfloat *) malloc(sizeof(GLfloat)*quads.count()*3*4);
quadTexCoordArray=(GLfloat *) malloc(sizeof(GLfloat)*quads.count()*2*4);
and
quadNormalsArray=new GLfloat[quads.count()*3];
quadVertexesArray=new GLfloat[quads.count()*3*4];
quadTexCoordArray=new GLfloat[quads.count()*2*4];
with the same result (0xC0000005: Access violation reading location 0x00000000.)
i suspect a driver problem
i have downloaded the latest driver but i get the same....
any idea of what to look for?
i use the latest Qt library and the a QGLWidget (if this is relevant in any way)
thank you for your time
george
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules