diff options
author | pajoye <none@none> | 2007-11-03 10:41:29 +0000 |
---|---|---|
committer | pajoye <none@none> | 2007-11-03 10:41:29 +0000 |
commit | a17152c438dbb44ce7c76ed5fd47c610217fb640 (patch) | |
tree | 5b966e427e85705cd7364ffdbd9aa15748dbd31b /src/gd_tga.c | |
parent | 1d88ed50729dad7d5b606f547b273a4c1cb47a94 (diff) | |
download | libgd-a17152c438dbb44ce7c76ed5fd47c610217fb640.tar.gz |
- #122, tga, add support for image flip (tga images can be stored
fliped)
Diffstat (limited to 'src/gd_tga.c')
-rw-r--r-- | src/gd_tga.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/gd_tga.c b/src/gd_tga.c index f0765a5..180e975 100644 --- a/src/gd_tga.c +++ b/src/gd_tga.c @@ -102,16 +102,15 @@ BGD_DECLARE(gdImagePtr) gdImageCreateFromTgaCtx(gdIOCtx* ctx) } } } -/* TODO: enable this part as soon as the flip functions have been commited*/ -#if 0 + if (tga->flipv && tga->fliph) { - gdImageFlip(image, GD_FLIP_BOTH); + gdImageFlipBoth(image); } else if (tga->flipv) { - gdImageFlip(image, GD_FLIP_HORIZONTAL); + gdImageFlipHorizontal(image); } else if (tga->fliph) { - gdImageFlip(image, GD_FLIP_VERTICAL); + gdImageFlipVertical(image); } -#endif + free_tga(tga); return image; |