Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3110 in orxonox.OLD for orxonox/branches/images/importer/material.cc


Ignore:
Timestamp:
Dec 6, 2004, 1:11:56 AM (19 years ago)
Author:
bensch
Message:

orxonox/branches/images: test for jpeg and png libs in configure.ac and material.cc/h

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/branches/images/importer/material.cc

    r3108 r3110  
    564564bool Material::loadJPG (char* jpgName, GLuint* texture)
    565565{
     566#ifdef HAVE_JPEGLIB_H
    566567  struct jpeg_decompress_struct cinfo;
    567568  Image *pImage = NULL;
     
    649650    }
    650651  return true;
     652#else /* HAVE_JPEGLIB_H */
     653  if (verbose >=1)
     654    printf ("sorry, but you did not compile with jpeg-support.\nEither install SDL_image or jpeglib, and recompile to see the image\n");
     655  return false;
     656#endif /* HAVE_JPEGLIB_H */
     657
    651658}
    652659
     
    980987bool Material::loadPNG(const char* pngName, GLuint* texture)
    981988{
     989#ifdef HAVE_PNG_H
    982990  Image* pImage = new Image;
    983991
     
    10991107 
    11001108  return true;
     1109#else /* HAVE_PNG_H */
     1110  if (verbose >=1)
     1111    printf ("sorry, but you did not compile with png-support.\nEither install SDL_image or libpng, and recompile to see the image\n");
     1112  return false;
     1113#endif /* HAVE_PNG_H */
     1114
    11011115}
    11021116
Note: See TracChangeset for help on using the changeset viewer.