Go to the source code of this file.
Enumerations | |
enum | EXIF_ASCII |
enum | EXIF_SHORT |
enum | EXIF_LONG |
enum | EXIF_RATIONAL |
enum | EXIF_SBYTE |
enum | EXIF_UNDEFINED |
enum | EXIF_SSHORT |
enum | EXIF_SLONG |
enum | EXIF_SRATIONAL |
enum | EXIF_LSEEK_ENABLE |
Functions | |
hexdump ($data) | |
======================================= Functions ====================================== | |
print_directory ($dir_entries) | |
test_print_header () | |
test_print_directory () | |
start_ifd ($count) | |
finish_ifd () | |
addDirEntry ($ifd_entry) | |
substitute_value ($ifd_entry) | |
process_ifd_entry ($ifd_entry, $group) | |
Variables | |
$ExifDeviceTemplateFilename = "/dev/exif_template" | |
$ExifDeviceMetadirFilename = "/dev/exif_metadir" | |
$ExifDeviceExifFilename = "/dev/exif_exif" | |
$ExifDeviceMetaFilename = "/dev/exif_meta" | |
$ExifXMLName = "/etc/Exif_template.xml" | |
$init = false | |
$init = true | |
$noGPS = ($_GET["noGPS"]!==NULL) | |
$nocompass = ($_GET["nocompass"]!==NULL) | |
$Exif_length_offset = 2 | |
$exif_data | |
$xml_exif = simplexml_load_file($ExifXMLName) | |
$IFD_offset = count($exif_data) | |
$SUB_IFD_offset = 12*count($xml_exif->Image->children())+2+4+$IFD_offset | |
$GPSInfo_offset = 12*count($xml_exif->Photo->children())+2+4+$SUB_IFD_offset | |
$data_offset = $GPSInfo_offset+(($xml_exif->GPSInfo)?(12*count($xml_exif->GPSInfo->children())+2+4):0) | |
$ifd_pointer = $IFD_offset | |
$data_pointer = $data_offset | |
$ifd_pointer = $SUB_IFD_offset | |
$exif_len = count($exif_head)+count($exif_data)-$Exif_length_offset | |
$exif_head [$Exif_length_offset] = ($exif_len >> 8) & 0xff | |
$exif_head [$Exif_length_offset+1] = $exif_len & 0xff | |
$Exif_str = "" | |
$Exif_file = fopen($ExifDeviceTemplateFilename, 'w') | |
$dir_sequence = array() | |
Exif template is done, now we need a directory to map frame meta data to fields in the template. | |
$dir_entries = array() | |
$frame_meta_size = 0 | |
$Exif_meta_file = fopen($ExifDeviceMetadirFilename, 'w') | |
$Exif_file = fopen($ExifDeviceTemplateFilename, 'w') | |
Rebuild buffer and enable Exif generation/output:. | |
$metadir = fread ($Exif_file, 4096) | |
$dir_entries = array() |
enum EXIF_ASCII |
enum EXIF_LSEEK_ENABLE |
enum EXIF_RATIONAL |
enum EXIF_SBYTE |
enum EXIF_SHORT |
enum EXIF_SLONG |
enum EXIF_SRATIONAL |
enum EXIF_SSHORT |
enum EXIF_UNDEFINED |
addDirEntry | ( | $ | ifd_entry | ) |
Definition at line 419 of file exif.php.
References $dir_entries, $dir_sequence, $exif_head, and min.
finish_ifd | ( | ) |
hexdump | ( | $ | data | ) |
======================================= Functions ======================================
Definition at line 314 of file exif.php.
References $d, $data, $exif_data, and $exif_head.
print_directory | ( | $ | dir_entries | ) |
process_ifd_entry | ( | $ | ifd_entry, | |
$ | group | |||
) |
Definition at line 464 of file exif.php.
References $d, $data_pointer, $exif_data, $GPSInfo_offset, $ifd_pointer, and $SUB_IFD_offset.
start_ifd | ( | $ | count | ) |
substitute_value | ( | $ | ifd_entry | ) |
test_print_directory | ( | ) |
test_print_header | ( | ) |
$data_offset = $GPSInfo_offset+(($xml_exif->GPSInfo)?(12*count($xml_exif->GPSInfo->children())+2+4):0) |
$data_pointer = $data_offset |
$dir_entries = array() |
Definition at line 198 of file exif.php.
Referenced by addDirEntry(), print_directory(), and test_print_directory().
$dir_sequence = array() |
Exif template is done, now we need a directory to map frame meta data to fields in the template.
Definition at line 197 of file exif.php.
Referenced by addDirEntry().
$exif_data |
Initial value:
array (// start of TIFF Header, data offsets will match indexes in this array 0x4d,0x4d, // (MM) Big endian, MSB goes first in multi-byte data 0x00,0x2a, // Tag Mark 0x00,0x00,0x00,0x08)
Definition at line 131 of file exif.php.
Referenced by finish_ifd(), hexdump(), process_ifd_entry(), start_ifd(), and test_print_header().
$Exif_file = fopen($ExifDeviceTemplateFilename, 'w') |
$exif_head[$Exif_length_offset] = ($exif_len >> 8) & 0xff |
Definition at line 185 of file exif.php.
Referenced by addDirEntry(), hexdump(), and test_print_header().
$exif_len = count($exif_head)+count($exif_data)-$Exif_length_offset |
$ExifDeviceTemplateFilename = "/dev/exif_template" |
$ExifXMLName = "/etc/Exif_template.xml" |
$frame_meta_size = 0 |
$GPSInfo_offset = 12*count($xml_exif->Photo->children())+2+4+$SUB_IFD_offset |
$ifd_pointer = $IFD_offset |
Definition at line 167 of file exif.php.
Referenced by finish_ifd(), process_ifd_entry(), and start_ifd().
$SUB_IFD_offset = 12*count($xml_exif->Image->children())+2+4+$IFD_offset |