ansilove

ANSI and ASCII art to PNG converter in C
Log | Files | Refs | README | LICENSE

commit 0a6e850b5294a24d43d0c45907c2e6ad596cf6ff
parent 5be4df0ee220439f869e0fea6eb617c354150122
Author: ByteProject <stefan.vogt@byteproject.net>
Date:   Thu,  6 Mar 2014 20:21:17 +0100

updating version to 2.1.2

Diffstat:
Mansilove/ansilove.c | 23+++++++++++------------
1 file changed, 11 insertions(+), 12 deletions(-)

diff --git a/ansilove/ansilove.c b/ansilove/ansilove.c @@ -2214,7 +2214,7 @@ void alTundraLoader(char *input, char output[], char retinaout[], char font[], c } // read tundra file a first time to find the image size - int32_t character, color_background, color_foreground; + int32_t character, color_background = 0, color_foreground = 0; int32_t loop = 0, position_x = 0, position_y = 0; loop=9; @@ -2299,11 +2299,11 @@ void alTundraLoader(char *input, char output[], char retinaout[], char font[], c { position_y = (input_file_buffer[loop + 1] << 24) + (input_file_buffer[loop + 2] << 16) + - (input_file_buffer[loop + 3] << 8) + input_file_buffer[loop+4]; + (input_file_buffer[loop + 3] << 8) + input_file_buffer[loop + 4]; position_x = (input_file_buffer[loop + 5] << 24) + (input_file_buffer[loop + 6] << 16) + - (input_file_buffer[loop + 7] << 8) + input_file_buffer[loop+8]; + (input_file_buffer[loop + 7] << 8) + input_file_buffer[loop + 8]; loop+=8; } @@ -2311,8 +2311,8 @@ void alTundraLoader(char *input, char output[], char retinaout[], char font[], c if (character == 2) { color_foreground = - (input_file_buffer[loop + 2] << 24) + (input_file_buffer[loop + 3] << 16) + - (input_file_buffer[loop + 4] << 8) + input_file_buffer[loop+5]; + (input_file_buffer[loop + 3] << 16) + (input_file_buffer[loop + 4] << 8) + + input_file_buffer[loop + 5]; character = input_file_buffer[loop+1]; @@ -2321,9 +2321,8 @@ void alTundraLoader(char *input, char output[], char retinaout[], char font[], c if (character == 4) { - color_background = - (input_file_buffer[loop + 2] << 24) + (input_file_buffer[loop + 3] << 16) + - (input_file_buffer[loop + 4] << 8) + input_file_buffer[loop+5]; + color_background = (input_file_buffer[loop + 3] << 16) + (input_file_buffer[loop + 4] << 8) + + input_file_buffer[loop+5]; character = input_file_buffer[loop+1]; @@ -2333,12 +2332,12 @@ void alTundraLoader(char *input, char output[], char retinaout[], char font[], c if (character==6) { color_foreground = - (input_file_buffer[loop + 2] << 24) + (input_file_buffer[loop + 3] << 16) + - (input_file_buffer[loop + 4] << 8) + input_file_buffer[loop+5]; + (input_file_buffer[loop + 3] << 16) + (input_file_buffer[loop + 4] << 8) + + input_file_buffer[loop+5]; color_background = - (input_file_buffer[loop + 6] << 24) + (input_file_buffer[loop + 7] << 16) + - (input_file_buffer[loop + 8] << 8) + input_file_buffer[loop+9]; + (input_file_buffer[loop + 7] << 16) + (input_file_buffer[loop + 8] << 8) + + input_file_buffer[loop+9]; character = input_file_buffer[loop+1];