hedgewars/uMisc.pas
changeset 1916 9c3d0e3df6bb
parent 1912 c3d31fb59f0e
child 2000 f9f47e681aad
equal deleted inserted replaced
1915:c357f5b55320 1916:9c3d0e3df6bb
   495 head[7]:= cScreenHeight;
   495 head[7]:= cScreenHeight;
   496 
   496 
   497 size:= cScreenWidth * cScreenHeight * 3;
   497 size:= cScreenWidth * cScreenHeight * 3;
   498 p:= GetMem(size);
   498 p:= GetMem(size);
   499 
   499 
       
   500 {$IFDEF IPHONE}
       
   501 //since opengl es operates on a single surface GL_FRONT is implied, but how to test that?
       
   502 {$ELSE}
   500 glReadBuffer(GL_FRONT);
   503 glReadBuffer(GL_FRONT);
       
   504 {$ENDIF}
   501 glReadPixels(0, 0, cScreenWidth, cScreenHeight, GL_BGR, GL_UNSIGNED_BYTE, p);
   505 glReadPixels(0, 0, cScreenWidth, cScreenHeight, GL_BGR, GL_UNSIGNED_BYTE, p);
   502 
   506 
   503 {$I-}
   507 {$I-}
   504 Assign(f, s);
   508 Assign(f, s);
   505 Rewrite(f, 1);
   509 Rewrite(f, 1);