"Fossies" - the Fresh Open Source Software Archive

Member "libgd-2.3.2/tests/gif/gif_nocolormaps.c" (3 Mar 2021, 578 Bytes) of package /linux/www/libgd-2.3.2.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file.

    1 /**
    2  * Ensure that a GIF without any Global or Local color tables is still decoded
    3  *
    4  * GIF89a spec indicates conforming image files need not have Global or Local color tables at all
    5  *
    6  * See also:    https://www.w3.org/Graphics/GIF/spec-gif89a.txt
    7  *      http://probablyprogramming.com/2009/03/15/the-tiniest-gif-ever
    8  */
    9 
   10 #include "gd.h"
   11 #include "gdtest.h"
   12 
   13 int main()
   14 {
   15     gdImagePtr im;
   16     FILE *fp;
   17 
   18     fp = gdTestFileOpen2("gif", "gif_nocolormaps.gif");
   19     gdTestAssert(fp != NULL);
   20     im = gdImageCreateFromGif(fp);
   21     gdTestAssert(im != NULL);
   22     fclose(fp);
   23 
   24     return gdNumFailures();
   25 }