equal
deleted
inserted
replaced
367 glEnable(GL_TEXTURE_2D); |
367 glEnable(GL_TEXTURE_2D); |
368 |
368 |
369 glBegin(GL_QUADS); |
369 glBegin(GL_QUADS); |
370 |
370 |
371 // top left |
371 // top left |
372 glTexCoord2f(0, 0); |
372 glTexCoord2i(0, 0); |
373 glVertex2f(0, 0); |
373 glVertex2i(X, Y); |
374 |
374 |
375 // top right |
375 // top right |
376 glTexCoord2f(1, 0); |
376 glTexCoord2i(1, 0); |
377 glVertex2f(1, 0); |
377 glVertex2i(2048 + X, Y); |
378 |
378 |
379 // bottom right |
379 // bottom right |
380 glTexCoord2f(1, 1); |
380 glTexCoord2i(1, 1); |
381 glVertex2f(1, 1); |
381 glVertex2i(2048 + X, 1024 + Y); |
382 |
382 |
383 // bottom left |
383 // bottom left |
384 glTexCoord2f(0, 1); |
384 glTexCoord2i(0, 1); |
385 glVertex2f(0, 1); |
385 glVertex2i(X, 1024 + Y); |
386 |
386 |
387 glEnd(); |
387 glEnd(); |
388 //DrawFromRect(X, Y, @r, LandSurface, Surface) |
388 //DrawFromRect(X, Y, @r, LandSurface, Surface) |
389 end; |
389 end; |
390 |
390 |
473 var aspect: real; |
473 var aspect: real; |
474 begin |
474 begin |
475 aspect:= cScreenWidth / cScreenHeight; |
475 aspect:= cScreenWidth / cScreenHeight; |
476 |
476 |
477 glViewport(0, 0, cScreenWidth, cScreenHeight); |
477 glViewport(0, 0, cScreenWidth, cScreenHeight); |
478 |
478 glScalef(2.0 / cScreenWidth, -2.0 / cScreenHeight, 1.0); |
|
479 glTranslatef(-cScreenWidth / 2, -cScreenHeight / 2, 0); |
479 //glMatrixMode(GL_PROJECTION); |
480 //glMatrixMode(GL_PROJECTION); |
480 //glLoadIdentity(); |
481 //glLoadIdentity(); |
481 |
482 |
482 //gluPerspective(60.0, aspect, 0.1, 100.0); |
483 //gluPerspective(60.0, aspect, 0.1, 100.0); |
483 |
484 |