|
|
@ -69,7 +69,7 @@ get_linux_colormap(int fd){
|
|
|
|
//
|
|
|
|
//
|
|
|
|
// height * rowbytes, where rowbytes = width + 7 / 8
|
|
|
|
// height * rowbytes, where rowbytes = width + 7 / 8
|
|
|
|
static int
|
|
|
|
static int
|
|
|
|
explode_glyph_row(const unsigned char** row, unsigned width){
|
|
|
|
explode_glyph_row(unsigned char** row, unsigned width){
|
|
|
|
unsigned char mask = 0x80;
|
|
|
|
unsigned char mask = 0x80;
|
|
|
|
while(width--){
|
|
|
|
while(width--){
|
|
|
|
printf("%s", **row & mask ? "*" : " ");
|
|
|
|
printf("%s", **row & mask ? "*" : " ");
|
|
|
@ -110,7 +110,7 @@ get_linux_consolefont(int fd, unsigned showglyphs){
|
|
|
|
// FIXME get real screen width
|
|
|
|
// FIXME get real screen width
|
|
|
|
const int atonce = 80 / (cfo.width + 1);
|
|
|
|
const int atonce = 80 / (cfo.width + 1);
|
|
|
|
const int Bper = 64;
|
|
|
|
const int Bper = 64;
|
|
|
|
const unsigned char* g[atonce];
|
|
|
|
unsigned char** g = malloc(sizeof(*g) * atonce);
|
|
|
|
for(unsigned i = 0 ; i < cfo.charcount ; i += atonce){
|
|
|
|
for(unsigned i = 0 ; i < cfo.charcount ; i += atonce){
|
|
|
|
for(int o = 0 ; o < atonce ; ++o){
|
|
|
|
for(int o = 0 ; o < atonce ; ++o){
|
|
|
|
g[o] = (unsigned char*)cfo.data + Bper * (i + o);
|
|
|
|
g[o] = (unsigned char*)cfo.data + Bper * (i + o);
|
|
|
@ -122,6 +122,7 @@ get_linux_consolefont(int fd, unsigned showglyphs){
|
|
|
|
printf("\n");
|
|
|
|
printf("\n");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
free(g);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
free(cfo.data);
|
|
|
|
free(cfo.data);
|
|
|
|
return 0;
|
|
|
|
return 0;
|
|
|
|