tga: fix flip/reflect

front
ftrvxmtrx 2013-01-22 17:02:31 +01:00
parent 54b62fe493
commit 8e7a00e143
1 changed files with 2 additions and 2 deletions

View File

@ -473,9 +473,9 @@ Breadtga(Biobuf *bp)
werrstr("ReadTGA: decode fail (%d!=%d) - %r\n", n, num);
goto Error;
}
if(h->xorigin != 0)
if((h->descriptor&(1<<4)) != 0)
reflect(ar);
if(h->yorigin == 0)
if((h->descriptor&(1<<5)) == 0)
flip(ar);
free(h);