Sfoglia il codice sorgente

* Improved GL rendering (characters are not blurry anymore)

tags/v0.99.beta14
Jean-Yves Lamoureux jylam 19 anni fa
parent
commit
43c29676eb
1 ha cambiato i file con 7 aggiunte e 3 eliminazioni
  1. +7
    -3
      src/graphics.c

+ 7
- 3
src/graphics.c Vedi File

@@ -274,6 +274,10 @@ unsigned char gl_key = 0;
int gl_special_key = 0; int gl_special_key = 0;
int gl_new_width; int gl_new_width;
int gl_new_height; int gl_new_height;

float gl_sw = 9.0f/16.0f;
float gl_sh = 15.0f/16.0f;

#endif #endif


static char *_caca_empty_line; static char *_caca_empty_line;
@@ -1545,11 +1549,11 @@ void caca_refresh(void)


glColor3f(fr, fg, fb); glColor3f(fr, fg, fb);
glBegin(GL_QUADS); glBegin(GL_QUADS);
glTexCoord2f(0, 1);
glTexCoord2f(0, gl_sh);
glVertex2f(x, y); glVertex2f(x, y);
glTexCoord2f(0.5, 1);
glTexCoord2f(gl_sw, gl_sh);
glVertex2f(x + gl_font_width, y); glVertex2f(x + gl_font_width, y);
glTexCoord2f(0.5, 0);
glTexCoord2f(gl_sw, 0);
glVertex2f(x + gl_font_width, y + gl_font_height); glVertex2f(x + gl_font_width, y + gl_font_height);
glTexCoord2f(0, 0); glTexCoord2f(0, 0);
glVertex2f(x, y + gl_font_height); glVertex2f(x, y + gl_font_height);


Caricamento…
Annulla
Salva