00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033 #ifndef OPJ_INCLUDES_H
00034 #define OPJ_INCLUDES_H
00035
00036
00037
00038
00039
00040 #include "opj_config_private.h"
00041
00042
00043
00044
00045
00046
00047 #include <memory.h>
00048 #include <stdlib.h>
00049 #include <string.h>
00050 #include <math.h>
00051 #include <float.h>
00052 #include <time.h>
00053 #include <stdio.h>
00054 #include <stdarg.h>
00055 #include <ctype.h>
00056 #include <assert.h>
00057
00058
00059
00060
00061
00062
00063
00064 #if defined(OPJ_HAVE_FSEEKO) && !defined(fseek)
00065 # define fseek fseeko
00066 # define ftell ftello
00067 #endif
00068
00069
00070 #if defined(WIN32) && !defined(Windows95) && !defined(__BORLANDC__) && \
00071 !(defined(_MSC_VER) && _MSC_VER < 1400) && \
00072 !(defined(__MINGW32__) && __MSVCRT_VERSION__ < 0x800)
00073
00074
00075
00076
00077
00078 # define OPJ_FSEEK(stream,offset,whence) _fseeki64(stream, offset,whence)
00079 # define OPJ_FSTAT(fildes,stat_buff) _fstati64(fildes, stat_buff)
00080 # define OPJ_FTELL(stream) _ftelli64(stream)
00081 # define OPJ_STAT_STRUCT_T struct _stati64
00082 # define OPJ_STAT(path,stat_buff) _stati64(path, stat_buff)
00083 #else
00084 # define OPJ_FSEEK(stream,offset,whence) fseek(stream,offset,whence)
00085 # define OPJ_FSTAT(fildes,stat_buff) fstat(fildes,stat_buff)
00086 # define OPJ_FTELL(stream) ftell(stream)
00087 # define OPJ_STAT_STRUCT_T struct stat
00088 # define OPJ_STAT(path,stat_buff) stat(path,stat_buff)
00089 #endif
00090
00091
00092
00093
00094
00095
00096
00097 #include "openjpeg.h"
00098
00099
00100
00101
00102
00103
00104
00105
00106 #ifndef __GNUC__
00107 #define __attribute__(x)
00108 #endif
00109
00110
00111
00112 #if (__STDC_VERSION__ != 199901L)
00113
00114 #ifdef __GNUC__
00115 #define restrict __restrict__
00116 #else
00117 #define restrict
00118 #endif
00119 #endif
00120
00121
00122 #if defined(_MSC_VER) && (_MSC_VER < 1800) || defined(__BORLANDC__)
00123 static INLINE long lrintf(float f){
00124 #ifdef _M_X64
00125 return (long)((f>0.0f) ? (f + 0.5f):(f -0.5f));
00126 #else
00127 int i;
00128
00129 _asm{
00130 fld f
00131 fistp i
00132 };
00133
00134 return i;
00135 #endif
00136 }
00137 #endif
00138
00139 #include "opj_inttypes.h"
00140 #include "opj_clock.h"
00141 #include "opj_malloc.h"
00142 #include "function_list.h"
00143 #include "event.h"
00144 #include "bio.h"
00145 #include "cio.h"
00146
00147 #include "image.h"
00148 #include "invert.h"
00149 #include "j2k.h"
00150 #include "jp2.h"
00151
00152 #include "mqc.h"
00153 #include "raw.h"
00154 #include "bio.h"
00155
00156 #include "pi.h"
00157 #include "tgt.h"
00158 #include "tcd.h"
00159 #include "t1.h"
00160 #include "dwt.h"
00161 #include "t2.h"
00162 #include "mct.h"
00163 #include "opj_intmath.h"
00164
00165 #ifdef USE_JPIP
00166 #include "cidx_manager.h"
00167 #include "indexbox_manager.h"
00168 #endif
00169
00170
00171 #ifdef USE_JPWL
00172 #include "openjpwl/jpwl.h"
00173 #endif
00174
00175
00176
00177 #include "opj_codec.h"
00178
00179
00180 #endif