vtk_jpeg.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
3 #ifndef vtk_jpeg_h
4 #define vtk_jpeg_h
5 
6 #include <stdio.h>
7 #include <stdlib.h>
8 
9 /* Use the jpeg library configured for VTK. */
10 #define VTK_MODULE_USE_EXTERNAL_vtkjpeg 0
11 
12 #if VTK_MODULE_USE_EXTERNAL_vtkjpeg
13  /* Work-around for a conflict between windows.h and jpeglib.h in cygwin.
14  If ADDRESS_TAG_BIT is defined then BaseTsd.h has been included and
15  INT32 has been defined with a typedef, so we must define XMD_H to
16  prevent the jpeg header from defining it again. */
17 # if defined(__CYGWIN__) && defined(ADDRESS_TAG_BIT) && !defined(XMD_H)
18 # define XMD_H
19 # define VTK_JPEG_XMD_H
20 # endif
21 # include <jpeglib.h>
22 # include <jerror.h>
23 #else
24 # include <vtkjpeg/jconfig.h>
25 # include <vtkjpeg/jmorecfg.h>
26 // Ensure jpeglib.h does not include jconfig.h nor jmorecfg.h from another include directory.
27 # define JCONFIG_INCLUDED
28 # define JMORECFG_INCLUDED
29 # include <vtkjpeg/jpeglib.h>
30 # include <vtkjpeg/jerror.h>
31 # undef JCONFIG_INCLUDED
32 # undef JMORECFG_INCLUDED
33 #endif
34 
35 #endif