void setMaterial(const GLfloat mat_diffuse[4],GLfloat mat_shininess){static const GLfloat mat_specular[]={0.0f,0.0f,0.0f,1.0f};static const GLfloat mat_emission[]={0.0f,0.0f,0.0f,1.0f}; glMaterialfv(GL_FRONT,GL_AMBIENT_AND_DIFFUSE,mat_diffuse);glMate…