Changeset 1806
- Timestamp:
- 04/13/12 23:54:11 (14 months ago)
- File:
-
- 1 edited
-
branches/release-1_0/core/dng.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/release-1_0/core/dng.c
r1803 r1806 68 68 const int cam_Resolution[]={180,1}; 69 69 int cam_AsShotNeutral[]={1000,1000,1000,1000,1000,1000}; 70 static char cam_datetime[20] = ""; // DateTimeOriginal 70 71 71 72 // warning: according to TIFF format specification, elements must be sorted by tag value in ascending order! 72 73 73 74 struct dir_entry IFD0[]={ 74 {0xFE, T_LONG, 1, 1}, // NewSubFileType: Preview Image75 {0x100, T_LONG, 1, DNG_TH_WIDTH}, // ImageWidth76 {0x101, T_LONG, 1, DNG_TH_HEIGHT}, // ImageLength77 {0x102, T_SHORT, 3, (int)cam_PreviewBitsPerSample}, // BitsPerSample: 8,8,878 {0x103, T_SHORT, 1, 1}, // Compression: Uncompressed79 {0x106, T_SHORT, 1, 2}, //PhotometricInterpretation: RGB80 {0x10E, T_ASCII, 1, 0}, // ImageDescription81 {0x10F, T_ASCII, sizeof(CAM_MAKE), (int)CAM_MAKE}, // Make82 {0x110, T_ASCII, 32, (int)cam_name}, //Model: Filled at header generation.83 {0x111, T_LONG, 1, 0}, //StripOffsets: Offset84 {0x112, T_SHORT, 1, 1}, //Orientation: 1 - 0th row is top, 0th column is left85 {0x115, T_SHORT, 1, 3}, // SamplesPerPixel: 386 {0x116, T_SHORT, 1, DNG_TH_HEIGHT}, //RowsPerStrip87 {0x117, T_LONG, 1, DNG_TH_WIDTH*DNG_TH_HEIGHT*3}, // StripByteCounts = preview size88 {0x11C, T_SHORT, 1, 1}, // PlanarConfiguration: 189 {0x131, T_ASCII, sizeof(cam_chdk_ver), (int)cam_chdk_ver}, //Software90 {0x132, T_ASCII, 20, 0},// DateTime91 {0x14A, T_LONG, 1, 0}, //SubIFDs offset92 {0x8298, T_ASCII, 1, 0}, // Copyright93 {0x8769, T_LONG, 1, 0}, //EXIF_IFD offset75 {0xFE, T_LONG, 1, 1}, // NewSubFileType: Preview Image 76 {0x100, T_LONG, 1, DNG_TH_WIDTH}, // ImageWidth 77 {0x101, T_LONG, 1, DNG_TH_HEIGHT}, // ImageLength 78 {0x102, T_SHORT, 3, (int)cam_PreviewBitsPerSample}, // BitsPerSample: 8,8,8 79 {0x103, T_SHORT, 1, 1}, // Compression: Uncompressed 80 {0x106, T_SHORT, 1, 2}, //PhotometricInterpretation: RGB 81 {0x10E, T_ASCII, 1, 0}, // ImageDescription 82 {0x10F, T_ASCII, sizeof(CAM_MAKE), (int)CAM_MAKE}, // Make 83 {0x110, T_ASCII, 32, (int)cam_name}, //Model: Filled at header generation. 84 {0x111, T_LONG, 1, 0}, //StripOffsets: Offset 85 {0x112, T_SHORT, 1, 1}, //Orientation: 1 - 0th row is top, 0th column is left 86 {0x115, T_SHORT, 1, 3}, // SamplesPerPixel: 3 87 {0x116, T_SHORT, 1, DNG_TH_HEIGHT}, //RowsPerStrip 88 {0x117, T_LONG, 1, DNG_TH_WIDTH*DNG_TH_HEIGHT*3}, // StripByteCounts = preview size 89 {0x11C, T_SHORT, 1, 1}, // PlanarConfiguration: 1 90 {0x131, T_ASCII, sizeof(cam_chdk_ver), (int)cam_chdk_ver}, //Software 91 {0x132, T_ASCII, 20, (int)cam_datetime}, // DateTime 92 {0x14A, T_LONG, 1, 0}, //SubIFDs offset 93 {0x8298, T_ASCII, 1, 0}, // Copyright 94 {0x8769, T_LONG, 1, 0}, //EXIF_IFD offset 94 95 #if defined(CAM_HAS_GPS) 95 {0x8825, T_LONG, 1, 0}, //GPS_IFD offset96 #endif 97 {0x9216, T_BYTE, 4, 0x00000001}, // TIFF/EPStandardID: 1.0.0.098 {0xC612, T_BYTE, 4, 0x00000101}, //DNGVersion: 1.1.0.099 {0xC614, T_ASCII, 32, (int)cam_name}, //UniqueCameraModel. Filled at header generation.96 {0x8825, T_LONG, 1, 0}, //GPS_IFD offset 97 #endif 98 {0x9216, T_BYTE, 4, 0x00000001}, // TIFF/EPStandardID: 1.0.0.0 99 {0xC612, T_BYTE, 4, 0x00000101}, //DNGVersion: 1.1.0.0 100 {0xC614, T_ASCII, 32, (int)cam_name}, //UniqueCameraModel. Filled at header generation. 100 101 {0xC621, T_SRATIONAL, 9, (int)cam_ColorMatrix1}, 101 102 {0xC627, T_RATIONAL, 3, (int)cam_AnalogBalance}, … … 141 142 static int cam_shutter[2] = { 0, 1000000 }; // Shutter speed 142 143 static int cam_aperture[2] = { 0, 10 }; // Aperture 143 static char cam_datetime[20] = ""; // DateTimeOriginal144 144 static int cam_apex_shutter[2] = { 0, 96 }; // Shutter speed in APEX units 145 145 static int cam_apex_aperture[2] = { 0, 96 }; // Aperture in APEX units … … 256 256 case 0x110 : // CameraName 257 257 case 0xC614: IFD_LIST[j].entry[i].count = strlen((char*)IFD_LIST[j].entry[i].offset) + 1; break; // UniqueCameraModel 258 case 0x132 :259 258 case 0x8827: IFD_LIST[j].entry[i].offset=exif_data.iso; break;//ISOSpeedRatings 260 259 case 0x8822: IFD_LIST[j].entry[i].offset=get_exp_program_for_exif(exif_data.exp_program); break;//ExposureProgram
Note: See TracChangeset
for help on using the changeset viewer.