/* * Intel IPP demo library */ #include #include "ksquirrel-libs/fmt_types.h" #include "ksquirrel-libs/fileio.h" #include "ksquirrel-libs/fmt_utils.h" #undef PACKAGE #undef PACKAGE_BUGREPORT #undef PACKAGE_NAME #undef PACKAGE_STRING #undef PACKAGE_TARNAME #undef PACKAGE_VERSION #undef VERSION /* * */ #include "j2kit.h" #include "cmdoptions.h" #include "consdiagnoutput.h" #include "fixedstring.h" // codec specific level #include "djp2file.h" #include "edib.h" #include "epnm.h" // codec meta level #include "mdjp2.h" #include "medib.h" #include "mepnm.h" #include "mapfileinput.h" #include "mapfileoutput.h" #include "byteinput.h" #include "byteoutput.h" #include "mrstrimage.h" #include "transcodingexception.h" #include "sysexception.h" #include "stricmp.h" /* */ #include "fmt_codec_jpeg2000_defs.h" #include "fmt_codec_jpeg2000.ipp.h" #include "../xpm/codec_jpeg2000.xpm" #include "ksquirrel-libs/error.h" ConsDiagnOutput diagnOutput; typedef ByteInputSigned > MapFileInputBE; typedef ByteOutputSigned > MapFileOutputLE; typedef ByteOutputSigned > MapFileOutputBE; class MapFileBoundedInputBE : public ByteInputBoundService { public: MapFileBoundedInputBE() {} virtual ~MapFileBoundedInputBE() {} void Open(const char *fileName) { MapFileInput::Open(fileName); PushSize(MapFileInput::Size()); } void Close() { MapFileInput::Close(); PopSize(); } }; MRstrImage metaImage; /* * * JPEG 2000 standard supports lossy and lossless compression of * single-component (e.g., grayscale) and multicomponent (e.g., color) * imagery. * */ fmt_codec::fmt_codec() : fmt_codec_base() { /* at first glance do nothing at this point */ } fmt_codec::~fmt_codec() {} void fmt_codec::options(codec_options *o) { o->version = "0.3.1"; o->name = "JPEG 2000"; o->filter = "*.jp2 *.j2k "; // some jp2 files don't have this mime header (why ?) // "....152120 }