tools/font2bmp.c
/* draw a char to surface dst */
draw a char to surface dst
draw a char to surface dst
int putc_(SDL_Surface *dst, int xoff, int yoff, int fy, int c, uint8_t r, uint8_t g, uint8_t b, uint8_t a) {
	int x, y, line_data;
	int off = c*fy;
	int posx, posy;
	for(y = 0; y < fy; y++) {
		line_data = buffer[off+y];
		for(x = 0; x < 8; x++) {
			if((line_data>>x) & 0x01) {
				posx = xoff+8-x;
				posy = yoff+y;
				pixelRGBA(dst, posx, posy, r, g, b, a);
			}
		}
	}
	return 0;	
}
int putc_ ( SDL_Surface * dst , int xoff , int yoff , int fy , int c , uint8_t r , uint8_t g , uint8_t b , uint8_t a ) { int x , y , line_data ; int off = c * fy ; int posx , posy ; for ( y = 0 ; y < fy ; y ++ ) { line_data = buffer [ off + y ] ; for ( x = 0 ; x < 8 ; x ++ ) { if ( ( line_data >> x ) & 0x01 ) { posx = xoff + 8 - x ; posy = yoff + y ; pixelRGBA ( dst , posx , posy , r , g , b , a ) ; } } } return 0 ; }
draw a char to surface dst
draw a char to surface dst