资源简介
读raw data、jpeg、bmp等多种格式的文件,实现gamma矫正等各种ISP算法下的多个功能
代码片段和文件信息
//Download by http://www.NewXing.com
/*
* TIFF file IO using CxFile.
*/
#ifdef WIN32
#include
#endif
#include
#include “ximage.h“
#if CXIMAGE_SUPPORT_TIF
#include “../tiff/tiffiop.h“
#include “xfile.h“
static tsize_t
_tiffReadProcEx(thandle_t fd tdata_t buf tsize_t size)
{
return (tsize_t)((CxFile*)fd)->Read(buf 1 size);
}
static tsize_t
_tiffWriteProcEx(thandle_t fd tdata_t buf tsize_t size)
{
return (tsize_t)((CxFile*)fd)->Write(buf 1 size);
}
static toff_t
_tiffSeekProcEx(thandle_t fd toff_t off int whence)
{
if ( off == 0xFFFFFFFF )
return 0xFFFFFFFF;
if (!((CxFile*)fd)->Seek(off whence))
return 0xFFFFFFFF;
if (whence == SEEK_SET)
return off;
return (toff_t)((CxFile*)fd)->Tell();
}
// Return nonzero if error
static int
_tiffCloseProcEx(thandle_t /*fd*/)
{
// return !((CxFile*)fd)->Close(); // “//“ needed for memory files
return 0;
}
#include
static toff_t
_tiffSizeProcEx(thandle_t fd)
{
return ((CxFile*)fd)->Size();
}
static int
_tiffMapProcEx(thandle_t /*fd*/ tdata_t* /*pbase*/ toff_t* /*psize*/)
{
return (0);
}
static void
_tiffUnmapProcEx(thandle_t /*fd*/ tdata_t /*base*/ toff_t /*size*/)
{
}
// Open a TIFF file descriptor for read/writing.
/*
TIFF*
TIFFOpen(const char* name const char* mode)
{
static const char module[] = “TIFFOpen“;
FILE* stream = fopen(name mode);
if (stream == NULL)
{
TIFFError(module “%s: Cannot open“ name);
return NULL;
}
return (TIFFFdOpen((int)stream name mode));
}
*/
TIFF*
_TIFFFdOpen(void* fd const char* name const char* mode)
{
TIFF* tif;
tif = TIFFClientOpen(name mode
(thandle_t) fd
_tiffReadProcEx _tiffWriteProcEx _tiffSeekProcEx _tiffCloseProcEx
_tiffSizeProcEx _tiffMapProcEx _tiffUnmapProcEx);
if (tif)
tif->tif_fd = fd;
return (tif);
}
extern “C“ TIFF* _TIFFOpenEx(CxFile* stream const char* mode)
{
return (_TIFFFdOpen(stream “TIFF IMAGE“ mode));
}
#ifdef __GNUC__
extern char* malloc();
extern char* realloc();
#else
#include
#endif
tdata_t
_TIFFmalloc(tsize_t s)
{
return (malloc((size_t) s));
}
void
_TIFFfree(tdata_t p)
{
free(p);
}
tdata_t
_TIFFrealloc(tdata_t p tsize_t s)
{
return (realloc(p (size_t) s));
}
void
_TIFFmemset(tdata_t p int v tsize_t c)
{
memset(p v (size_t) c);
}
void
_TIFFmemcpy(tdata_t d const tdata_t s tsize_t c)
{
memcpy(d s (size_t) c);
}
int
_TIFFmemcmp(const tdata_t p1 const tdata_t p2 tsize_t c)
{
return (memcmp(p1 p2 (size_t) c));
}
#ifndef UNICODE
#define DbgPrint wvsprintf
#define DbgPrint2 wsprintf
#define DbgMsgBox MessageBox
#else
#define DbgPrint wvsprintfA
#define DbgPrint2 wsprintfA
#define DbgMsgBox MessageBoxA
#endif
static void
Win32WarningHandler(const char* module const char* fmt va_list ap)
{
#ifdef _DEBUG
#if (!defined(_
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2017-07-18 02:11 DCRAW_cximage600_full\
目录 0 2017-07-18 02:11 DCRAW_cximage600_full\bin\
文件 3229696 2017-07-18 02:11 DCRAW_cximage600_full\bin\demod.exe
文件 9434 2017-07-18 02:11 DCRAW_cximage600_full\bin\demod.exp
文件 5692492 2017-07-18 02:11 DCRAW_cximage600_full\bin\demod.ilk
文件 15838 2017-07-18 02:11 DCRAW_cximage600_full\bin\demod.lib
目录 0 2017-07-18 02:10 DCRAW_cximage600_full\CxImage\
文件 9193 2008-01-29 00:34 DCRAW_cximage600_full\CxImage\cximage.dsp
文件 537 2001-08-06 17:19 DCRAW_cximage600_full\CxImage\cximage.dsw
文件 49784 2017-07-18 02:10 DCRAW_cximage600_full\CxImage\cximage.vcproj
文件 2619 2017-07-18 02:12 DCRAW_cximage600_full\CxImage\cximage.vcproj.DESKTOP-N520FAJ.wtsitp.user
目录 0 2017-07-18 02:10 DCRAW_cximage600_full\CxImage\CxImageDLL\
文件 332 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageCrtDll.cpp
文件 11859 2008-01-29 19:27 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageCrtDll.dsp
文件 3035 2008-02-03 17:07 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageCrtDll.rc
文件 41744 2017-07-18 02:10 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageCrtDll.vcproj
文件 2619 2017-07-18 02:12 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageCrtDll.vcproj.DESKTOP-N520FAJ.wtsitp.user
文件 2998 2003-04-06 13:33 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageDll.dsw
文件 364 2003-03-23 14:55 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageMfcDll.clw
文件 1855 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageMfcDll.cpp
文件 11043 2008-01-29 00:59 DCRAW_cximage600_full\CxImage\CxImageDLL\cximagemfcdll.dsp
文件 1368 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageMfcDll.h
文件 3031 2008-01-29 20:06 DCRAW_cximage600_full\CxImage\CxImageDLL\CxImageMfcDll.rc
文件 43087 2017-07-18 02:10 DCRAW_cximage600_full\CxImage\CxImageDLL\cximagemfcdll.vcproj
文件 2619 2017-07-18 02:12 DCRAW_cximage600_full\CxImage\CxImageDLL\cximagemfcdll.vcproj.DESKTOP-N520FAJ.wtsitp.user
文件 457 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\resource.h
文件 457 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\resrc1.h
文件 253 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\StdAfx.cpp
文件 1534 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\StdAfx.h
文件 840 2013-12-02 03:40 DCRAW_cximage600_full\CxImage\CxImageDLL\StdCrt.h
目录 0 2017-07-18 02:11 DCRAW_cximage600_full\CxImage\Debug\
............此处省略1020个文件信息
相关资源
- SN_Writer_Tool_src_v1.2020.0.0.rar
- Toolbar menu 菜单的学习与实现2
- Labview PID control toolkit
- mathpix_snipping_tool_setup.exe
- qtOpenCVTools v1.7.0.rar
- microsoft toolkit 2.4.3
- Command_Line_Tools_macOS_10.14_for_Xcode_10.1.
- TBtools最新.rar
- springsource-tool-suite-3.9.5
- eclipse-201809-4.9版本-STSTools安装zip包
- 海思HiTool-STB-5.0.27最新版工具
- 840dsl toolbox020602
- TBtools最新
- wetool企业2.8.1版,全网都在用的免费免
- depot_tools
- hibernatetools-Update-4.1.1.Final_2013-12-08_0
- Gtools LGP V9.55s.zip
- 快思聪编程crestron_toolbox_3.01.355.00
- ArcGIS10.3版本ArcHydro tools
- VMtools-Windows
- TBtools_windows-64-bits_0_6654.rar
-
VMware Tools 11 for VMware Pla
yer 15 - MKS ToolKit 8.1 破解版本
- learun.tool.7z
- CSI Tool 集成安装包(适配Ubuntu11.04)
- Codejock.Xtreme.Toolkit.Pro.v15.3.1 VS2015版本
- Kutools for Excel V17.0破解全功能无时间限
- A Sampler of Useful Computational Tools for Ap
- springsource-tool-suite-3.9.5.RELEASE-e4.8.0-u
- OpenGL蓝宝书5中文版+英文原版+GLTools
评论
共有 条评论