Hello,
This is the code which i have written
void GLFWCALL reshape(int width,int height)
{
glViewport(0,0,width,height);
//GLfloat mat[4][4]={0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
GLfloat mat[16];
glMatrixMode(GL_PROJECTION);
glLoadIdentity();
glGetFloatv(GL_PROJECTION,mat);
glFrustum(0.0,(GLdouble)width,0.0,(GLdouble)height,1.0,7.0);
glMatrixMode(GL_MODELVIEW);
}
The function glGetFloatv is returning matrix having garbage value.
I have tried initializing the matrix mat to 0,in that case it is returning 0.
What is wrong with this code?