PDA

View Full Version : latest forceware (81.xx +) and glut problems



Chris Lux
02-26-2006, 11:22 AM
hi,
i noticed strange behavior with latest forceware dirvers on GeForce7800GTX boards (256 and 512MB version).

i did a test with glut (and freeglut) with the display loop below. the cube starts spinning, but not very fast. from time to time the whole gl rendering freezes but the display loop is actually executed. i also can quit the program properly. other times the cube starts slow but then after some time accellerates so the expected framerate.

i find this very strange. because i use an dual core cpu i tried disabling the dual core usage through the registry setting Ogl_ThreadControl but this did not change the situation. i also tried to set the process affinity to one cpu only in the taskmanager also without any affect.

has anyone observed that kind of behavior?

my systems:
winXP sp2
visual studio 2005 (c++)
Athlon64 x2 4400+
2gb ram
geforce7800gtx 256MB
forceware 81.98 -> 83.90

winxp sp2
visual studio 2005 (c++)
Athlon64 x2 4800+
2gb ram
geforce7800gtx 512MB
forceware 81.98 -> 83.90

latest glut and freeglut testet.



void display()
{
static float angl = 0.0f;

glClear(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT);

glColor4f(0,0.9f,0.5f,1);

glPushMatrix();
glRotatef(angl, 1,1,1);
glutSolidCube(10);
glPopMatrix();

glutSwapBuffers();

angl += 0.1f;
}once i also had the same problem using quake4, so this can be completely opengl related.

dorbie
02-26-2006, 09:26 PM
Sounds like it may be some kind of hardware issue.

Make sure your board is seated properly, and perhaps try/demo a posisble replacement (Fry's is your friend).

Chris Lux
02-27-2006, 01:41 AM
nope it is not the hardware, as is tried it on 2 different systems.

i thinkit is a synchronisation issue of the forceware drivers, because if i do a Sleep(40) in the display loop all is fine and as expected.

here the full test app:

#include <windows.h> // Standard Header For Most Programs
#include <gl/gl.h> // The GL Header File
#include <gl/glut.h> // The GL Utility Toolkit (Glut) Header

float rtri; // Angle For The Triangle
float rquad; // Angle For The Quad

void init()
{
glPixelStorei(GL_UNPACK_ALIGNMENT,1);
glPixelStorei(GL_PACK_ALIGNMENT,1);

glClearColor(0.2f,0.2f,0.2f,1);
glDepthFunc(GL_LESS);
glEnable(GL_DEPTH_TEST);
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
}

void display()
{
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glLoadIdentity();
glPushMatrix();
glTranslatef(-1.5f,0.0f,-6.0f);
glRotatef(rtri,0.0f,1.0f,0.0f);
glBegin(GL_TRIANGLES);
glColor3f(1.0f,0.0f,0.0f);
glVertex3f( 0.0f, 1.0f, 0.0f);
glColor3f(0.0f,1.0f,0.0f);
glVertex3f(-1.0f,-1.0f, 0.0f);
glColor3f(0.0f,0.0f,1.0f);
glVertex3f( 1.0f,-1.0f, 0.0f);
glEnd();

glLoadIdentity();
glTranslatef(1.5f,0.0f,-6.0f);
glRotatef(rquad,1.0f,0.0f,0.0f);
glColor3f(0.5f,0.5f,1.0f);
glBegin(GL_QUADS);
glVertex3f(-1.0f, 1.0f, 0.0f);
glVertex3f( 1.0f, 1.0f, 0.0f);
glVertex3f( 1.0f,-1.0f, 0.0f);
glVertex3f(-1.0f,-1.0f, 0.0f);
glEnd();
glPopMatrix();
rtri+=0.2f;
rquad-=0.15f;


glutSwapBuffers();
}

void reshape(int w, int h)
{
glViewport(0, 0, w, h);
glMatrixMode(GL_PROJECTION);
glLoadIdentity();
//gluPerspective(60.f, 1.0f, 1.f, 100.f);
gluPerspective ( 60, ( float ) w / ( float ) h, 1.0, 20.0 );
glMatrixMode(GL_MODELVIEW);
}

void idle()
{
glutPostRedisplay();
}

void main(int argc, char** argv)
{
glutInit(&amp;argc,argv);

glutInitDisplayMode(GLUT_DOUBLE | GLUT_DEPTH | GLUT_RGBA | GLUT_ALPHA);
//glutInitDisplayMode ( GLUT_RGB | GLUT_DOUBLE );

glutInitWindowSize(512, 512);
glutCreateWindow("test");

init();

glutDisplayFunc(display);
glutReshapeFunc(reshape);
glutIdleFunc(idle);

glutMainLoop();
}it is derived from the nehe lesson04.

i also found out, that when i initialize the window only with GLUT_RGB | GLUT_DOUBLE all is fine.

i have to say the issue only occures once on five trials, but i think this can be described as reproducable.

sometimes, when resizing the window the framerate does not change (vsynch is OFF). i find these things VERY strange.

ALSO, when the geometry moves stuttery there is light hiss on the speakers connected to the computer, when suddenly the movement of the scene is smooth the hiss is gone (also on both systems!).

i could reproduce this issue only once with the original win32 nehe lesson04 (the original one without glut), but this confirms that it is there.