parent
98a4690ec1
commit
9c561f7bf5
1
AUTHORS
1
AUTHORS
|
@ -26,3 +26,4 @@ Renchi Raju <renchi@pooh.tam.uiuc.edu>
|
|||
Yuri Hudobin <glassy_ape@users.sourceforge.net>
|
||||
Radoslaw Grzanka <radekg2@poczta.onet.pl>
|
||||
Kim Woelders <kim@woelders.dk>
|
||||
Nick Blievers <nickb@sgi.com>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# include <config.h>
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
#include <bzlib.h>
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
|
|
|
@ -245,7 +245,7 @@ load(ImlibImage * im, ImlibProgressFunction progress,
|
|||
|
||||
filedata = seg;
|
||||
header = (tga_header *) filedata;
|
||||
footer = (tga_footer *) (filedata + ss.st_size - sizeof(tga_footer));
|
||||
footer = (tga_footer *) ((char *)filedata + ss.st_size - sizeof(tga_footer));
|
||||
|
||||
/* check the footer to see if we have a v2.0 TGA file */
|
||||
if (memcmp(footer->signature, TGA_SIGNATURE, sizeof(footer->signature)) == 0)
|
||||
|
@ -256,11 +256,11 @@ load(ImlibImage * im, ImlibProgressFunction progress,
|
|||
}
|
||||
|
||||
/* skip over header */
|
||||
filedata += sizeof(tga_header);
|
||||
|
||||
filedata = (char *)filedata + sizeof(tga_header);
|
||||
|
||||
/* skip over alphanumeric ID field */
|
||||
if (header->idLength)
|
||||
filedata += header->idLength;
|
||||
filedata = (char *)filedata + header->idLength;
|
||||
|
||||
/* now parse the header */
|
||||
|
||||
|
|
14
src/api.c
14
src/api.c
|
@ -185,18 +185,20 @@ imlib_context_new(void)
|
|||
context->font = NULL;
|
||||
context->direction = IMLIB_TEXT_TO_RIGHT;
|
||||
context->angle = 0.0;
|
||||
context->color = (Imlib_Color)
|
||||
{
|
||||
255, 255, 255, 255};
|
||||
context->color.alpha = 255;
|
||||
context->color.red = 255;
|
||||
context->color.green = 255;
|
||||
context->color.blue = 255;
|
||||
context->color_range = NULL;
|
||||
context->image = NULL;
|
||||
context->progress_func = NULL;
|
||||
context->progress_granularity = 0;
|
||||
context->dither_mask = 0;
|
||||
context->filter = NULL;
|
||||
context->cliprect = (Imlib_Rectangle)
|
||||
{
|
||||
0, 0, 0, 0};
|
||||
context->cliprect.x = 0;
|
||||
context->cliprect.y = 0;
|
||||
context->cliprect.w = 0;
|
||||
context->cliprect.h = 0;
|
||||
context->encoding = IMLIB_TTF_ENCODING_ISO_8859_1;
|
||||
|
||||
context->references = 0;
|
||||
|
|
Loading…
Reference in New Issue