mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2025-12-30 10:50:13 +01:00
Remove all libtiff-related code by #ifdef
This commit is contained in:
parent
2b92556abe
commit
6e06b68452
2 changed files with 11 additions and 0 deletions
|
|
@ -67,8 +67,10 @@ bool CompareArgs::Parse_Args(int argc, char **argv)
|
|||
}
|
||||
for (int i = 0; i < argc; i++) {
|
||||
if (i == 1) {
|
||||
#if HAVE_LIBTIFF
|
||||
ImgA = RGBAImage::ReadTiff(argv[1]);
|
||||
if (!ImgA) {
|
||||
#endif /* HAVE_LIBTIFF */
|
||||
ImgA = RGBAImage::ReadPNG(argv[1]);
|
||||
if (!ImgA)
|
||||
{
|
||||
|
|
@ -77,10 +79,14 @@ bool CompareArgs::Parse_Args(int argc, char **argv)
|
|||
ErrorStr += "\n";
|
||||
return false;
|
||||
}
|
||||
#if HAVE_LIBTIFF
|
||||
}
|
||||
#endif /* HAVE_LIBTIFF */
|
||||
} else if (i == 2) {
|
||||
#if HAVE_LIBTIFF
|
||||
ImgB = RGBAImage::ReadTiff(argv[2]);
|
||||
if (!ImgB) {
|
||||
#endif /* HAVE_LIBTIFF */
|
||||
ImgB = RGBAImage::ReadPNG(argv[2]);
|
||||
if (!ImgB)
|
||||
{
|
||||
|
|
@ -89,7 +95,9 @@ bool CompareArgs::Parse_Args(int argc, char **argv)
|
|||
ErrorStr += "\n";
|
||||
return false;
|
||||
}
|
||||
#if HAVE_LIBTIFF
|
||||
}
|
||||
#endif /* HAVE_LIBTIFF */
|
||||
} else {
|
||||
if (strstr(argv[i], "-fov")) {
|
||||
if (i + 1 < argc) {
|
||||
|
|
|
|||
|
|
@ -16,6 +16,8 @@ if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
|
|||
|
||||
#include "RGBAImage.h"
|
||||
#include "png.h"
|
||||
|
||||
#if HAVE_LIBTIFF
|
||||
#include "tiff.h"
|
||||
#include "tiffio.h"
|
||||
|
||||
|
|
@ -53,6 +55,7 @@ RGBAImage* RGBAImage::ReadTiff(char *filename)
|
|||
}
|
||||
return fimg;
|
||||
}
|
||||
#endif /* HAVE_LIBTIFF */
|
||||
|
||||
// This portion was written by Scott Corley
|
||||
RGBAImage* RGBAImage::ReadPNG(char *filename)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue