title: How to rotate my object with the light in opengl
body: <p>In my code, I cannot set cordinate the lighting according to the object so I cannot with fixed my lighting on the object which moves. How can i move the light with the objects </p>
  
  <p>I have an objet that is in the 0,0,-15 position and When I press the up down right left buttons , this object moving with the light which is lamb object. Yet, although I put the light(lamb object) 0,0,-15 position and give move_x and move_z cordinates as a position of light , the light is appeared in the different place and it is moving unlinked with my object. this is my code : </p>
  
  <pre><code>            glTranslatef(move_x,0,move_y);
              float l0_pos_temp[] = {move_x   ,-3, move_y  ,1} ;
              glLightfv( GL_LIGHT0, GL_POSITION, l0_pos_temp ) ;
              glTranslatef(0,-3,0);
              Light();
          glPopMatrix();
  </code></pre>