diff --git a/README.md b/README.md index 79582765..91e7fe51 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ Kim is a Kotlin Multiplatform library for reading and writing image metadata. -It's part of [Ashampoo Photos](https://ashampoo.com/photos). +It's part of [Ashampoo Photo Organizer](https://ashampoo.com/photo-organizer). ## Features @@ -34,12 +34,12 @@ It's part of [Ashampoo Photos](https://ashampoo.com/photos). + JPG: Lossless rotation by modifying only one byte (where present) The future development of features on our part is driven entirely by the needs -of Ashampoo Photos, which, in turn, is driven by user community feedback. +of Ashampoo Photo Organizer, which, in turn, is driven by user community feedback. ## Installation ``` -implementation("com.ashampoo:kim:0.17.3") +implementation("com.ashampoo:kim:0.17.4") ``` For the targets `wasmJs` & `js` you also need to specify this: diff --git a/examples/kim-kotlin-jvm-sample/src/main/kotlin/Main.kt b/examples/kim-kotlin-jvm-sample/src/main/kotlin/Main.kt index 1e8f8d1a..7c23f53c 100644 --- a/examples/kim-kotlin-jvm-sample/src/main/kotlin/Main.kt +++ b/examples/kim-kotlin-jvm-sample/src/main/kotlin/Main.kt @@ -125,6 +125,8 @@ fun setGeoTiffToJpeg() { /** * Shows how to update set GeoTiff to a TIF file using JVM API. + * + * CAUTION: Writing TIFF is experimental and may corrupt the file! */ fun setGeoTiffToTiff() { diff --git a/src/commonMain/kotlin/com/ashampoo/kim/common/ExifDateUtil.kt b/src/commonMain/kotlin/com/ashampoo/kim/common/ExifDateUtil.kt index bb3435d1..7b86bd46 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/common/ExifDateUtil.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/common/ExifDateUtil.kt @@ -15,13 +15,9 @@ */ package com.ashampoo.kim.common -/** - * This class contains extensions needed to - * interpret bytes in photo files. - */ - -private val emptyExifDates = setOf( +private val emptyExifDateStrings = setOf( "0000:00:00 00:00:00", + " : : : : ", " " ) @@ -43,7 +39,7 @@ private const val FIRST_SECOND_INDEX = 17 private const val SECOND_SECOND_INDEX = 18 fun isExifDateEmpty(exifDate: String?): Boolean = - exifDate.isNullOrEmpty() || emptyExifDates.contains(exifDate) + exifDate.isNullOrBlank() || emptyExifDateStrings.contains(exifDate) /** * EXIF dates are in the format of "yyyy:MM:dd HH:mm:ss" (19 chars), diff --git a/src/commonMain/kotlin/com/ashampoo/kim/common/PhotoMetadataConverter.kt b/src/commonMain/kotlin/com/ashampoo/kim/common/PhotoMetadataConverter.kt index 6dd848b4..d3d39a13 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/common/PhotoMetadataConverter.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/common/PhotoMetadataConverter.kt @@ -31,167 +31,187 @@ import com.ashampoo.kim.model.TiffOrientation import kotlinx.datetime.LocalDateTime import kotlinx.datetime.TimeZone import kotlinx.datetime.toInstant +import kotlin.jvm.JvmOverloads +import kotlin.jvm.JvmStatic -fun ImageMetadata.convertToPhotoMetadata( - ignoreOrientation: Boolean = false -): PhotoMetadata { +/* + * This is a dedicated object with @JvmStatic methods + * to provide a better API to pure Java projects. + */ +object PhotoMetadataConverter { + + @JvmStatic + @JvmOverloads + @Suppress("LongMethod") + fun convertToPhotoMetadata( + imageMetadata: ImageMetadata, + ignoreOrientation: Boolean = false + ): PhotoMetadata { + + val orientation = if (ignoreOrientation) + TiffOrientation.STANDARD + else + TiffOrientation.of(imageMetadata.findShortValue(TiffTag.TIFF_TAG_ORIENTATION)?.toInt()) - val orientation = if (ignoreOrientation) - TiffOrientation.STANDARD - else - TiffOrientation.of(findShortValue(TiffTag.TIFF_TAG_ORIENTATION)?.toInt()) + val takenDateMillis = extractTakenDateMillis(imageMetadata) - val takenDateMillis = extractTakenDateMillis(this) + val gpsDirectory = imageMetadata.findTiffDirectory(TiffConstants.TIFF_DIRECTORY_GPS) - val gpsDirectory = findTiffDirectory(TiffConstants.TIFF_DIRECTORY_GPS) + val gps = gpsDirectory?.let { GPSInfo.createFrom(it) } - val gps = gpsDirectory?.let { GPSInfo.createFrom(it) } + val latitude = gps?.getLatitudeAsDegreesNorth() + val longitude = gps?.getLongitudeAsDegreesEast() - val latitude = gps?.getLatitudeAsDegreesNorth() - val longitude = gps?.getLongitudeAsDegreesEast() + val cameraMake = imageMetadata.findStringValue(TiffTag.TIFF_TAG_MAKE) + val cameraModel = imageMetadata.findStringValue(TiffTag.TIFF_TAG_MODEL) - val cameraMake = findStringValue(TiffTag.TIFF_TAG_MAKE) - val cameraModel = findStringValue(TiffTag.TIFF_TAG_MODEL) + val lensMake = imageMetadata.findStringValue(ExifTag.EXIF_TAG_LENS_MAKE) + val lensModel = imageMetadata.findStringValue(ExifTag.EXIF_TAG_LENS_MODEL) - val lensMake = findStringValue(ExifTag.EXIF_TAG_LENS_MAKE) - val lensModel = findStringValue(ExifTag.EXIF_TAG_LENS_MODEL) + /* Look for ISO at the standard place and fall back to test RW2 logic. */ + val iso = imageMetadata.findShortValue(ExifTag.EXIF_TAG_ISO) + ?: imageMetadata.findShortValue(ExifTag.EXIF_TAG_ISO_PANASONIC) - /* Look for ISO at the standard place and fall back to test RW2 logic. */ - val iso = findShortValue(ExifTag.EXIF_TAG_ISO) - ?: findShortValue(ExifTag.EXIF_TAG_ISO_PANASONIC) + val exposureTime = imageMetadata.findDoubleValue(ExifTag.EXIF_TAG_EXPOSURE_TIME) + val fNumber = imageMetadata.findDoubleValue(ExifTag.EXIF_TAG_FNUMBER) + val focalLength = imageMetadata.findDoubleValue(ExifTag.EXIF_TAG_FOCAL_LENGTH) - val exposureTime = findDoubleValue(ExifTag.EXIF_TAG_EXPOSURE_TIME) - val fNumber = findDoubleValue(ExifTag.EXIF_TAG_FNUMBER) - val focalLength = findDoubleValue(ExifTag.EXIF_TAG_FOCAL_LENGTH) + val keywords = mutableSetOf() - val keywords = mutableSetOf() + val iptcRecords = imageMetadata.iptc?.records - val iptcRecords = iptc?.records + iptcRecords?.forEach { - iptcRecords?.forEach { + if (it.iptcType == IptcTypes.KEYWORDS) + keywords.add(it.value) + } - if (it.iptcType == IptcTypes.KEYWORDS) - keywords.add(it.value) - } + val gpsCoordinates = + if (latitude != null && longitude != null) + GpsCoordinates( + latitude = latitude, + longitude = longitude + ) + else + null - val gpsCoordinates = - if (latitude != null && longitude != null) - GpsCoordinates( - latitude = latitude, - longitude = longitude - ) - else - null + val xmpMetadata: PhotoMetadata? = imageMetadata.xmp?.let { + XmpReader.readMetadata(it) + } - val xmpMetadata: PhotoMetadata? = xmp?.let { - XmpReader.readMetadata(it) - } + val thumbnailBytes = imageMetadata.getExifThumbnailBytes() - val thumbnailBytes = getExifThumbnailBytes() + val thumbnailImageSize = thumbnailBytes?.let { + JpegImageParser.getImageSize( + ByteArrayByteReader(thumbnailBytes) + ) + } - val thumbnailImageSize = thumbnailBytes?.let { - JpegImageParser.getImageSize( - ByteArrayByteReader(thumbnailBytes) + /* + * Embedded XMP metadata has higher priority than EXIF or IPTC + * for certain fields because it's the newer format. Some fields + * like rating, faces and persons in image are exclusive to XMP. + * + * Resolution, orientation and capture parameters (camera make, + * iso, exposure time, etc.) are always taken from EXIF. + */ + return PhotoMetadata( + widthPx = imageMetadata.imageSize?.width, + heightPx = imageMetadata.imageSize?.height, + orientation = orientation, + takenDate = xmpMetadata?.takenDate ?: takenDateMillis, + gpsCoordinates = xmpMetadata?.gpsCoordinates ?: gpsCoordinates, + location = xmpMetadata?.location, + cameraMake = cameraMake, + cameraModel = cameraModel, + lensMake = lensMake, + lensModel = lensModel, + iso = iso?.toInt(), + exposureTime = exposureTime, + fNumber = fNumber, + focalLength = focalLength, + flagged = xmpMetadata?.flagged ?: false, + rating = xmpMetadata?.rating, + keywords = keywords.ifEmpty { xmpMetadata?.keywords ?: emptySet() }, + faces = xmpMetadata?.faces ?: emptyMap(), + personsInImage = xmpMetadata?.personsInImage ?: emptySet(), + albums = xmpMetadata?.albums ?: emptySet(), + thumbnailImageSize = thumbnailImageSize, + thumbnailBytes = thumbnailBytes ) } - /* - * Embedded XMP metadata has higher priority than EXIF or IPTC - * for certain fields because it's the newer format. Some fields - * like rating, faces and persons in image are exclusive to XMP. - * - * Resolution, orientation and capture parameters (camera make, - * iso, exposure time, etc.) are always taken from EXIF. - */ - return PhotoMetadata( - widthPx = imageSize?.width, - heightPx = imageSize?.height, - orientation = orientation, - takenDate = xmpMetadata?.takenDate ?: takenDateMillis, - gpsCoordinates = xmpMetadata?.gpsCoordinates ?: gpsCoordinates, - location = xmpMetadata?.location, - cameraMake = cameraMake, - cameraModel = cameraModel, - lensMake = lensMake, - lensModel = lensModel, - iso = iso?.toInt(), - exposureTime = exposureTime, - fNumber = fNumber, - focalLength = focalLength, - flagged = xmpMetadata?.flagged ?: false, - rating = xmpMetadata?.rating, - keywords = keywords.ifEmpty { xmpMetadata?.keywords ?: emptySet() }, - faces = xmpMetadata?.faces ?: emptyMap(), - personsInImage = xmpMetadata?.personsInImage ?: emptySet(), - albums = xmpMetadata?.albums ?: emptySet(), - thumbnailImageSize = thumbnailImageSize, - thumbnailBytes = thumbnailBytes - ) -} + @JvmStatic + fun extractTakenDateAsIsoString(metadata: ImageMetadata): String? { -private fun extractTakenDateAsIso(metadata: ImageMetadata): String? { + val takenDateField = metadata.findTiffField(ExifTag.EXIF_TAG_DATE_TIME_ORIGINAL) + ?: return null - val takenDateField = metadata.findTiffField(ExifTag.EXIF_TAG_DATE_TIME_ORIGINAL) + var takenDate = takenDateField.value as? String - var takenDate = takenDateField?.value as? String + /* + * Workaround in case that it's a String array. + */ + if (takenDate == null) + takenDate = takenDateField.toStringValue() - /* - * photo_53.jpg of our test data triggers a bug here. - * This is workaround code. - */ - if (takenDate == null && takenDateField != null) - takenDate = takenDateField.toStringValue() + if (isExifDateEmpty(takenDate)) + return null - if (takenDate == null || isExifDateEmpty(takenDate)) - return null + return convertExifDateToIso8601Date(takenDate) + } - return convertExifDateToIso8601Date(takenDate) -} + @JvmStatic + fun extractTakenDateMillis(metadata: ImageMetadata): Long? { -private fun extractTakenDateMillis(metadata: ImageMetadata): Long? { + var takenDate: String? = null - val exif = metadata.exif + try { - if (exif == null) - return exif + takenDate = extractTakenDateAsIsoString(metadata) ?: return null - var takenDate: String? = null + val takenDateSubSecond = metadata + .findStringValue(ExifTag.EXIF_TAG_SUB_SEC_TIME_ORIGINAL) + ?.toIntOrNull() + ?: 0 - try { + /* + * If the date string itself contains a sub second like "2020-08-30T18:43:00.500" + * this should be used. We append it, if the string does not have a dot yet. + */ + val takenDatePlusSubSecond = if (!takenDate.contains('.')) + "$takenDate.$takenDateSubSecond" + else + takenDate - takenDate = extractTakenDateAsIso(metadata) ?: return null + val timeZone = if (underUnitTesting) + TimeZone.of("GMT+02:00") + else + TimeZone.currentSystemDefault() - val takenDateSubSecond = metadata - .findStringValue(ExifTag.EXIF_TAG_SUB_SEC_TIME_ORIGINAL) - ?.toIntOrNull() - ?: 0 + return LocalDateTime.parse(takenDatePlusSubSecond) + .toInstant(timeZone) + .toEpochMilliseconds() - /* - * If the date string itself contains a sub second like "2020-08-30T18:43:00.500" - * this should be used. We append it, if the string does not have a dot yet. - */ - val takenDatePlusSubSecond = if (!takenDate.contains('.')) - "$takenDate.$takenDateSubSecond" - else - takenDate + } catch (ignore: Exception) { - val timeZone = if (underUnitTesting) - TimeZone.of("GMT+02:00") - else - TimeZone.currentSystemDefault() + /* + * Many photos contain wrong values here. We ignore this problem and hope + * that another taken date source like embedded XMP has a valid date instead. + */ + println("Ignore invalid EXIF DateTimeOriginal: '$takenDate'") - return LocalDateTime.parse(takenDatePlusSubSecond) - .toInstant(timeZone) - .toEpochMilliseconds() + return null + } + } - } catch (ignore: Exception) { +} - /* - * Many photos contain wrong values here. We ignore this problem and hope - * that another taken date source like embedded XMP has a valid date instead. - */ - println("Ignore invalid EXIF DateTimeOriginal: '$takenDate'") +fun ImageMetadata.convertToPhotoMetadata( + ignoreOrientation: Boolean = false +): PhotoMetadata = + PhotoMetadataConverter.convertToPhotoMetadata( + imageMetadata = this, + ignoreOrientation = ignoreOrientation + ) - return null - } -} diff --git a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParser.kt b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParser.kt index 5b9b73b4..28bddbf6 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParser.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParser.kt @@ -42,7 +42,7 @@ import com.ashampoo.kim.model.ImageSize object JpegImageParser : ImageParser { - fun getImageSize(byteReader: ByteReader): ImageSize { + fun getImageSize(byteReader: ByteReader): ImageSize? { val magicNumberBytes = byteReader.readBytes(ImageFormatMagicNumbers.jpeg.size).toList() @@ -51,12 +51,16 @@ object JpegImageParser : ImageParser { "JPEG magic number mismatch: ${magicNumberBytes.toByteArray().toSingleNumberHexes()}" } + var readBytesCount = magicNumberBytes.size + @Suppress("LoopWithTooManyJumpStatements") do { var segmentIdentifier = byteReader.readByte() ?: break var segmentType = byteReader.readByte() ?: break + readBytesCount += 2 + /* * Find the segment marker. Markers are zero or more 0xFF bytes, followed by * a 0xFF and then a byte not equal to 0x00 or 0xFF. @@ -71,6 +75,8 @@ object JpegImageParser : ImageParser { val nextSegmentType = byteReader.readByte() ?: break + readBytesCount += 1 + segmentType = nextSegmentType } @@ -80,18 +86,33 @@ object JpegImageParser : ImageParser { ) break + /* If we don't have anough bytes for the segment count we are done reading. */ + if (byteReader.contentLength - readBytesCount < 2) + break + /* Note: Segment length includes size bytes */ val segmentLength = byteReader.read2BytesAsInt("segmentLength", JpegConstants.JPEG_BYTE_ORDER) - 2 + readBytesCount += 2 + + /* Ignore invalid segment lengths */ if (segmentLength <= 0) - throw ImageReadException("Illegal JPEG segment length: $segmentLength") + continue /* We are only looking for a SOF segment. */ if (!JpegConstants.SOFN_MARKER_BYTES.contains(segmentType)) { + val remainingByteCount = byteReader.contentLength - readBytesCount + + /* Ignore invalid segment lengths */ + if (segmentLength > remainingByteCount) + continue + byteReader.skipBytes("skip segment", segmentLength) + readBytesCount += segmentLength + continue } @@ -105,7 +126,7 @@ object JpegImageParser : ImageParser { } while (true) - throw ImageReadException("Did not find image size.") + return null } @Throws(ImageReadException::class) @@ -138,17 +159,11 @@ object JpegImageParser : ImageParser { ) } - private fun getImageSize(segments: List): ImageSize { + private fun getImageSize(segments: List): ImageSize? { val sofnSegment = segments.filterIsInstance() - if (sofnSegment.isEmpty()) - throw ImageReadException("No JFIF Data Found.") - - if (sofnSegment.size > 1) - throw ImageReadException("Redundant JFIF Data Found.") - - val firstSegment = sofnSegment.first() + val firstSegment = sofnSegment.firstOrNull() ?: return null return ImageSize(firstSegment.width, firstSegment.height) } @@ -215,7 +230,7 @@ object JpegImageParser : ImageParser { val iptcMetadata = try { segment.parseIptcMetadata() } catch (ignore: ImageReadException) { - println("Ignored broken IPTC: ${ignore.message}") + /* We ignore proken IPTC. */ continue } diff --git a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegMetadataExtractor.kt b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegMetadataExtractor.kt index acebd939..027be89f 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegMetadataExtractor.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegMetadataExtractor.kt @@ -114,8 +114,15 @@ object JpegMetadataExtractor : MetadataExtractor { /* Segment length includes size bytes, so subtract two */ segmentLength -= 2 + /* Ignore invalid segment lengths */ if (segmentLength <= 0) - throw ImageReadException("Illegal JPEG segment length: $segmentLength") + continue + + val remainingByteCount = byteReader.contentLength - bytes.size + + /* Ignore invalid segment lengths */ + if (segmentLength > remainingByteCount) + continue val segmentBytes = byteReader.readBytes(segmentLength) diff --git a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinder.kt b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinder.kt index f1c9125b..fa2254c1 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinder.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinder.kt @@ -84,18 +84,29 @@ object JpegOrientationOffsetFinder { if (segmentType == SEGMENT_START_OF_SCAN || segmentType == MARKER_END_OF_IMAGE) break + /* If we don't have anough bytes for the segment count we are done reading. */ + if (byteReader.contentLength - positionCounter < 2) + break + /* Note: Segment length includes size bytes */ val segmentLength = byteReader.read2BytesAsInt("segmentLength", JPEG_BYTE_ORDER) - 2 positionCounter += 2 + /* Ignore invalid segment lengths */ if (segmentLength <= 0) - throw ImageReadException("Illegal JPEG segment length: $segmentLength") + continue /* We are only looking for the EXIF segment. */ if (segmentType != APP1_MARKER) { + val remainingByteCount = byteReader.contentLength - positionCounter + + /* Ignore invalid segment lengths */ + if (segmentLength > remainingByteCount) + continue + byteReader.skipBytes("skip segment", segmentLength) positionCounter += segmentLength diff --git a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegUtils.kt b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegUtils.kt index a602bbef..07e287bc 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegUtils.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/format/jpeg/JpegUtils.kt @@ -16,35 +16,38 @@ */ package com.ashampoo.kim.format.jpeg -import com.ashampoo.kim.common.ImageReadException import com.ashampoo.kim.common.toUInt16 import com.ashampoo.kim.format.jpeg.JpegConstants.JPEG_BYTE_ORDER import com.ashampoo.kim.input.ByteReader object JpegUtils { - private fun findNextMarkerBytes(byteReader: ByteReader): ByteArray { + fun traverseJFIF(byteReader: ByteReader, visitor: JpegVisitor) { - val markerBytes = ByteArray(2) + byteReader.readAndVerifyBytes("JPEG SOI (0xFFD8)", JpegConstants.SOI) - do { - markerBytes[0] = markerBytes[1] - markerBytes[1] = byteReader.readByte("JFIF marker") - } while ( - 0xFF and markerBytes[0].toInt() != 0xFF || - 0xFF and markerBytes[1].toInt() == 0xFF - ) + var readBytesCount = JpegConstants.SOI.size - return markerBytes - } + while (true) { - fun traverseJFIF(byteReader: ByteReader, visitor: JpegVisitor) { + val markerBytes = ByteArray(2) - byteReader.readAndVerifyBytes("JPEG SOI (0xFFD8)", JpegConstants.SOI) + /* + * Find next marker bytes + * + * If there are no more bytes left we end. + */ + do { - while (true) { + markerBytes[0] = markerBytes[1] + markerBytes[1] = byteReader.readByte() ?: return - val markerBytes = findNextMarkerBytes(byteReader) + readBytesCount++ + + } while ( + 0xFF and markerBytes[0].toInt() != 0xFF || + 0xFF and markerBytes[1].toInt() == 0xFF + ) val marker = markerBytes.toUInt16(JPEG_BYTE_ORDER) @@ -57,17 +60,35 @@ object JpegUtils { visitor.visitSOS(marker, markerBytes, imageData) + /* Break, because the image segment is the last one. */ break } + /* If we don't have anough bytes for the segment count we are done reading. */ + if (byteReader.contentLength - readBytesCount < 2) + break + val segmentLengthBytes = byteReader.readBytes("segmentLengthBytes", 2) + readBytesCount += 2 + val segmentLength = segmentLengthBytes.toUInt16(JPEG_BYTE_ORDER) - if (segmentLength < 2) - throw ImageReadException("Invalid segment size: $segmentLength") + val segmentContentLength = segmentLength - 2 + + val remainingByteCount = byteReader.contentLength - readBytesCount + + /* + * If the segment specifies a zero length or a length that is + * longer than the remaining bytes, it's corrupt and should be ignored. + * That's what ExifTool does. + */ + if (segmentContentLength <= 0 || segmentContentLength > remainingByteCount) + continue + + val segmentData = byteReader.readBytes("segmentData", segmentContentLength) - val segmentData = byteReader.readBytes("segmentData", segmentLength - 2) + readBytesCount += segmentContentLength val analyzeNextSegment = visitor.visitSegment( marker, diff --git a/src/commonMain/kotlin/com/ashampoo/kim/format/tiff/TiffReader.kt b/src/commonMain/kotlin/com/ashampoo/kim/format/tiff/TiffReader.kt index 552fd6c0..e9337333 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/format/tiff/TiffReader.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/format/tiff/TiffReader.kt @@ -215,10 +215,27 @@ object TiffReader { if (field != null) { - val subDirOffsets: IntArray = when (offsetField) { - is TagInfoLong -> intArrayOf(directory.getFieldValue(offsetField)!!) - is TagInfoLongs -> directory.getFieldValue(offsetField) - else -> error("Unknown type: $offsetField") + val subDirOffsets: IntArray = try { + + when (offsetField) { + is TagInfoLong -> intArrayOf(directory.getFieldValue(offsetField)!!) + is TagInfoLongs -> directory.getFieldValue(offsetField) + else -> error("Unknown offset type: $offsetField") + } + + } catch (ignore: ImageReadException) { + + /* + * If the offset field is broken we don't try + * to read the sub directory. + * + * We need to remove the field pointing to wrong + * data or else we won't be able to update the file. + */ + + fields.remove(field) + + continue } for ((index, subDirOffset) in subDirOffsets.withIndex()) { @@ -597,8 +614,6 @@ object TiffReader { } catch (ignore: Exception) { - ignore.printStackTrace() // FIXME - /* * Be silent here as GeoTiff interpretation is not essential. */ diff --git a/src/commonMain/kotlin/com/ashampoo/kim/model/PhotoMetadata.kt b/src/commonMain/kotlin/com/ashampoo/kim/model/PhotoMetadata.kt index 32a094de..fb8c88e9 100644 --- a/src/commonMain/kotlin/com/ashampoo/kim/model/PhotoMetadata.kt +++ b/src/commonMain/kotlin/com/ashampoo/kim/model/PhotoMetadata.kt @@ -24,7 +24,7 @@ import kotlinx.datetime.toLocalDateTime /** * Represents a high-level summary of image metadata extracted from raw ImageMetadata. - * This summary is used by Ashampoo Photos. + * This summary is used by Ashampoo Photo Organizer. */ data class PhotoMetadata( diff --git a/src/commonTest/kotlin/com/ashampoo/kim/XmpExtractionTest.kt b/src/commonTest/kotlin/com/ashampoo/kim/XmpExtractionTest.kt index 2b6dd19d..8e6d2e94 100644 --- a/src/commonTest/kotlin/com/ashampoo/kim/XmpExtractionTest.kt +++ b/src/commonTest/kotlin/com/ashampoo/kim/XmpExtractionTest.kt @@ -25,7 +25,7 @@ import kotlin.test.fail class XmpExtractionTest { val indicesWithoutXmp = setOf( - 2, 18, 20, 23, 30, 48, + 2, 18, 20, 23, 30, 42, 43, 44, 45, 46, 47, 48, KimTestData.HEIC_TEST_IMAGE_INDEX, KimTestData.GIF_TEST_IMAGE_INDEX, KimTestData.NEF_TEST_IMAGE_INDEX, diff --git a/src/commonTest/kotlin/com/ashampoo/kim/common/ExifDateUtilTest.kt b/src/commonTest/kotlin/com/ashampoo/kim/common/ExifDateUtilTest.kt index e1e6558c..bfa8b24d 100644 --- a/src/commonTest/kotlin/com/ashampoo/kim/common/ExifDateUtilTest.kt +++ b/src/commonTest/kotlin/com/ashampoo/kim/common/ExifDateUtilTest.kt @@ -53,6 +53,11 @@ class ExifDateUtilTest { convertExifDateToIso8601Date(" ") } + /* Blanks string. */ + assertFailsWith("Should not accept only blanks.") { + convertExifDateToIso8601Date(" : : : : ") + } + /* Zero string. */ assertFailsWith("Should not accept only zeros.") { convertExifDateToIso8601Date("0000:00:00 00:00:00") diff --git a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParserTest.kt b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParserTest.kt index cb1f2a92..06557f9b 100644 --- a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParserTest.kt +++ b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegImageParserTest.kt @@ -64,13 +64,13 @@ class JpegImageParserTest { 38 to ImageSize(2371, 1580), 39 to ImageSize(4608, 3456), 40 to ImageSize(4272, 2848), - 41 to ImageSize(4928, 3264), - 42 to ImageSize(3870, 3131), - 43 to ImageSize(4032, 3024), - 44 to ImageSize(6000, 4000), - 45 to ImageSize(3594, 2446), - 46 to ImageSize(4390, 2927), - 47 to ImageSize(3038, 3038), + 41 to ImageSize(3264, 1836), + 42 to ImageSize(1024, 768), + 43 to ImageSize(1024, 768), + 44 to ImageSize(2820, 3077), + 45 to null, + 46 to ImageSize(325, 407), + 47 to ImageSize(260, 773), 48 to ImageSize(4032, 3024), 49 to ImageSize(5184, 3456), 50 to ImageSize(6240, 4160) diff --git a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinderTest.kt b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinderTest.kt index 73bd1136..8a568e9e 100644 --- a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinderTest.kt +++ b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegOrientationOffsetFinderTest.kt @@ -41,9 +41,10 @@ class JpegOrientationOffsetFinderTest { 38 to 102, 39 to 66, 40 to 54, - 41 to 55, - 44 to 54, - 45 to 54, + 41 to 54, + 42 to 66, + 43 to 66, + 46 to 49, 48 to 55, 49 to 54, 50 to 54 diff --git a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegRewriterTest.kt b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegRewriterTest.kt index 658080fe..37995639 100644 --- a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegRewriterTest.kt +++ b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegRewriterTest.kt @@ -78,6 +78,20 @@ class JpegRewriterTest { for (index in 1..KimTestData.HIGHEST_JPEG_INDEX) { + // FIXME APP1 segment is too long for rewrite + if (index == 41) + continue + + // FIXME Corrupt file. Normal fields have offset in Makernote space. + // This should be detected to keep Makernote as is. + // ExifTool behaves the same. + if (index == 42) + continue + + // FIXME Handle extra ExifOffset in IFD1 (thumbnail) + if (index == 43) + continue + val bytes = KimTestData.getBytesOf(index) val metadata = Kim.readMetadata(bytes) @@ -172,6 +186,20 @@ class JpegRewriterTest { for (index in 1..KimTestData.HIGHEST_JPEG_INDEX) { + // FIXME APP1 segment is too long for rewrite + if (index == 41) + continue + + // FIXME Corrupt file. Normal fields have offset in Makernote space. + // This should be detected to keep Makernote as is. + // ExifTool behaves the same. + if (index == 42) + continue + + // FIXME Handle extra ExifOffset in IFD1 (thumbnail) + if (index == 43) + continue + val bytes = KimTestData.getBytesOf(index) val expectedMetadata = Kim.readMetadata(bytes) as ImageMetadata @@ -297,9 +325,10 @@ class JpegRewriterTest { if (!bytesEqual) { - fail( - "Value mismatch for image #$index and field ${expectedField.tagFormatted}: " + - "$expectedBytesAsHex != $actualBytesAsHex" + assertEquals( + expected = expectedBytesAsHex, + actual = actualBytesAsHex, + message = "Value mismatch for image #$index and field ${expectedField.tagFormatted}" ) } } diff --git a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegSegmentAnalyzerTest.kt b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegSegmentAnalyzerTest.kt index a70b2a6f..fdbc2094 100644 --- a/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegSegmentAnalyzerTest.kt +++ b/src/commonTest/kotlin/com/ashampoo/kim/format/jpeg/JpegSegmentAnalyzerTest.kt @@ -613,120 +613,6 @@ class JpegSegmentAnalyzerTest { JpegSegmentAnalyzer.JpegSegmentInfo(29348, 65498, 1651935), JpegSegmentAnalyzer.JpegSegmentInfo(1681283, 65497, 2), ), - 41 to listOf( - JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), - JpegSegmentAnalyzer.JpegSegmentInfo(2, 65505, 45619), - JpegSegmentAnalyzer.JpegSegmentInfo(45621, 65517, 78), - JpegSegmentAnalyzer.JpegSegmentInfo(45699, 65505, 2814), - JpegSegmentAnalyzer.JpegSegmentInfo(48513, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(48582, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(48651, 65472, 19), - JpegSegmentAnalyzer.JpegSegmentInfo(48670, 65476, 30), - JpegSegmentAnalyzer.JpegSegmentInfo(48700, 65476, 66), - JpegSegmentAnalyzer.JpegSegmentInfo(48766, 65476, 28), - JpegSegmentAnalyzer.JpegSegmentInfo(48794, 65476, 40), - JpegSegmentAnalyzer.JpegSegmentInfo(48834, 65498, 911992), - JpegSegmentAnalyzer.JpegSegmentInfo(960826, 65497, 2), - ), - 42 to listOf( - JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), - JpegSegmentAnalyzer.JpegSegmentInfo(2, 65505, 21950), - JpegSegmentAnalyzer.JpegSegmentInfo(21952, 65517, 21320), - JpegSegmentAnalyzer.JpegSegmentInfo(43272, 65506, 3162), - JpegSegmentAnalyzer.JpegSegmentInfo(46434, 65505, 15499), - JpegSegmentAnalyzer.JpegSegmentInfo(61933, 65518, 16), - JpegSegmentAnalyzer.JpegSegmentInfo(61949, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(62018, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(62087, 65472, 19), - JpegSegmentAnalyzer.JpegSegmentInfo(62106, 65476, 30), - JpegSegmentAnalyzer.JpegSegmentInfo(62136, 65476, 76), - JpegSegmentAnalyzer.JpegSegmentInfo(62212, 65476, 28), - JpegSegmentAnalyzer.JpegSegmentInfo(62240, 65476, 45), - JpegSegmentAnalyzer.JpegSegmentInfo(62285, 65498, 1485660), - JpegSegmentAnalyzer.JpegSegmentInfo(1547945, 65497, 2), - ), - 43 to listOf( - JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), - JpegSegmentAnalyzer.JpegSegmentInfo(2, 65504, 22), - JpegSegmentAnalyzer.JpegSegmentInfo(24, 65505, 2116), - JpegSegmentAnalyzer.JpegSegmentInfo(2140, 65506, 90), - JpegSegmentAnalyzer.JpegSegmentInfo(2230, 65506, 566), - JpegSegmentAnalyzer.JpegSegmentInfo(2796, 65517, 114), - JpegSegmentAnalyzer.JpegSegmentInfo(2910, 65505, 2814), - JpegSegmentAnalyzer.JpegSegmentInfo(5724, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(5793, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(5862, 65472, 19), - JpegSegmentAnalyzer.JpegSegmentInfo(5881, 65476, 30), - JpegSegmentAnalyzer.JpegSegmentInfo(5911, 65476, 77), - JpegSegmentAnalyzer.JpegSegmentInfo(5988, 65476, 26), - JpegSegmentAnalyzer.JpegSegmentInfo(6014, 65476, 40), - JpegSegmentAnalyzer.JpegSegmentInfo(6054, 65498, 1216476), - JpegSegmentAnalyzer.JpegSegmentInfo(1222530, 65497, 2), - ), - 44 to listOf( - JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), - JpegSegmentAnalyzer.JpegSegmentInfo(2, 65505, 18248), - JpegSegmentAnalyzer.JpegSegmentInfo(18250, 65517, 116), - JpegSegmentAnalyzer.JpegSegmentInfo(18366, 65505, 2814), - JpegSegmentAnalyzer.JpegSegmentInfo(21180, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(21249, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(21318, 65472, 19), - JpegSegmentAnalyzer.JpegSegmentInfo(21337, 65476, 31), - JpegSegmentAnalyzer.JpegSegmentInfo(21368, 65476, 85), - JpegSegmentAnalyzer.JpegSegmentInfo(21453, 65476, 28), - JpegSegmentAnalyzer.JpegSegmentInfo(21481, 65476, 43), - JpegSegmentAnalyzer.JpegSegmentInfo(21524, 65498, 1607749), - JpegSegmentAnalyzer.JpegSegmentInfo(1629273, 65497, 2), - ), - 45 to listOf( - JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), - JpegSegmentAnalyzer.JpegSegmentInfo(2, 65505, 13662), - JpegSegmentAnalyzer.JpegSegmentInfo(13664, 65505, 30970), - JpegSegmentAnalyzer.JpegSegmentInfo(44634, 65517, 12922), - JpegSegmentAnalyzer.JpegSegmentInfo(57556, 65506, 3162), - JpegSegmentAnalyzer.JpegSegmentInfo(60718, 65518, 16), - JpegSegmentAnalyzer.JpegSegmentInfo(60734, 65534, 54), - JpegSegmentAnalyzer.JpegSegmentInfo(60788, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(60857, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(60926, 65472, 19), - JpegSegmentAnalyzer.JpegSegmentInfo(60945, 65476, 29), - JpegSegmentAnalyzer.JpegSegmentInfo(60974, 65476, 78), - JpegSegmentAnalyzer.JpegSegmentInfo(61052, 65476, 28), - JpegSegmentAnalyzer.JpegSegmentInfo(61080, 65476, 50), - JpegSegmentAnalyzer.JpegSegmentInfo(61130, 65498, 1245290), - JpegSegmentAnalyzer.JpegSegmentInfo(1306420, 65497, 2), - ), - 46 to listOf( - JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), - JpegSegmentAnalyzer.JpegSegmentInfo(2, 65505, 11356), - JpegSegmentAnalyzer.JpegSegmentInfo(11358, 65517, 10788), - JpegSegmentAnalyzer.JpegSegmentInfo(22146, 65506, 3162), - JpegSegmentAnalyzer.JpegSegmentInfo(25308, 65505, 12810), - JpegSegmentAnalyzer.JpegSegmentInfo(38118, 65499, 134), - JpegSegmentAnalyzer.JpegSegmentInfo(38252, 65501, 6), - JpegSegmentAnalyzer.JpegSegmentInfo(38258, 65518, 16), - JpegSegmentAnalyzer.JpegSegmentInfo(38274, 65472, 19), - JpegSegmentAnalyzer.JpegSegmentInfo(38293, 65476, 162), - JpegSegmentAnalyzer.JpegSegmentInfo(38455, 65498, 753335), - JpegSegmentAnalyzer.JpegSegmentInfo(791790, 65497, 2), - ), - 47 to listOf( - JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), - JpegSegmentAnalyzer.JpegSegmentInfo(2, 65505, 12452), - JpegSegmentAnalyzer.JpegSegmentInfo(12454, 65517, 11752), - JpegSegmentAnalyzer.JpegSegmentInfo(24206, 65506, 3162), - JpegSegmentAnalyzer.JpegSegmentInfo(27368, 65505, 27253), - JpegSegmentAnalyzer.JpegSegmentInfo(54621, 65518, 16), - JpegSegmentAnalyzer.JpegSegmentInfo(54637, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(54706, 65499, 69), - JpegSegmentAnalyzer.JpegSegmentInfo(54775, 65472, 19), - JpegSegmentAnalyzer.JpegSegmentInfo(54794, 65476, 30), - JpegSegmentAnalyzer.JpegSegmentInfo(54824, 65476, 79), - JpegSegmentAnalyzer.JpegSegmentInfo(54903, 65476, 29), - JpegSegmentAnalyzer.JpegSegmentInfo(54932, 65476, 50), - JpegSegmentAnalyzer.JpegSegmentInfo(54982, 65498, 1126226), - JpegSegmentAnalyzer.JpegSegmentInfo(1181208, 65497, 2), - ), 48 to listOf( JpegSegmentAnalyzer.JpegSegmentInfo(0, 65496, 2), JpegSegmentAnalyzer.JpegSegmentInfo(2, 65505, 13524), @@ -771,10 +657,14 @@ class JpegSegmentAnalyzerTest { @Test fun testFindSegmentInfos() { + // TODO Refresh data + val outdatedData = setOf( + 8, 9, 18, 19, 41, 42, 43, 44, 45, 46, 47 + ) + for (index in 1..KimTestData.HIGHEST_JPEG_INDEX) { - // TODO Refresh data - if (index == 8 || index == 9 || index == 18 || index == 19) + if (outdatedData.contains(index)) continue val bytes = KimTestData.getBytesOf(index) diff --git a/src/commonTest/kotlin/com/ashampoo/kim/testdata/KimTestData.kt b/src/commonTest/kotlin/com/ashampoo/kim/testdata/KimTestData.kt index f15c103f..342a81ac 100644 --- a/src/commonTest/kotlin/com/ashampoo/kim/testdata/KimTestData.kt +++ b/src/commonTest/kotlin/com/ashampoo/kim/testdata/KimTestData.kt @@ -70,7 +70,7 @@ object KimTestData { val photoIdsWithExifThumbnail: Set = setOf( 2, 3, 4, 5, 6, 7, 10, 12, 15, 16, 19, 20, 21, 22, 24, 25, 27, 28, 29, 30, 31, 32, 33, 35, 37, - 38, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 50, + 38, 39, 40, 41, 42, 46, 48, 49, 50, PNG_TEST_IMAGE_INDEX, PNG_GIMP_TEST_IMAGE_INDEX, CR2_TEST_IMAGE_INDEX, diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_41_exifthumb.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_41_exifthumb.jpg index 8790c914..0961f5d6 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_41_exifthumb.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_41_exifthumb.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_42_exifthumb.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_42_exifthumb.jpg index 487c8e61..dc53b2a5 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_42_exifthumb.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_42_exifthumb.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_46_exifthumb.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_46_exifthumb.jpg index 64a8535b..8ecb4451 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_46_exifthumb.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/exifthumbs/photo_46_exifthumb.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/README.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/full/README.txt index 7eb62326..d464d85d 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/full/README.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/full/README.txt @@ -9,6 +9,13 @@ photo_21.jpg = Corrupted IFD1 (thumbnail) photo_22.jpg = Non-corrupted version of photo_30.jpg photo_23.jpg = Nothing Phone OOC-JPEG (50 MP) photo_30.jpg = Multiple APP1 +photo_41.jpg = Long APP1 +photo_42.jpg = Broken, normal fields point into Makernote space. +photo_43.jpg = IFD1 (Thumbnail) has its own ExifOffset. +photo_44.jpg = Broken, but can be read by ExifTool (wrong segment size) +photo_45.jpg = Broken, but can be read by ExifTool (no SOFN = no image size) +photo_46.jpg = Broken, but can be read by ExifTool (ExifOffset field corrupt) +photo_47.jpg = Broken, but can be read by ExifTool (zero segment size) photo_48.jpg = iPhone SE OOC-JPEG photo_49.jpg = Canon 60D OOC-JPEG photo_50.jpg = Fuji X-T4 OOC-JPEG diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_41.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_41.jpg old mode 100755 new mode 100644 index fc466d8f..fde9c9f4 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_41.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_41.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_42.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_42.jpg old mode 100755 new mode 100644 index 88598a3c..ebdb5854 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_42.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_42.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_43.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_43.jpg old mode 100755 new mode 100644 index e29f1d78..d659d03d Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_43.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_43.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_44.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_44.jpg old mode 100755 new mode 100644 index 1ff8e1a0..63291baa Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_44.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_44.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_45.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_45.jpg old mode 100755 new mode 100644 index dd4676fb..782ab790 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_45.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_45.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_46.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_46.jpg old mode 100755 new mode 100644 index fcdcb993..c1e58a96 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_46.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_46.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_47.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_47.jpg old mode 100755 new mode 100644 index fbc51693..684a8f95 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_47.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/full/photo_47.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_41_header.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_41_header.jpg index 9be6c448..5bafdcac 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_41_header.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_41_header.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_42_header.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_42_header.jpg index 5ab9ea70..eee7b2c4 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_42_header.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_42_header.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_43_header.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_43_header.jpg index c57811a2..0185396a 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_43_header.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_43_header.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_44_header.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_44_header.jpg index 540b3189..19815bb6 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_44_header.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_44_header.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_45_header.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_45_header.jpg index d248c72a..9fc3b1dc 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_45_header.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_45_header.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_46_header.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_46_header.jpg index 62846c15..ec83877b 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_46_header.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_46_header.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_47_header.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_47_header.jpg index b3d7a466..21aa3d10 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_47_header.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/headers/photo_47_header.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/metadata.csv b/src/commonTest/resources/com/ashampoo/kim/testdata/metadata.csv index 89d0d623..53db656c 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/metadata.csv +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/metadata.csv @@ -39,13 +39,13 @@ photo_37.jpg;5870;2799;STANDARD;1532721723350;null;null;NIKON CORPORATION;NIKON photo_38.jpg;2371;1580;STANDARD;1399301366760;null;null;Canon;Canon EOS 550D;null;EF70-200mm f/4L USM;400;8.0E-4;4.0;154.0;false;2;[foal];[];[];160 x 107;11065 photo_39.jpg;4608;3456;STANDARD;1466260726000;null;null;OLYMPUS IMAGING CORP. ;E-M10 ;null;OLYMPUS M.40-150mm F4.0-5.6 R;400;0.0125;5.0;102.0;false;1;[];[];[];160 x 120;9032 photo_40.jpg;4272;2848;STANDARD;1561620317200;null;null;NIKON CORPORATION;NIKON D500;null;70.0-200.0 mm f/2.8;320;0.003125;8.0;86.0;false;3;[wildlife, bear];[];[];160 x 107;3320 -photo_41.jpg;4928;3264;STANDARD;1503579240000;null;null;PENTAX ;PENTAX K-50 ;null;null;1600;0.0025;3.5;18.0;false;1;[outdoors];[];[];160 x 120;6551 -photo_42.jpg;3870;3131;null;1570103057900;null;null;Canon;Canon EOS 7D Mark II;null;EF100-400mm f/4.5-5.6L IS II USM;640;0.00125;5.6;400.0;false;4;[animal, grass, plant, finch, lawn, bird, reed];[];[];256 x 207;20962 -photo_43.jpg;4032;3024;null;1553273402935;34.463058333333336;-119.75821666666667;Apple;iPhone XS;Apple;iPhone XS back dual camera 6mm f/2.4;50;0.00819672131147541;2.4;6.0;false;4;[nature, field, grassland, outdoors];[];[];null;null -photo_44.jpg;6000;4000;STANDARD;1539078920860;null;null;Canon;Canon EOS 77D;null;EF100-400mm f/4.5-5.6L IS USM;400;0.002;8.0;400.0;false;2;[animal, bald eagle, eagle, bird];[];[];160 x 120;7437 -photo_45.jpg;3594;2446;STANDARD;1500308474000;null;null;SONY;ILCE-7S;null;FE 24-240mm F3.5-6.3 OSS;800;0.0015625;6.3;240.0;false;2;[];[];[];256 x 174;12731 -photo_46.jpg;4390;2927;null;1540041598620;null;null;Canon;Canon EOS 6D;null;100mm;125;0.005;2.0;100.0;false;0;[canine, wildlife, red fox, pet, animal, mammal, dog, fox];[];[];256 x 171;10447 -photo_47.jpg;3038;3038;null;1531503487000;null;null;OLYMPUS IMAGING CORP.;E-M5MarkII;null;OLYMPUS M.40-150mm F2.8;500;0.003125;2.8;150.0;false;2;[bird, animal, outdoors, duck];[];[];256 x 256;11446 +photo_41.jpg;3264;1836;STANDARD;1258791581000;null;null;Sony Ericsson;U10i;null;null;50;0.001;2.8;4.65;false;null;[];[];[];160 x 120;7053 +photo_42.jpg;1024;768;STANDARD;1011527566000;null;null;TRAVELER OPTICAL CO,LTD;SX330Z;null;null;100;null;null;23.28;false;null;[];[];[];160 x 120;6495 +photo_43.jpg;1024;768;STANDARD;1146003974000;null;null;Digital;Digital Cam;null;null;100;0.0031577418356584838;7.4;10.04;false;null;[];[];[];null;null +photo_44.jpg;2820;3077;null;null;null;null;null;null;null;null;null;null;null;null;false;null;[];[];[];null;null +photo_45.jpg;null;null;null;null;null;null;null;null;null;null;null;null;null;null;false;null;[];[];[];null;null +photo_46.jpg;325;407;STANDARD;null;null;null;null;null;null;null;null;null;null;null;false;null;[];[];[];102 x 128;3664 +photo_47.jpg;260;773;null;null;null;null;null;null;null;null;null;null;null;null;false;null;[];[];[];null;null photo_48.jpg;4032;3024;ROTATE_RIGHT;1669813020203;null;null;Apple;iPhone SE (3rd generation);Apple;iPhone SE (3rd generation) back camera 3.99mm f/1.8;50;0.01;1.8;3.99;false;null;[];[];[];160 x 120;11130 photo_49.jpg;5184;3456;STANDARD;1638761253820;null;null;Canon;Canon EOS 60D;null;EF-S15-85mm f/3.5-5.6 IS USM;400;0.016666666666666666;5.0;24.0;false;0;[];[];[];160 x 120;11200 photo_50.jpg;6240;4160;STANDARD;1684514510000;null;null;FUJIFILM;X-T4;FUJIFILM;XC35mmF2;400;0.025;4.0;35.0;false;0;[];[];[];160 x 120;9359 diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_41_modified.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_41_modified.jpg deleted file mode 100644 index 04256457..00000000 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_41_modified.jpg and /dev/null differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_41_modified.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_41_modified.txt deleted file mode 100644 index 1c4f9557..00000000 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_41_modified.txt +++ /dev/null @@ -1,86 +0,0 @@ -File format : JPEG -Resolution : 4928 x 3264 ----- TIFF ---- -Version 42 -Big-endian (Motorola, MM) ----- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = PENTAX -0000000022 0x0110 Model = PENTAX K-50 -0000000034 0x0112 Orientation = 8 -0000000046 0x011a XResolution = 300/1 (300.0) -0000000058 0x011b YResolution = 300/1 (300.0) -0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0131 Software = K-50 Ver. 1.02 -0000000094 0x0132 ModifyDate = 2023:05:10 13:37:42 -0000000106 0x0213 YCbCrPositioning = 2 -0000000118 0x8769 ExifOffset = 608 -0000000130 0x8825 GPSInfo = 5482 -0000000142 0xc4a5 PrintIM = [350 bytes] - ----- Directory ExifIFD @ 608 ---- -0000000610 0x829a ExposureTime = 1/400 (0.0025) -0000000622 0x829d FNumber = 35/10 (3.5) -0000000634 0x8822 ExposureProgram = 3 -0000000646 0x8827 PhotographicSensitivity = 1600 -0000000658 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000670 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 -0000000682 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 -0000000694 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] -0000000706 0x9204 ExposureCompensation = 0/10 (0.0) -0000000718 0x9207 MeteringMode = 5 -0000000730 0x9209 Flash = 16 -0000000742 0x920a FocalLength = 1800/100 (18.0) -0000000754 0x927c MakerNote = [4382 bytes] -0000000766 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] -0000000778 0xa001 ColorSpace = 1 -0000000790 0xa002 ExifImageWidth = 4928 -0000000802 0xa003 ExifImageLength = 3264 -0000000814 0xa005 InteropOffset = 5452 -0000000826 0xa217 SensingMethod = 2 -0000000838 0xa300 FileSource = 3 -0000000850 0xa301 SceneType = 1 -0000000862 0xa401 CustomRendered = 0 -0000000874 0xa402 ExposureMode = 0 -0000000886 0xa403 WhiteBalance = 0 -0000000898 0xa405 FocalLengthIn35mmFormat = 27 -0000000910 0xa406 SceneCaptureType = 0 -0000000922 0xa408 Contrast = 0 -0000000934 0xa409 Saturation = 0 -0000000946 0xa40a Sharpness = 0 -0000000958 0xa40c SubjectDistanceRange = 2 - ----- Directory InteropIFD @ 5452 ---- -0000005454 0x0001 InteroperabilityIndex = R98 -0000005466 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] - ----- Directory GPS @ 5482 ---- -0000005484 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] -0000005496 0x0001 GPSLatitudeRef = N -0000005508 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] -0000005520 0x0003 GPSLongitudeRef = E -0000005532 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] - ----- Directory SubIFD @ 5572 ---- -0000005574 0x0103 Compression = 6 -0000005586 0x011a XResolution = 300/1 (300.0) -0000005598 0x011b YResolution = 300/1 (300.0) -0000005610 0x0128 ResolutionUnit = 2 -0000005622 0x0201 JpgFromRawStart = 45610 -0000005634 0x0202 JpgFromRawLength = 6551 - - ----- IPTC ---- -Caption/Abstract (120) = 'Antelope Cave, Arizona' -Keywords (25) = 'outdoors' -Keywords (25) = 'Umlauts: äöüß' - ----- XMP ---- - - - - - - - diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.jpg index 2b66efaf..3c1bcfa3 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.txt index 0be07ccf..aa2f623e 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_44_modified.txt @@ -1,86 +1,26 @@ File format : JPEG -Resolution : 6000 x 4000 +Resolution : 2820 x 3077 ---- TIFF ---- Version 42 -Little-endian (Intel, II) +Big-endian (Motorola, MM) ---- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = Canon -0000000022 0x0110 Model = Canon EOS 77D -0000000034 0x0112 Orientation = 8 -0000000046 0x011a XResolution = 72/1 (72.0) -0000000058 0x011b YResolution = 72/1 (72.0) -0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0132 ModifyDate = 2023:05:10 13:37:42 -0000000094 0x013b Artist = HENRIK HANSEN -0000000106 0x0213 YCbCrPositioning = 2 -0000000118 0x8769 ExifOffset = 216 -0000000130 0x8825 GPSInfo = 10408 +0000000010 0x0112 Orientation = 8 +0000000022 0x0132 ModifyDate = 2023:05:10 13:37:42 +0000000034 0x8769 ExifOffset = 84 +0000000046 0x8825 GPSInfo = 156 ----- Directory ExifIFD @ 216 ---- -0000000218 0x829a ExposureTime = 1/500 (0.002) -0000000230 0x829d FNumber = 8/1 (8.0) -0000000242 0x8822 ExposureProgram = 2 -0000000254 0x8827 PhotographicSensitivity = 400 -0000000266 0x8830 SensitivityType = 2 -0000000278 0x8832 RecommendedExposureIndex = 400 -0000000290 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000302 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 -0000000314 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 -0000000326 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] -0000000338 0x9201 ShutterSpeedValue = 589824/65536 (9.0) -0000000350 0x9202 ApertureValue = 393216/65536 (6.0) -0000000362 0x9204 ExposureCompensation = 0/1 (0.0) -0000000374 0x9207 MeteringMode = 5 -0000000386 0x9209 Flash = 16 -0000000398 0x920a FocalLength = 400/1 (400.0) -0000000410 0x927c MakerNote = [9512 bytes] -0000000422 0x9290 SubSecTime = 86 -0000000434 0x9291 SubSecTimeOriginal = 86 -0000000446 0x9292 SubSecTimeDigitized = 86 -0000000458 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] -0000000470 0xa001 ColorSpace = 1 -0000000482 0xa002 ExifImageWidth = 6000 -0000000494 0xa003 ExifImageLength = 4000 -0000000506 0xa005 InteropOffset = 10378 -0000000518 0xa20e FocalPlaneXResolution = 6000000/921 (6514.65798) -0000000530 0xa20f FocalPlaneYResolution = 4000000/594 (6734.006734) -0000000542 0xa210 FocalPlaneResolutionUnit = 2 -0000000554 0xa401 CustomRendered = 0 -0000000566 0xa402 ExposureMode = 0 -0000000578 0xa403 WhiteBalance = 0 -0000000590 0xa406 SceneCaptureType = 0 -0000000602 0xa430 CameraOwnerName = -0000000614 0xa431 BodySerialNumber = 143031003387 -0000000626 0xa432 LensSpecification = [100/1 (100.0), 400/1 (400.0), 0/1 (0.0), 0/1 (0.0)] -0000000638 0xa434 LensModel = EF100-400mm f/4.5-5.6L IS USM -0000000650 0xa435 LensSerialNumber = 0000000000 - ----- Directory InteropIFD @ 10378 ---- -0000010380 0x0001 InteroperabilityIndex = R98 -0000010392 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] - ----- Directory GPS @ 10408 ---- -0000010410 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] -0000010422 0x0001 GPSLatitudeRef = N -0000010434 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] -0000010446 0x0003 GPSLongitudeRef = E -0000010458 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] - ----- Directory SubIFD @ 10522 ---- -0000010524 0x0103 Compression = 6 -0000010536 0x011a XResolution = 72/1 (72.0) -0000010548 0x011b YResolution = 72/1 (72.0) -0000010560 0x0128 ResolutionUnit = 2 -0000010572 0x0201 JpgFromRawStart = 10608 -0000010584 0x0202 JpgFromRawLength = 7437 +---- Directory ExifIFD @ 84 ---- +0000000086 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 +0000000098 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 +---- Directory GPS @ 156 ---- +0000000158 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] +0000000170 0x0001 GPSLatitudeRef = N +0000000182 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] +0000000194 0x0003 GPSLongitudeRef = E +0000000206 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] ---- IPTC ---- -Caption/Abstract (120) = 'American eagle during daytime' -Keywords (25) = 'animal' -Keywords (25) = 'bald eagle' -Keywords (25) = 'eagle' -Keywords (25) = 'bird' Keywords (25) = 'Umlauts: äöüß' ---- XMP ---- @@ -92,4 +32,4 @@ Keywords (25) = 'Umlauts: äöüß' xmp:Rating="3"/> - + \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.jpg index fea3b9c2..cfcf6eb5 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.txt index 621d15fc..84d3800c 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_45_modified.txt @@ -1,78 +1,26 @@ File format : JPEG -Resolution : 3594 x 2446 +Resolution : null ---- TIFF ---- Version 42 -Little-endian (Intel, II) +Big-endian (Motorola, MM) ---- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = SONY -0000000022 0x0110 Model = ILCE-7S -0000000034 0x0112 Orientation = 8 -0000000046 0x011a XResolution = 72/1 (72.0) -0000000058 0x011b YResolution = 72/1 (72.0) -0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0131 Software = Adobe Photoshop Lightroom 6.0 (Macintosh) -0000000094 0x0132 ModifyDate = 2023:05:10 13:37:42 -0000000106 0x8769 ExifOffset = 226 -0000000118 0x8825 GPSInfo = 932 +0000000010 0x0112 Orientation = 8 +0000000022 0x0132 ModifyDate = 2023:05:10 13:37:42 +0000000034 0x8769 ExifOffset = 84 +0000000046 0x8825 GPSInfo = 156 ----- Directory ExifIFD @ 226 ---- -0000000228 0x829a ExposureTime = 1/640 (0.001563) -0000000240 0x829d FNumber = 63/10 (6.3) -0000000252 0x8822 ExposureProgram = 1 -0000000264 0x8827 PhotographicSensitivity = 800 -0000000276 0x8830 SensitivityType = 2 -0000000288 0x8832 RecommendedExposureIndex = 800 -0000000300 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000312 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 -0000000324 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 -0000000336 0x9201 ShutterSpeedValue = 9321928/1000000 (9.321928) -0000000348 0x9202 ApertureValue = 5310704/1000000 (5.310704) -0000000360 0x9203 BrightnessValue = 16234/2560 (6.341406) -0000000372 0x9204 ExposureCompensation = 0/10 (0.0) -0000000384 0x9205 MaxApertureValue = 1360/256 (5.3125) -0000000396 0x9207 MeteringMode = 5 -0000000408 0x9208 LightSource = 11 -0000000420 0x9209 Flash = 16 -0000000432 0x920a FocalLength = 2400/10 (240.0) -0000000444 0xa001 ColorSpace = 1 -0000000456 0xa20e FocalPlaneXResolution = 38690215/32768 (1180.731659) -0000000468 0xa20f FocalPlaneYResolution = 38690215/32768 (1180.731659) -0000000480 0xa210 FocalPlaneResolutionUnit = 3 -0000000492 0xa300 FileSource = 3 -0000000504 0xa301 SceneType = 1 -0000000516 0xa401 CustomRendered = 0 -0000000528 0xa402 ExposureMode = 1 -0000000540 0xa403 WhiteBalance = 1 -0000000552 0xa404 DigitalZoomRatio = 16/16 (1.0) -0000000564 0xa405 FocalLengthIn35mmFormat = 240 -0000000576 0xa406 SceneCaptureType = 0 -0000000588 0xa408 Contrast = 0 -0000000600 0xa409 Saturation = 0 -0000000612 0xa40a Sharpness = 0 -0000000624 0xa432 LensSpecification = [240/10 (24.0), 2400/10 (240.0), 35/10 (3.5), 63/10 (6.3)] -0000000636 0xa434 LensModel = FE 24-240mm F3.5-6.3 OSS - ----- Directory GPS @ 932 ---- -0000000934 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] -0000000946 0x0001 GPSLatitudeRef = N -0000000958 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] -0000000970 0x0003 GPSLongitudeRef = E -0000000982 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] - ----- Directory SubIFD @ 838 ---- -0000000840 0x0103 Compression = 6 -0000000852 0x011a XResolution = 72/1 (72.0) -0000000864 0x011b YResolution = 72/1 (72.0) -0000000876 0x0128 ResolutionUnit = 2 -0000000888 0x0201 JpgFromRawStart = 13652 -0000000900 0x0202 JpgFromRawLength = 12731 +---- Directory ExifIFD @ 84 ---- +0000000086 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 +0000000098 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 +---- Directory GPS @ 156 ---- +0000000158 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] +0000000170 0x0001 GPSLatitudeRef = N +0000000182 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] +0000000194 0x0003 GPSLongitudeRef = E +0000000206 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] ---- IPTC ---- -Digital Creation Time (63) = '182114' -Digital Creation Date (62) = '20170717' -Time Created (60) = '182114' -Date Created (55) = '20170717' Keywords (25) = 'Umlauts: äöüß' ---- XMP ---- @@ -84,4 +32,4 @@ Keywords (25) = 'Umlauts: äöüß' xmp:Rating="3"/> - + \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.jpg index ca835fe7..f2effb45 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.txt index 1d852eee..673e5e55 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_46_modified.txt @@ -1,86 +1,35 @@ File format : JPEG -Resolution : 4390 x 2927 +Resolution : 325 x 407 ---- TIFF ---- Version 42 -Little-endian (Intel, II) ----- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = Canon -0000000022 0x0110 Model = Canon EOS 6D -0000000034 0x0112 Orientation = 8 -0000000046 0x011a XResolution = 72/1 (72.0) -0000000058 0x011b YResolution = 72/1 (72.0) -0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0131 Software = Adobe Photoshop Lightroom Classic 8.0 (Macintosh) -0000000094 0x0132 ModifyDate = 2023:05:10 13:37:42 -0000000106 0x013b Artist = Jonathan Cooper -0000000118 0x8298 Copyright = 2014 -0000000130 0x8769 ExifOffset = 286 -0000000142 0x8825 GPSInfo = 922 +Big-endian (Motorola, MM) +---- Directory IFD0 @ 200 ---- +0000000202 0x0112 Orientation = 8 +0000000214 0x0131 Software = Adobe Photoshop 7.0 +0000000226 0x0132 ModifyDate = 2023:05:10 13:37:42 +0000000238 0x8769 ExifOffset = 122 +0000000250 0x8825 GPSInfo = 4048 ----- Directory ExifIFD @ 286 ---- -0000000288 0x829a ExposureTime = 1/200 (0.005) -0000000300 0x829d FNumber = 2/1 (2.0) -0000000312 0x8822 ExposureProgram = 1 -0000000324 0x8827 PhotographicSensitivity = 125 -0000000336 0x8830 SensitivityType = 2 -0000000348 0x8832 RecommendedExposureIndex = 125 -0000000360 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000372 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 -0000000384 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 -0000000396 0x9201 ShutterSpeedValue = 7643856/1000000 (7.643856) -0000000408 0x9202 ApertureValue = 2/1 (2.0) -0000000420 0x9204 ExposureCompensation = 0/1 (0.0) -0000000432 0x9205 MaxApertureValue = 2/1 (2.0) -0000000444 0x9207 MeteringMode = 5 -0000000456 0x9209 Flash = 16 -0000000468 0x920a FocalLength = 100/1 (100.0) -0000000480 0x9291 SubSecTimeOriginal = 62 -0000000492 0x9292 SubSecTimeDigitized = 62 -0000000504 0xa001 ColorSpace = 1 -0000000516 0xa20e FocalPlaneXResolution = 49807360/32768 (1520.0) -0000000528 0xa20f FocalPlaneYResolution = 49807360/32768 (1520.0) -0000000540 0xa210 FocalPlaneResolutionUnit = 3 -0000000552 0xa401 CustomRendered = 0 -0000000564 0xa402 ExposureMode = 1 -0000000576 0xa403 WhiteBalance = 0 -0000000588 0xa406 SceneCaptureType = 0 -0000000600 0xa431 BodySerialNumber = 022123002072 -0000000612 0xa432 LensSpecification = [100/1 (100.0), 100/1 (100.0), Invalid rational (0/0), Invalid rational (0/0)] -0000000624 0xa434 LensModel = 100mm -0000000636 0xa435 LensSerialNumber = 0000000000 +---- Directory ExifIFD @ 122 ---- +0000000124 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 +0000000136 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 ----- Directory GPS @ 922 ---- -0000000924 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] -0000000936 0x0001 GPSLatitudeRef = N -0000000948 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] -0000000960 0x0003 GPSLongitudeRef = E -0000000972 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] - ----- Directory SubIFD @ 828 ---- -0000000830 0x0103 Compression = 6 -0000000842 0x011a XResolution = 72/1 (72.0) -0000000854 0x011b YResolution = 72/1 (72.0) -0000000866 0x0128 ResolutionUnit = 2 -0000000878 0x0201 JpgFromRawStart = 11346 -0000000890 0x0202 JpgFromRawLength = 10447 +---- Directory GPS @ 4048 ---- +0000004050 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] +0000004062 0x0001 GPSLatitudeRef = N +0000004074 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] +0000004086 0x0003 GPSLongitudeRef = E +0000004098 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] +---- Directory IFD1 @ 266 ---- +0000000268 0x0103 Compression = 6 +0000000280 0x011a XResolution = 72/851969 (8.5E-5) +0000000292 0x011b YResolution = 72/1 (72.0) +0000000304 0x0128 ResolutionUnit = 2 +0000000316 0x0201 JpgFromRawStart = 344 +0000000328 0x0202 JpgFromRawLength = 3664 ---- IPTC ---- -Caption/Abstract (120) = 'orange fox walking on street' -Copyright Notice (116) = '2014' -By-line (80) = 'Jonathan Cooper' -Digital Creation Time (63) = '151958' -Digital Creation Date (62) = '20181020' -Time Created (60) = '151958' -Date Created (55) = '20181020' -Keywords (25) = 'canine' -Keywords (25) = 'wildlife' -Keywords (25) = 'red fox' -Keywords (25) = 'pet' -Keywords (25) = 'animal' -Keywords (25) = 'mammal' -Keywords (25) = 'dog' -Keywords (25) = 'fox' Keywords (25) = 'Umlauts: äöüß' ---- XMP ---- @@ -92,4 +41,4 @@ Keywords (25) = 'Umlauts: äöüß' xmp:Rating="3"/> - + \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.jpg b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.jpg index 50479a23..e24176e8 100644 Binary files a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.jpg and b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.jpg differ diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.txt index d0033824..20bb8a80 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/modified/photo_47_modified.txt @@ -1,85 +1,26 @@ File format : JPEG -Resolution : 3038 x 3038 +Resolution : 260 x 773 ---- TIFF ---- Version 42 -Little-endian (Intel, II) +Big-endian (Motorola, MM) ---- Directory IFD0 @ 8 ---- -0000000010 0x010e ImageDescription = OLYMPUS DIGITAL CAMERA -0000000022 0x010f Make = OLYMPUS IMAGING CORP. -0000000034 0x0110 Model = E-M5MarkII -0000000046 0x0112 Orientation = 8 -0000000058 0x011a XResolution = 240/1 (240.0) -0000000070 0x011b YResolution = 240/1 (240.0) -0000000082 0x0128 ResolutionUnit = 2 -0000000094 0x0131 Software = Adobe Photoshop Lightroom 6.14 (Windows) -0000000106 0x0132 ModifyDate = 2023:05:10 13:37:42 -0000000118 0x8769 ExifOffset = 282 -0000000130 0x8825 GPSInfo = 12466 +0000000010 0x0112 Orientation = 8 +0000000022 0x0132 ModifyDate = 2023:05:10 13:37:42 +0000000034 0x8769 ExifOffset = 84 +0000000046 0x8825 GPSInfo = 156 ----- Directory ExifIFD @ 282 ---- -0000000284 0x829a ExposureTime = 1/320 (0.003125) -0000000296 0x829d FNumber = 28/10 (2.8) -0000000308 0x8822 ExposureProgram = 3 -0000000320 0x8827 PhotographicSensitivity = 500 -0000000332 0x8830 SensitivityType = 1 -0000000344 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000356 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 -0000000368 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 -0000000380 0x9201 ShutterSpeedValue = 8321928/1000000 (8.321928) -0000000392 0x9202 ApertureValue = 2970854/1000000 (2.970854) -0000000404 0x9204 ExposureCompensation = 0/10 (0.0) -0000000416 0x9205 MaxApertureValue = 768/256 (3.0) -0000000428 0x9207 MeteringMode = 5 -0000000440 0x9208 LightSource = 0 -0000000452 0x9209 Flash = 24 -0000000464 0x920a FocalLength = 150/1 (150.0) -0000000476 0xa001 ColorSpace = 1 -0000000488 0xa20e FocalPlaneXResolution = 87196351/32768 (2661.021454) -0000000500 0xa20f FocalPlaneYResolution = 87196351/32768 (2661.021454) -0000000512 0xa210 FocalPlaneResolutionUnit = 3 -0000000524 0xa300 FileSource = 3 -0000000536 0xa302 CFAPattern = [0x02, 0x00, 0x02, 0x00, 0x00, 0x01, 0x01, 0x02] -0000000548 0xa401 CustomRendered = 0 -0000000560 0xa402 ExposureMode = 0 -0000000572 0xa403 WhiteBalance = 0 -0000000584 0xa404 DigitalZoomRatio = 100/100 (1.0) -0000000596 0xa405 FocalLengthIn35mmFormat = 300 -0000000608 0xa406 SceneCaptureType = 0 -0000000620 0xa407 GainControl = 2 -0000000632 0xa408 Contrast = 0 -0000000644 0xa409 Saturation = 0 -0000000656 0xa40a Sharpness = 0 -0000000668 0xa431 BodySerialNumber = BHEA65641 -0000000680 0xa432 LensSpecification = [40/1 (40.0), 150/1 (150.0), 28/10 (2.8), 28/10 (2.8)] -0000000692 0xa434 LensModel = OLYMPUS M.40-150mm F2.8 -0000000704 0xa435 LensSerialNumber = ABV25833600 - ----- Directory GPS @ 12466 ---- -0000012468 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] -0000012480 0x0001 GPSLatitudeRef = N -0000012492 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] -0000012504 0x0003 GPSLongitudeRef = E -0000012516 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] - ----- Directory SubIFD @ 926 ---- -0000000928 0x0103 Compression = 6 -0000000940 0x011a XResolution = 72/1 (72.0) -0000000952 0x011b YResolution = 72/1 (72.0) -0000000964 0x0128 ResolutionUnit = 2 -0000000976 0x0201 JpgFromRawStart = 1020 -0000000988 0x0202 JpgFromRawLength = 11446 +---- Directory ExifIFD @ 84 ---- +0000000086 0x9003 DateTimeOriginal = 2023:05:10 13:37:42 +0000000098 0x9004 DateTimeDigitized = 2023:05:10 13:37:42 +---- Directory GPS @ 156 ---- +0000000158 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] +0000000170 0x0001 GPSLatitudeRef = N +0000000182 0x0002 GPSLatitude = [53/1 (53.0), 13/1 (13.0), 24519/2500 (9.8076)] +0000000194 0x0003 GPSLongitudeRef = E +0000000206 0x0004 GPSLongitude = [8/1 (8.0), 14/1 (14.0), 56949/2500 (22.7796)] ---- IPTC ---- -Caption/Abstract (120) = 'three yellow ducklings on body of water in close-up photography' -Digital Creation Time (63) = '193807' -Digital Creation Date (62) = '20180713' -Time Created (60) = '193807' -Date Created (55) = '20180713' -Keywords (25) = 'bird' -Keywords (25) = 'animal' -Keywords (25) = 'outdoors' -Keywords (25) = 'duck' Keywords (25) = 'Umlauts: äöüß' ---- XMP ---- @@ -91,4 +32,4 @@ Keywords (25) = 'Umlauts: äöüß' xmp:Rating="3"/> - + \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_41.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_41.txt index 91cb99fe..6f9ca76a 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_41.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_41.txt @@ -1,108 +1,57 @@ File format : JPEG -Resolution : 4928 x 3264 +Resolution : 3264 x 1836 ---- TIFF ---- Version 42 -Big-endian (Motorola, MM) +Little-endian (Intel, II) ---- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = PENTAX -0000000022 0x0110 Model = PENTAX K-50 +0000000010 0x010f Make = Sony Ericsson +0000000022 0x0110 Model = U10i 0000000034 0x0112 Orientation = 1 -0000000046 0x011a XResolution = 300/1 (300.0) -0000000058 0x011b YResolution = 300/1 (300.0) +0000000046 0x011a XResolution = 72/1 (72.0) +0000000058 0x011b YResolution = 72/1 (72.0) 0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0131 Software = K-50 Ver. 1.02 -0000000094 0x0132 ModifyDate = 2017:08:24 14:54:00 -0000000106 0x013b Artist = -0000000118 0x0213 YCbCrPositioning = 2 -0000000130 0x8298 Copyright = -0000000142 0x8769 ExifOffset = 632 -0000000154 0x8825 GPSInfo = 5482 -0000000166 0xc4a5 PrintIM = [350 bytes] +0000000082 0x0131 Software = R1CA008 prg1223-3004_GENERIC_RA d:179.1 f:53 h:50 +0000000094 0x0132 ModifyDate = 2009:11:21 10:19:43 +0000000106 0x0213 YCbCrPositioning = 2 +0000000118 0x8769 ExifOffset = 134 ----- Directory ExifIFD @ 632 ---- -0000000634 0x829a ExposureTime = 1/400 (0.0025) -0000000646 0x829d FNumber = 35/10 (3.5) -0000000658 0x8822 ExposureProgram = 3 -0000000670 0x8827 ISO = 1600 -0000000682 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000694 0x9003 DateTimeOriginal = 2017:08:24 14:54:00 -0000000706 0x9004 DateTimeDigitized = 2017:08:24 14:54:00 -0000000718 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] -0000000730 0x9204 ExposureCompensation = 0/10 (0.0) -0000000742 0x9207 MeteringMode = 5 -0000000754 0x9209 Flash = 16 -0000000766 0x920a FocalLength = 1800/100 (18.0) -0000000778 0x927c MakerNote = [4382 bytes] -0000000790 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] -0000000802 0xa001 ColorSpace = 1 -0000000814 0xa002 ExifImageWidth = 4928 -0000000826 0xa003 ExifImageHeight = 3264 -0000000838 0xa005 InteropOffset = 5452 -0000000850 0xa217 SensingMethod = 2 -0000000862 0xa300 FileSource = 3 -0000000874 0xa301 SceneType = 1 -0000000886 0xa401 CustomRendered = 0 -0000000898 0xa402 ExposureMode = 0 -0000000910 0xa403 WhiteBalance = 0 -0000000922 0xa405 FocalLengthIn35mmFormat = 27 -0000000934 0xa406 SceneCaptureType = 0 -0000000946 0xa408 Contrast = 0 -0000000958 0xa409 Saturation = 0 -0000000970 0xa40a Sharpness = 0 -0000000982 0xa40c SubjectDistanceRange = 2 +---- Directory ExifIFD @ 134 ---- +0000000136 0x829a ExposureTime = 1/1000 (0.001) +0000000148 0x829d FNumber = 280/100 (2.8) +0000000160 0x8827 ISO = 50 +0000000172 0x9000 ExifVersion = [0x30, 0x32, 0x32, 0x30] +0000000184 0x9003 DateTimeOriginal = 2009:11:21 10:19:41 +0000000196 0x9004 DateTimeDigitized = 2009:11:21 10:19:43 +0000000208 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] +0000000220 0x9204 ExposureCompensation = 0/100 (0.0) +0000000232 0x9207 MeteringMode = 2 +0000000244 0x9208 LightSource = 0 +0000000256 0x9209 Flash = 0 +0000000268 0x920a FocalLength = 465/100 (4.65) +0000000280 0x927c MakerNote = [51930 bytes] +0000000292 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] +0000000304 0xa001 ColorSpace = 1 +0000000316 0xa002 ExifImageWidth = 3264 +0000000328 0xa003 ExifImageHeight = 1836 +0000000340 0xa005 InteropOffset = 416 +0000000352 0xa401 CustomRendered = 0 +0000000364 0xa402 ExposureMode = 0 +0000000376 0xa403 WhiteBalance = 0 +0000000388 0xa404 DigitalZoomRatio = 100/100 (1.0) +0000000400 0xa406 SceneCaptureType = 0 ----- Directory InteropIFD @ 5452 ---- -0000005454 0x0001 InteroperabilityIndex = R98 -0000005466 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] +---- Directory InteropIFD @ 416 ---- +0000000418 0x0001 InteroperabilityIndex = R98 +0000000430 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] ----- Directory GPS @ 5482 ---- -0000005484 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] - ----- Directory IFD1 @ 5500 ---- -0000005502 0x0103 Compression = 6 -0000005514 0x011a XResolution = 300/1 (300.0) -0000005526 0x011b YResolution = 300/1 (300.0) -0000005538 0x0128 ResolutionUnit = 2 -0000005550 0x0201 JpgFromRawStart = 5594 -0000005562 0x0202 JpgFromRawLength = 6551 - ----- IPTC ---- -Caption/Abstract (120) = 'Antelope Cave, Arizona' -Keywords (25) = 'outdoors' +---- Directory IFD1 @ 446 ---- +0000000448 0x0103 Compression = 6 +0000000460 0x0112 Orientation = 1 +0000000472 0x011a XResolution = 72/1 (72.0) +0000000484 0x011b YResolution = 72/1 (72.0) +0000000496 0x0128 ResolutionUnit = 2 +0000000508 0x0201 JpgFromRawStart = 52672 +0000000520 0x0202 JpgFromRawLength = 7053 ---- XMP ---- - - - - - - 1 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file +46004236502803460-0-4236-50280 \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_42.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_42.txt index 8445eae2..25df969e 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_42.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_42.txt @@ -1,409 +1,51 @@ File format : JPEG -Resolution : 3870 x 3131 +Resolution : 1024 x 768 ---- TIFF ---- Version 42 Little-endian (Intel, II) ---- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = Canon -0000000022 0x0110 Model = Canon EOS 7D Mark II -0000000034 0x011a XResolution = 240/1 (240.0) -0000000046 0x011b YResolution = 240/1 (240.0) -0000000058 0x0128 ResolutionUnit = 2 -0000000070 0x0131 Software = Adobe Photoshop Lightroom Classic 8.4.1 (Windows) -0000000082 0x0132 ModifyDate = 2019:10:09 20:46:41 -0000000094 0x013b Artist = Zdenek & Eva Machackovi -0000000106 0x8298 Copyright = ZEphoto.zenfolio.com -0000000118 0x8769 ExifOffset = 294 +0000000010 0x010e ImageDescription = TRAVELER DIGITAL CAMERA +0000000022 0x010f Make = TRAVELER OPTICAL CO,LTD +0000000034 0x0110 Model = SX330Z +0000000046 0x0112 Orientation = 1 +0000000058 0x011a XResolution = 72/1 (72.0) +0000000070 0x011b YResolution = 72/1 (72.0) +0000000082 0x0128 ResolutionUnit = 2 +0000000094 0x0131 Software = v951-78 +0000000106 0x0132 ModifyDate = 2001:12:00 00:00:00 +0000000118 0x0213 YCbCrPositioning = 2 +0000000130 0x8769 ExifOffset = 284 + +---- Directory ExifIFD @ 284 ---- +0000000286 0x8827 ISO = 100 +0000000298 0x9000 ExifVersion = [0x30, 0x32, 0x31, 0x30] +0000000310 0x9003 DateTimeOriginal = 2002:01:20 13:52:46 +0000000322 0x9004 DateTimeDigitized = 2002:01:20 13:52:44 +0000000334 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] +0000000346 0x9102 CompressedBitsPerPixel = 200/1572 (0.127226) +0000000358 0x9201 ShutterSpeedValue = 49/8 (6.125) +0000000370 0x9202 ApertureValue = 35055/10000 (3.5055) +0000000382 0x9204 ExposureCompensation = 0/10 (0.0) +0000000394 0x9206 Subject Distance = Invalid rational (0/0) +0000000406 0x9207 MeteringMode = 0 +0000000418 0x9209 Flash = 1 +0000000430 0x920a FocalLength = 23280/1000 (23.28) +0000000442 0x927c MakerNote = [264 bytes] +0000000454 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] +0000000466 0xa001 ColorSpace = 1 +0000000478 0xa002 ExifImageWidth = 1024 +0000000490 0xa003 ExifImageHeight = 768 +0000000502 0xa005 InteropOffset = 886 + +---- Directory InteropIFD @ 886 ---- +0000000888 0x0001 InteroperabilityIndex = R98 +0000000900 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] + +---- Directory IFD1 @ 792 ---- +0000000794 0x0103 Compression = 6 +0000000806 0x011a XResolution = 72/1 (72.0) +0000000818 0x011b YResolution = 72/1 (72.0) +0000000830 0x0128 ResolutionUnit = 2 +0000000842 0x0201 JpgFromRawStart = 2447 +0000000854 0x0202 JpgFromRawLength = 6495 ----- Directory ExifIFD @ 294 ---- -0000000296 0x829a ExposureTime = 1/800 (0.00125) -0000000308 0x829d FNumber = 56/10 (5.6) -0000000320 0x8822 ExposureProgram = 1 -0000000332 0x8827 ISO = 640 -0000000344 0x8830 SensitivityType = 2 -0000000356 0x8832 RecommendedExposureIndex = 640 -0000000368 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x31] -0000000380 0x9003 DateTimeOriginal = 2019:10:03 13:44:17 -0000000392 0x9004 DateTimeDigitized = 2019:10:03 13:44:17 -0000000404 0x9010 OffsetTime = +02:00 -0000000416 0x9201 ShutterSpeedValue = 9643856/1000000 (9.643856) -0000000428 0x9202 ApertureValue = 4970854/1000000 (4.970854) -0000000440 0x9204 ExposureCompensation = -2/3 (-0.666667) -0000000452 0x9205 MaxApertureValue = 5/1 (5.0) -0000000464 0x9207 MeteringMode = 5 -0000000476 0x9209 Flash = 16 -0000000488 0x920a FocalLength = 400/1 (400.0) -0000000500 0x9291 SubSecTimeOriginal = 09 -0000000512 0x9292 SubSecTimeDigitized = 09 -0000000524 0xa001 ColorSpace = 1 -0000000536 0xa20e FocalPlaneXResolution = 79937569/32768 (2439.501007) -0000000548 0xa20f FocalPlaneYResolution = 79937569/32768 (2439.501007) -0000000560 0xa210 FocalPlaneResolutionUnit = 3 -0000000572 0xa401 CustomRendered = 0 -0000000584 0xa402 ExposureMode = 1 -0000000596 0xa403 WhiteBalance = 0 -0000000608 0xa406 SceneCaptureType = 0 -0000000620 0xa431 BodySerialNumber = 058021001207 -0000000632 0xa432 LensSpecification = [100/1 (100.0), 400/1 (400.0), Invalid rational (0/0), Invalid rational (0/0)] -0000000644 0xa434 LensModel = EF100-400mm f/4.5-5.6L IS II USM -0000000656 0xa435 LensSerialNumber = 3610001521 - ----- Directory IFD1 @ 884 ---- -0000000886 0x0103 Compression = 6 -0000000898 0x011a XResolution = 72/1 (72.0) -0000000910 0x011b YResolution = 72/1 (72.0) -0000000922 0x0128 ResolutionUnit = 2 -0000000934 0x0201 JpgFromRawStart = 978 -0000000946 0x0202 JpgFromRawLength = 20962 - ----- IPTC ---- -Date Created (55) = '20191003' -Time Created (60) = '134417' -Digital Creation Date (62) = '20191003' -Digital Creation Time (63) = '134417' -By-line (80) = 'Zdenek & Eva Machackovi' -Copyright Notice (116) = 'ZEphoto.zenfolio.com' -Caption/Abstract (120) = 'white and brown bird on grass field' -Keywords (25) = 'animal' -Keywords (25) = 'grass' -Keywords (25) = 'plant' -Keywords (25) = 'finch' -Keywords (25) = 'lawn' -Keywords (25) = 'bird' -Keywords (25) = 'reed' - ----- XMP ---- - - - - - - 569/100 - True - 1.1.2 - 0/1 - 0 - True - EF100-400mm f/4.5-5.6L IS II USM - 747 - 100/1 400/1 0/0 0/0 - 3610001521 - 058021001207 - True - - - - - - Zdenek & Eva Machackovi - - - image/jpeg - - - ZEphoto.zenfolio.com - - - - - - EF100-400mm f/4.5-5.6L IS II USM - - - - 2019-10-03T13:44:17.09 - - - - 2019-10-03T13:44:17.09 - Adobe Photoshop Lightroom Classic 8.4.1 (Windows) - 2019-10-09T20:46:41+02:00 - 2019-10-09T20:46:41+02:00 - 4 - - - - - 65FEF5F0166319A4F14A4323DC9D3BAF - 65FEF5F0166319A4F14A4323DC9D3BAF - - xmp.did:a7ef1345-23e4-b747-9bd5-603d8a177783 - - - - derived - converted from image/x-canon-cr2 to image/jpeg, saved to new location - - - saved - / - xmp.iid:a7ef1345-23e4-b747-9bd5-603d8a177783 - Adobe Photoshop Lightroom Classic 8.4.1 (Windows) - 2019-10-09T20:46:41+02:00 - - - - xmp.iid:a7ef1345-23e4-b747-9bd5-603d8a177783 - 65FEF5F0166319A4F14A4323DC9D3BAF - _D2_2886.CR2 - - - - True - 1 - -24 - 0 - 0 - Adobe Standard - 986DA3807E87AD9D00B35EFF80D467B9 - +13 - 25 - 50 - 50 - +7 - False - 0 - 0.891957 - 0 - 0.2928 - 1 - 0.033613 - 0 - 60 - 40 - 0 - 70 - 30 - 0 - +0.63 - 0 - 0 - 0 - True - True - -77 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 100 - A4D0BA96DE80CADD0EFEC7ADBE403FCD - 100 - 1 - Canon EOS-1Ds Mark III (Canon EF 100-400mm f4.5-5.6L IS II USM) - RAW.lcp - Adobe (Canon EF 100-400mm f/4.5-5.6L IS II USM) - LensDefaults - 100 - - 1.000000 - - - Profiles - - - Adobe Color - - Adobe Standard - False - E1095149FDB39D7A057BAB208837E2E1 - 11.0 - - - 0, 0 - 22, 16 - 40, 35 - 127, 127 - 224, 230 - 240, 246 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - 11.4.1 - - false - false - false - B952C231111CD8E0ECCF14B86BAA7077 - - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 50 - 25 - False - 0 - 75 - 0 - 0 - 50 - 25 - 0 - 0 - 0 - 0.0 - 100 - 0 - 0 - 0.00 - 0.00 - 0 - 11.0 - _D2_2886.CR2 - 0 - 0 - -3 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - +87 - 25 - 87 - +1.0 - 54 - 0 - 0 - 0 - 0 - 0 - 4500 - +24 - +9 - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - Linear - Custom - - - 0, 0 - 65, 59 - 193, 198 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - 0 - 0 - 0.5 - 0.5 - 35 - 0 - 0 - False - 6 - 151388160 - 11.4.1 - +13 - 0 - As Shot - +49 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_43.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_43.txt index 3ed94649..f0bdf0f1 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_43.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_43.txt @@ -1,113 +1,97 @@ File format : JPEG -Resolution : 4032 x 3024 +Resolution : 1024 x 768 ---- TIFF ---- Version 42 -Big-endian (Motorola, MM) +Little-endian (Intel, II) ---- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = Apple -0000000022 0x0110 Model = iPhone XS -0000000034 0x011a XResolution = 72/1 (72.0) -0000000046 0x011b YResolution = 72/1 (72.0) -0000000058 0x0128 ResolutionUnit = 2 -0000000070 0x0131 Software = 12.1.4 -0000000082 0x0132 ModifyDate = 2019:03:22 18:50:02 -0000000094 0x0142 TileWidth = 512 -0000000106 0x0143 TileLength = 512 -0000000118 0x0213 YCbCrPositioning = 1 -0000000130 0x8769 ExifOffset = 218 -0000000142 0x8825 GPSInfo = 1796 +0000000010 0x010e ImageDescription = DIGITAL CAMERA +0000000022 0x010f Make = Digital +0000000034 0x0110 Model = Digital Cam +0000000046 0x0112 Orientation = 1 +0000000058 0x011a XResolution = 72/1 (72.0) +0000000070 0x011b YResolution = 72/1 (72.0) +0000000082 0x0128 ResolutionUnit = 2 +0000000094 0x0131 Software = M4021M-1006 +0000000106 0x0132 ModifyDate = 2004:01:18 04:27:28 +0000000118 0x0213 YCbCrPositioning = 2 +0000000130 0x8769 ExifOffset = 158 +0000000142 0x8825 GPSInfo = 470 ----- Directory ExifIFD @ 218 ---- -0000000220 0x829a ExposureTime = 1/122 (0.008197) -0000000232 0x829d FNumber = 12/5 (2.4) -0000000244 0x8822 ExposureProgram = 2 -0000000256 0x8827 ISO = 50 -0000000268 0x9000 ExifVersion = [0x30, 0x32, 0x32, 0x31] -0000000280 0x9003 DateTimeOriginal = 2019:03:22 18:50:02 -0000000292 0x9004 DateTimeDigitized = 2019:03:22 18:50:02 -0000000304 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] -0000000316 0x9201 ShutterSpeedValue = 328711/47450 (6.927524) -0000000328 0x9202 ApertureValue = 126503/50079 (2.526069) -0000000340 0x9203 BrightnessValue = 685337/119222 (5.748411) -0000000352 0x9204 ExposureCompensation = 0/1 (0.0) -0000000364 0x9207 MeteringMode = 5 -0000000376 0x9209 Flash = 24 -0000000388 0x920a FocalLength = 6/1 (6.0) -0000000400 0x9214 SubjectArea = [2007, 1505, 2112, 1270] -0000000412 0x927c MakerNote = [996 bytes] -0000000424 0x9291 SubSecTimeOriginal = 935 -0000000436 0x9292 SubSecTimeDigitized = 935 -0000000448 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] -0000000460 0xa001 ColorSpace = -1 -0000000472 0xa002 ExifImageWidth = 4032 -0000000484 0xa003 ExifImageHeight = 3024 -0000000496 0xa217 SensingMethod = 2 -0000000508 0xa301 SceneType = 1 -0000000520 0xa401 CustomRendered = 8 -0000000532 0xa402 ExposureMode = 0 -0000000544 0xa403 WhiteBalance = 0 -0000000556 0xa405 FocalLengthIn35mmFormat = 52 -0000000568 0xa406 SceneCaptureType = 0 -0000000580 0xa432 LensSpecification = [17/4 (4.25), 6/1 (6.0), 9/5 (1.8), 12/5 (2.4)] -0000000592 0xa433 LensMake = Apple -0000000604 0xa434 LensModel = iPhone XS back dual camera 6mm f/2.4 +---- Directory ExifIFD @ 158 ---- +0000000160 0x829a ExposureTime = 1000/316682 (0.003158) +0000000172 0x829d FNumber = 740/100 (7.4) +0000000184 0x8822 ExposureProgram = 2 +0000000196 0x8827 ISO = 100 +0000000208 0x9000 ExifVersion = [0x30, 0x32, 0x32, 0x30] +0000000220 0x9003 DateTimeOriginal = 2006:04:26 00:26:14 +0000000232 0x9004 DateTimeDigitized = 2006:04:26 00:26:14 +0000000244 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] +0000000256 0x9102 CompressedBitsPerPixel = 2/1 (2.0) +0000000268 0x9204 ExposureCompensation = 154/10 (15.4) +0000000280 0x9205 MaxApertureValue = 61/20 (3.05) +0000000292 0x9207 MeteringMode = 2 +0000000304 0x9208 LightSource = 0 +0000000316 0x9209 Flash = 0 +0000000328 0x920a FocalLength = 1004/100 (10.04) +0000000340 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] +0000000352 0xa001 ColorSpace = 1 +0000000364 0xa002 ExifImageWidth = 1024 +0000000376 0xa003 ExifImageHeight = 768 +0000000388 0xa004 RelatedSoundFile = +0000000400 0xa005 InteropOffset = 440 +0000000412 0xa300 FileSource = 3 +0000000424 0xa301 SceneType = 1 ----- Directory GPS @ 1796 ---- -0000001798 0x0001 GPSLatitudeRef = N -0000001810 0x0002 GPSLatitude = [34/1 (34.0), 27/1 (27.0), 4701/100 (47.01)] -0000001822 0x0003 GPSLongitudeRef = W -0000001834 0x0004 GPSLongitude = [119/1 (119.0), 45/1 (45.0), 2958/100 (29.58)] -0000001846 0x0005 GPSAltitudeRef = 0 -0000001858 0x0006 GPSAltitude = 425411/2445 (173.992229) -0000001870 0x0007 GPSTimeStamp = [1/1 (1.0), 50/1 (50.0), 1/1 (1.0)] -0000001882 0x000c GPSSpeedRef = K -0000001894 0x000d GPSSpeed = 76721/92899 (0.825854) -0000001906 0x0010 GPSImgDirectionRef = T -0000001918 0x0011 GPSImgDirection = 100129/713 (140.43338) -0000001930 0x0017 GPSDestBearingRef = T -0000001942 0x0018 GPSDestBearing = 100129/713 (140.43338) -0000001954 0x001d GPSDateStamp = 2019:03:23 -0000001966 0x001f Unknown = 79605/8807 (9.038833) +---- Directory InteropIFD @ 440 ---- +0000000442 0x0001 InteroperabilityIndex = R98 +0000000454 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] ----- IPTC ---- -Keywords (25) = 'nature' -Keywords (25) = 'field' -Keywords (25) = 'grassland' -Keywords (25) = 'outdoors' +---- Directory GPS @ 470 ---- +0000000472 0x0000 GPSVersionID = [0x02, 0x02, 0x00, 0x00] ----- XMP ---- - - - +---- Directory IFD1 @ 682 ---- +0000000684 0x010e ImageDescription = DIGITAL CAMERA +0000000696 0x010f Make = Digital +0000000708 0x0110 Model = Digital Cam +0000000720 0x0112 Orientation = 1 +0000000732 0x011a XResolution = 72/1 (72.0) +0000000744 0x011b YResolution = 72/1 (72.0) +0000000756 0x0128 ResolutionUnit = 2 +0000000768 0x0131 Software = M4021M-1006 +0000000780 0x0132 ModifyDate = 2004:01:18 04:27:28 +0000000792 0x0213 YCbCrPositioning = 2 +0000000804 0x8769 ExifOffset = 832 +0000000816 0x8825 GPSInfo = 1144 + +---- Directory ExifIFD @ 832 ---- +0000000834 0x829a ExposureTime = 1000/316682 (0.003158) +0000000846 0x829d FNumber = 740/100 (7.4) +0000000858 0x8822 ExposureProgram = 2 +0000000870 0x8827 ISO = 100 +0000000882 0x9000 ExifVersion = [0x30, 0x32, 0x32, 0x30] +0000000894 0x9003 DateTimeOriginal = 2006:04:26 00:26:14 +0000000906 0x9004 DateTimeDigitized = 2006:04:26 00:26:14 +0000000918 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] +0000000930 0x9102 CompressedBitsPerPixel = 2/1 (2.0) +0000000942 0x9204 ExposureCompensation = 154/10 (15.4) +0000000954 0x9205 MaxApertureValue = 61/20 (3.05) +0000000966 0x9207 MeteringMode = 2 +0000000978 0x9208 LightSource = 0 +0000000990 0x9209 Flash = 0 +0000001002 0x920a FocalLength = 1004/100 (10.04) +0000001014 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] +0000001026 0xa001 ColorSpace = 1 +0000001038 0xa002 ExifImageWidth = 1024 +0000001050 0xa003 ExifImageHeight = 768 +0000001062 0xa004 RelatedSoundFile = +0000001074 0xa005 InteropOffset = 1114 +0000001086 0xa300 FileSource = 3 +0000001098 0xa301 SceneType = 1 + +---- Directory InteropIFD @ 1114 ---- +0000001116 0x0001 InteroperabilityIndex = R98 +0000001128 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] + +---- Directory GPS @ 1144 ---- +0000001146 0x0000 GPSVersionID = [0x02, 0x02, 0x00, 0x00] - - 4 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_44.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_44.txt index d9cc2d08..8e7b7e3d 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_44.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_44.txt @@ -1,162 +1,2 @@ File format : JPEG -Resolution : 6000 x 4000 ----- TIFF ---- -Version 42 -Little-endian (Intel, II) ----- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = Canon -0000000022 0x0110 Model = Canon EOS 77D -0000000034 0x0112 Orientation = 1 -0000000046 0x011a XResolution = 72/1 (72.0) -0000000058 0x011b YResolution = 72/1 (72.0) -0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0132 ModifyDate = 2018:10:09 11:55:20 -0000000094 0x013b Artist = HENRIK HANSEN -0000000106 0x0213 YCbCrPositioning = 2 -0000000118 0x8298 Copyright = -0000000130 0x8769 ExifOffset = 228 -0000000142 0x8825 GPSInfo = 10688 - ----- Directory ExifIFD @ 228 ---- -0000000230 0x829a ExposureTime = 1/500 (0.002) -0000000242 0x829d FNumber = 8/1 (8.0) -0000000254 0x8822 ExposureProgram = 2 -0000000266 0x8827 ISO = 400 -0000000278 0x8830 SensitivityType = 2 -0000000290 0x8832 RecommendedExposureIndex = 400 -0000000302 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000314 0x9003 DateTimeOriginal = 2018:10:09 11:55:20 -0000000326 0x9004 DateTimeDigitized = 2018:10:09 11:55:20 -0000000338 0x9101 ComponentsConfiguration = [0x01, 0x02, 0x03, 0x00] -0000000350 0x9201 ShutterSpeedValue = 589824/65536 (9.0) -0000000362 0x9202 ApertureValue = 393216/65536 (6.0) -0000000374 0x9204 ExposureCompensation = 0/1 (0.0) -0000000386 0x9207 MeteringMode = 5 -0000000398 0x9209 Flash = 16 -0000000410 0x920a FocalLength = 400/1 (400.0) -0000000422 0x927c MakerNote = [9512 bytes] -0000000434 0x9286 UserComment = -0000000446 0x9290 SubSecTime = 86 -0000000458 0x9291 SubSecTimeOriginal = 86 -0000000470 0x9292 SubSecTimeDigitized = 86 -0000000482 0xa000 FlashpixVersion = [0x30, 0x31, 0x30, 0x30] -0000000494 0xa001 ColorSpace = 1 -0000000506 0xa002 ExifImageWidth = 6000 -0000000518 0xa003 ExifImageHeight = 4000 -0000000530 0xa005 InteropOffset = 10658 -0000000542 0xa20e FocalPlaneXResolution = 6000000/921 (6514.65798) -0000000554 0xa20f FocalPlaneYResolution = 4000000/594 (6734.006734) -0000000566 0xa210 FocalPlaneResolutionUnit = 2 -0000000578 0xa401 CustomRendered = 0 -0000000590 0xa402 ExposureMode = 0 -0000000602 0xa403 WhiteBalance = 0 -0000000614 0xa406 SceneCaptureType = 0 -0000000626 0xa430 CameraOwnerName = -0000000638 0xa431 BodySerialNumber = 143031003387 -0000000650 0xa432 LensSpecification = [100/1 (100.0), 400/1 (400.0), 0/1 (0.0), 0/1 (0.0)] -0000000662 0xa434 LensModel = EF100-400mm f/4.5-5.6L IS USM -0000000674 0xa435 LensSerialNumber = 0000000000 - ----- Directory InteropIFD @ 10658 ---- -0000010660 0x0001 InteroperabilityIndex = R98 -0000010672 0x0002 InteroperabilityVersion = [0x30, 0x31, 0x30, 0x30] - ----- Directory GPS @ 10688 ---- -0000010690 0x0000 GPSVersionID = [0x02, 0x03, 0x00, 0x00] - ----- Directory IFD1 @ 10706 ---- -0000010708 0x0103 Compression = 6 -0000010720 0x011a XResolution = 72/1 (72.0) -0000010732 0x011b YResolution = 72/1 (72.0) -0000010744 0x0128 ResolutionUnit = 2 -0000010756 0x0201 JpgFromRawStart = 10800 -0000010768 0x0202 JpgFromRawLength = 7437 - ----- Directory MakerNoteCanon @ 778 ---- -0000000780 0x0001 CanonCameraSettings = [49 shorts] -0000000792 0x0002 Unknown = [0, 400, 25518, 18461] -0000000804 0x0003 Unknown = [0, 0, 0, 0] -0000000816 0x0004 Unknown = [34 shorts] -0000000828 0x0006 CanonImageType = Canon EOS 77D -0000000840 0x0007 CanonFirmwareVersion = Firmware Version 1.0.2 -0000000852 0x0009 OwnerName = -0000000864 0x000d Unknown = [1536 bytes] -0000000876 0x0010 CanonModelID = -2147482616 -0000000888 0x0013 Unknown = [0, 159, 7, 112] -0000000900 0x0019 Unknown = 1 -0000000912 0x0026 Unknown = [217 shorts] -0000000924 0x0035 Unknown = [16, 60, 19, 0] -0000000936 0x0038 Unknown = [76 bytes] -0000000948 0x0093 Unknown = [43 shorts] -0000000960 0x0095 LensModel = EF100-400mm f/4.5-5.6L IS USM -0000000972 0x0096 InternalSerialNumber = AG0542547 -0000000984 0x0097 Unknown = [1024 bytes] -0000000996 0x0098 Unknown = [0, 0, 0, 0] -0000001008 0x0099 Unknown = [74 ints] -0000001020 0x009a Unknown = [0, 6000, 4000, 0, 0] -0000001032 0x00a0 Unknown = [17 shorts] -0000001044 0x00aa Unknown = [12, 574, 1024, 1024, 611, 0] -0000001056 0x00b4 Unknown = 1 -0000001068 0x00d0 Unknown = 0 -0000001080 0x00e0 Unknown = [17 shorts] -0000001092 0x4001 Unknown = [1602 shorts] -0000001104 0x4008 Unknown = [135, 135, 135] -0000001116 0x4009 Unknown = [0, 0, 0] -0000001128 0x4010 Unknown = -0000001140 0x4011 Unknown = [252 bytes] -0000001152 0x4012 Unknown = -0000001164 0x4013 Unknown = [44, 3, 0, 0, 0, 30, 10, 30, 10, 0, 10] -0000001176 0x4015 Unknown = [632 bytes] -0000001188 0x4016 Unknown = [40, 0, 1, 0, 0, 1, 1, 0, 1, 0] -0000001200 0x4018 Unknown = [52, 0, 3, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0] -0000001212 0x4019 LensInfo = [30 bytes] -0000001224 0x4020 Unknown = [32, 0, 0, 0, 2147483647, 0, 1, 1] -0000001236 0x4024 Unknown = [53 ints] -0000001248 0x4025 Unknown = [36, 0, 0, 0, 0, 0, 0, 0, 0] -0000001260 0x4027 Unknown = [24, 459526, 1845493828, 251658240, 13684944, 0] -0000001272 0x402a Unknown = [12, 0, 0] -0000001284 0x4033 Unknown = [410 bytes] - ----- IPTC ---- -Caption/Abstract (120) = 'American eagle during daytime' -Keywords (25) = 'animal' -Keywords (25) = 'bald eagle' -Keywords (25) = 'eagle' -Keywords (25) = 'bird' - ----- XMP ---- - - - - - - 2 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file +Resolution : 2820 x 3077 diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_45.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_45.txt index 880908b7..c72bca45 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_45.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_45.txt @@ -1,759 +1,2 @@ File format : JPEG -Resolution : 3594 x 2446 ----- TIFF ---- -Version 42 -Little-endian (Intel, II) ----- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = SONY -0000000022 0x0110 Model = ILCE-7S -0000000034 0x0112 Orientation = 1 -0000000046 0x011a XResolution = 72/1 (72.0) -0000000058 0x011b YResolution = 72/1 (72.0) -0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0131 Software = Adobe Photoshop Lightroom 6.0 (Macintosh) -0000000094 0x0132 ModifyDate = 2017:07:17 22:04:13 -0000000106 0x8769 ExifOffset = 214 - ----- Directory ExifIFD @ 214 ---- -0000000216 0x829a ExposureTime = 1/640 (0.001563) -0000000228 0x829d FNumber = 63/10 (6.3) -0000000240 0x8822 ExposureProgram = 1 -0000000252 0x8827 ISO = 800 -0000000264 0x8830 SensitivityType = 2 -0000000276 0x8832 RecommendedExposureIndex = 800 -0000000288 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000300 0x9003 DateTimeOriginal = 2017:07:17 18:21:14 -0000000312 0x9004 DateTimeDigitized = 2017:07:17 18:21:14 -0000000324 0x9201 ShutterSpeedValue = 9321928/1000000 (9.321928) -0000000336 0x9202 ApertureValue = 5310704/1000000 (5.310704) -0000000348 0x9203 BrightnessValue = 16234/2560 (6.341406) -0000000360 0x9204 ExposureCompensation = 0/10 (0.0) -0000000372 0x9205 MaxApertureValue = 1360/256 (5.3125) -0000000384 0x9207 MeteringMode = 5 -0000000396 0x9208 LightSource = 11 -0000000408 0x9209 Flash = 16 -0000000420 0x920a FocalLength = 2400/10 (240.0) -0000000432 0xa001 ColorSpace = 1 -0000000444 0xa20e FocalPlaneXResolution = 38690215/32768 (1180.731659) -0000000456 0xa20f FocalPlaneYResolution = 38690215/32768 (1180.731659) -0000000468 0xa210 FocalPlaneResolutionUnit = 3 -0000000480 0xa300 FileSource = 3 -0000000492 0xa301 SceneType = 1 -0000000504 0xa401 CustomRendered = 0 -0000000516 0xa402 ExposureMode = 1 -0000000528 0xa403 WhiteBalance = 1 -0000000540 0xa404 DigitalZoomRatio = 16/16 (1.0) -0000000552 0xa405 FocalLengthIn35mmFormat = 240 -0000000564 0xa406 SceneCaptureType = 0 -0000000576 0xa408 Contrast = 0 -0000000588 0xa409 Saturation = 0 -0000000600 0xa40a Sharpness = 0 -0000000612 0xa432 LensSpecification = [240/10 (24.0), 2400/10 (240.0), 35/10 (3.5), 63/10 (6.3)] -0000000624 0xa434 LensModel = FE 24-240mm F3.5-6.3 OSS - ----- Directory IFD1 @ 826 ---- -0000000828 0x0103 Compression = 6 -0000000840 0x011a XResolution = 72/1 (72.0) -0000000852 0x011b YResolution = 72/1 (72.0) -0000000864 0x0128 ResolutionUnit = 2 -0000000876 0x0201 JpgFromRawStart = 920 -0000000888 0x0202 JpgFromRawLength = 12731 - ----- IPTC ---- -Date Created (55) = '20170717' -Time Created (60) = '182114' -Digital Creation Date (62) = '20170717' -Digital Creation Time (63) = '182114' - ----- XMP ---- - - - - - - FE 24-240mm F3.5-6.3 OSS - 240/10 2400/10 35/10 63/10 - - - - image/jpeg - - - - 2017-07-17T18:21:14 - - - - 2017-07-17T18:21:14 - Adobe Photoshop Lightroom 6.0 (Macintosh) - 2017-07-17T22:04:13-03:00 - 2017-07-17T22:04:13-03:00 - 2 - - - - - xmp.did:b593b3ed-ff2f-4e8e-95d5-7cc5988c01c5 - xmp.iid:b593b3ed-ff2f-4e8e-95d5-7cc5988c01c5 - 6BE69D49EC5B5C820D2EEE864415D602 - - xmp.did:1a499823-4165-4149-9355-5038b48eda98 - - - - converted - from image/x-sony-arw to image/dng - - - saved - /metadata - xmp.iid:b593b3ed-ff2f-4e8e-95d5-7cc5988c01c5 - Adobe Photoshop Lightroom 6.0 (Macintosh) - 2017-07-17T20:37-03:00 - - - derived - converted from image/dng to image/jpeg, saved to new location - - - saved - / - xmp.iid:1a499823-4165-4149-9355-5038b48eda98 - Adobe Photoshop Lightroom 6.0 (Macintosh) - 2017-07-17T22:04:13-03:00 - - - saved - /metadata - xmp.iid:e5101770-6dc9-4c2d-93ba-7e0dddb726be - Adobe Photoshop Lightroom 6.0 (Macintosh) - 2017-07-17T22:04:13-03:00 - - - - xmp.iid:e5101770-6dc9-4c2d-93ba-7e0dddb726be - 6BE69D49EC5B5C820D2EEE864415D602 - - - - True - 1 - 134348800 - +7 - -11 - 0 - Adobe Standard - +5 - 25 - 50 - 50 - +26 - False - 0 - 0.952836 - 0 - 0.0051 - 0.852836 - 0.089087 - 0 - 60 - 40 - 0 - 70 - 30 - +0.59 - 15 - 50 - 1866158102 - 45 - +44 - 0 - True - True - -82 - +10 - -23 - 0 - +20 - +5 - +20 - +10 - 0 - 0 - 100 - 0E0E0483ED048452CE6CC01CB9D7D893 - 100 - 0 - SONY (Sony FE 24-240mm F3.5-6.3 OSS) - RAW.lcp - Adobe (Sony FE 24-240mm F3.5-6.3 OSS) - LensDefaults - 100 - -12 - +59 - 0 - 0 - +5 - 0 - 0 - 0 - 0 - - - - true - 1.000000 - - - - 0.092338 - - - d 0.550077 0.453913 - r 0.106822 - d 0.520538 0.468930 - r 0.106808 - d 0.500725 0.505721 - r 0.106833 - d 0.496680 0.552137 - r 0.106876 - d 0.519958 0.580808 - r 0.106895 - d 0.548101 0.566140 - r 0.106881 - d 0.560024 0.524490 - r 0.106884 - d 0.561107 0.476508 - r 0.106899 - d 0.552378 0.434688 - r 0.106846 - d 0.523235 0.444702 - r 0.106816 - d 0.499427 0.476094 - r 0.106824 - d 0.480304 0.514348 - r 0.106858 - d 0.475552 0.559611 - r 0.106897 - d 0.492413 0.595464 - r 0.106870 - d 0.518960 0.575597 - r 0.106846 - d 0.536703 0.536319 - r 0.106861 - d 0.546815 0.491035 - r 0.106893 - d 0.554394 0.444487 - r 0.106968 - d 0.555413 0.396484 - r 0.106973 - d 0.543178 0.384028 - r 0.106879 - d 0.525867 0.424331 - r 0.106823 - d 0.511626 0.467138 - r 0.106810 - d 0.503710 0.512444 - r 0.106845 - d 0.513228 0.558261 - r 0.106928 - d 0.540532 0.576265 - r 0.107022 - d 0.571590 0.588377 - r 0.107117 - d 0.602716 0.600434 - r 0.107259 - d 0.632682 0.596823 - r 0.107191 - d 0.631266 0.549494 - r 0.107117 - d 0.622830 0.503102 - r 0.107075 - d 0.611411 0.458268 - r 0.106992 - d 0.590011 0.449967 - r 0.107005 - d 0.598077 0.496484 - r 0.107091 - d 0.613109 0.538498 - r 0.107226 - d 0.633399 0.575002 - r 0.107417 - d 0.664455 0.571043 - r 0.107397 - d 0.666784 0.535788 - r 0.107252 - d 0.642236 0.504925 - r 0.107108 - d 0.617137 0.474806 - r 0.106982 - d 0.588570 0.454908 - r 0.106895 - d 0.566615 0.482976 - r 0.106887 - d 0.560958 0.529939 - r 0.106952 - d 0.570297 0.571515 - r 0.106964 - d 0.581924 0.526779 - r 0.106985 - d 0.592769 0.481572 - r 0.107060 - d 0.599760 0.434648 - r 0.107143 - d 0.602691 0.387180 - r 0.107148 - d 0.582107 0.353694 - r 0.107091 - d 0.551252 0.343667 - r 0.106978 - d 0.528428 0.372647 - r 0.106885 - d 0.522544 0.419049 - r 0.106828 - d 0.526121 0.464519 - r 0.106892 - d 0.554594 0.446531 - r 0.106998 - d 0.579749 0.417010 - r 0.107063 - d 0.578712 0.381745 - r 0.107047 - d 0.588228 0.406282 - r 0.107212 - d 0.610614 0.372765 - r 0.107236 - d 0.595553 0.340617 - r 0.107125 - d 0.564782 0.343689 - r 0.106988 - d 0.542013 0.376746 - r 0.106882 - d 0.525553 0.417782 - r 0.106948 - d 0.544006 0.394959 - r 0.106969 - d 0.528907 0.376524 - r 0.106971 - d 0.497175 0.369564 - r 0.106902 - d 0.509024 0.400551 - r 0.106944 - d 0.525368 0.384667 - r 0.106898 - d 0.508112 0.403409 - r 0.106845 - d 0.503437 0.450597 - r 0.106814 - d 0.501593 0.498503 - r 0.106823 - d 0.516832 0.537627 - r 0.106858 - d 0.547423 0.531031 - r 0.106877 - d 0.559390 0.488709 - r 0.106910 - d 0.557095 0.441228 - r 0.106929 - d 0.541816 0.403862 - r 0.106870 - d 0.517747 0.421556 - r 0.106822 - d 0.508947 0.467700 - r 0.106815 - d 0.503279 0.514841 - r 0.106849 - d 0.499223 0.562437 - r 0.106909 - d 0.485215 0.599547 - r 0.106897 - d 0.490295 0.592247 - r 0.106860 - d 0.517689 0.567318 - r 0.106862 - d 0.544311 0.540665 - r 0.106884 - d 0.560416 0.502504 - r 0.106917 - d 0.566212 0.455446 - r 0.106988 - d 0.566901 0.407415 - r 0.107085 - d 0.567243 0.359335 - r 0.106975 - d 0.556458 0.395924 - r 0.106910 - d 0.552261 0.443356 - r 0.106865 - d 0.549546 0.491197 - r 0.106897 - d 0.559145 0.534934 - r 0.106976 - d 0.577398 0.571906 - r 0.107068 - d 0.604027 0.566485 - r 0.107019 - d 0.600219 0.518930 - - - 0.200000 - 1.000000 - 0.106873 - Mask/Paint - - - 0.092338 - - - d 0.566661 0.538366 - r 0.106882 - d 0.541813 0.567195 - r 0.106929 - d 0.536683 0.601096 - r 0.106970 - d 0.566832 0.588891 - r 0.106923 - d 0.568658 0.550795 - r 0.106863 - d 0.538016 0.553920 - r 0.106882 - d 0.512408 0.581818 - r 0.106949 - d 0.490852 0.617374 - r 0.107024 - d 0.482470 0.646244 - r 0.106953 - d 0.510312 0.622943 - r 0.106896 - d 0.530616 0.585900 - r 0.106886 - d 0.544947 0.542953 - r 0.106876 - d 0.559278 0.500006 - r 0.106922 - d 0.567467 0.453660 - r 0.106886 - d 0.552312 0.453384 - r 0.106839 - d 0.527834 0.483247 - r 0.106840 - d 0.507702 0.520587 - r 0.106845 - d 0.487778 0.558154 - r 0.106927 - d 0.473313 0.601001 - r 0.106976 - d 0.490174 0.630790 - r 0.106980 - d 0.520269 0.631014 - r 0.106927 - d 0.540365 0.594812 - r 0.106889 - d 0.551051 0.550057 - r 0.106868 - d 0.556893 0.502988 - r 0.106833 - d 0.537076 0.498236 - r 0.106824 - d 0.514421 0.532173 - r 0.106862 - d 0.495516 0.570725 - r 0.106946 - d 0.481764 0.613786 - r 0.106964 - d 0.495720 0.625847 - r 0.106935 - d 0.522268 0.599753 - r 0.106915 - d 0.547553 0.570199 - r 0.106933 - d 0.569604 0.535951 - r 0.106990 - d 0.588399 0.497007 - r 0.107053 - d 0.606222 0.457218 - r 0.107076 - d 0.605565 0.431983 - r 0.107003 - d 0.596030 0.477714 - r 0.106976 - d 0.590207 0.524973 - r 0.107035 - d 0.603324 0.537552 - r 0.107127 - d 0.624703 0.514553 - r 0.107170 - d 0.624940 0.562699 - r 0.107252 - d 0.625833 0.610832 - r 0.107355 - d 0.623089 0.656983 - r 0.107382 - d 0.641347 0.629751 - r 0.107315 - d 0.646258 0.582121 - r 0.107273 - d 0.647777 0.540055 - r 0.107272 - d 0.637604 0.585766 - r 0.107374 - d 0.628826 0.632228 - r 0.107503 - d 0.620427 0.678861 - r 0.107632 - d 0.612028 0.725494 - r 0.107762 - d 0.603629 0.772127 - r 0.107964 - d 0.593573 0.818167 - r 0.107803 - d 0.600664 0.784909 - r 0.107621 - d 0.611126 0.739181 - r 0.107473 - d 0.620815 0.693183 - r 0.107357 - d 0.629142 0.646568 - r 0.107246 - d 0.629798 0.598641 - r 0.107112 - d 0.611782 0.572861 - r 0.107304 - d 0.637627 0.601544 - r 0.107535 - d 0.664347 0.628550 - r 0.107696 - d 0.685524 0.632845 - r 0.107544 - d 0.677592 0.586715 - r 0.107398 - d 0.665785 0.541865 - r 0.107339 - d 0.658137 0.533667 - r 0.107396 - d 0.658178 0.581910 - r 0.107490 - d 0.657815 0.630181 - r 0.107569 - d 0.649486 0.675674 - r 0.107475 - d 0.650755 0.641654 - r 0.107412 - d 0.657007 0.594506 - r 0.107350 - d 0.657950 0.546796 - r 0.107280 - d 0.651304 0.499629 - r 0.107214 - d 0.640101 0.514470 - r 0.107378 - d 0.662679 0.547600 - r 0.107605 - d 0.688417 0.576858 - r 0.107869 - d 0.712434 0.609328 - r 0.107815 - d 0.710900 0.587842 - r 0.107659 - d 0.697665 0.543732 - r 0.107521 - d 0.684362 0.499767 - r 0.107445 - d 0.670409 0.456254 - r 0.107393 - d 0.657024 0.412397 - r 0.107438 - d 0.649885 0.368699 - r 0.107600 - d 0.651247 0.320426 - r 0.107672 - d 0.640848 0.282640 - r 0.107446 - d 0.614652 0.303731 - r 0.107233 - d 0.598648 0.345469 - r 0.107080 - d 0.577041 0.372584 - r 0.106989 - d 0.555666 0.386802 - r 0.106914 - d 0.556263 0.429504 - r 0.106866 - d 0.525492 0.427890 - - - 0.200000 - 1.000000 - 0.106906 - Mask/Paint - - - - 0.000000 - 0.373183 - 0.059684 - 0.000000 - 0.301508 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.091025 - 0.000000 - -0.099382 - 0.000000 - 0.000000 - 0.000000 - Correction - - - - 0 - 75 - 0 - 0 - 50 - 25 - 0 - 0 - 0 - 0.0 - 100 - 0 - 0 - -11 - 50 - 0 - 50 - 0 - 1 - 6.7 - DSC07033.jpg - +26 - +50 - -33 - 0 - -56 - -69 - -35 - +19 - -35 - 0 - -30 - -2 - +39 - 25 - 0 - +1.0 - 35 - 0 - 0 - 0 - 0 - 0 - 6150 - +17 - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - Linear - Custom - - - 0, 28 - 54, 62 - 176, 164 - 255, 224 - - - - - 0, 0 - 39, 13 - 87, 65 - 123, 124 - 183, 199 - 255, 255 - - - - - 0, 0 - 40, 14 - 83, 59 - 123, 126 - 172, 185 - 255, 255 - - - - - 0, 0 - 40, 12 - 84, 58 - 123, 125 - 186, 196 - 255, 255 - - - - - 0, 0 - 255, 255 - - - 9.0 - 0 - 0 - Custom - -49 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file +Resolution : null diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_46.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_46.txt index 7dc22206..d4892f25 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_46.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_46.txt @@ -1,350 +1,18 @@ File format : JPEG -Resolution : 4390 x 2927 +Resolution : 325 x 407 ---- TIFF ---- -Version 42 -Little-endian (Intel, II) +Version 4906 +Big-endian (Motorola, MM) ---- Directory IFD0 @ 8 ---- -0000000010 0x010f Make = Canon -0000000022 0x0110 Model = Canon EOS 6D -0000000034 0x011a XResolution = 72/1 (72.0) -0000000046 0x011b YResolution = 72/1 (72.0) -0000000058 0x0128 ResolutionUnit = 2 -0000000070 0x0131 Software = Adobe Photoshop Lightroom Classic 8.0 (Macintosh) -0000000082 0x0132 ModifyDate = 2019:03:04 15:08:58 -0000000094 0x013b Artist = Jonathan Cooper -0000000106 0x8298 Copyright = 2014 -0000000118 0x8769 ExifOffset = 262 +0000000010 0x0112 Orientation = 1 +0000000058 0x0131 Software = Adobe Photoshop 7.0 +0000000070 0x0132 ModifyDate = 2006:10:14 22:52:07 + +---- Directory IFD1 @ 200 ---- +0000000202 0x0103 Compression = 6 +0000000214 0x011a XResolution = 72/851969 (8.5E-5) +0000000226 0x011b YResolution = 72/1 (72.0) +0000000238 0x0128 ResolutionUnit = 2 +0000000250 0x0201 JpgFromRawStart = 294 +0000000262 0x0202 JpgFromRawLength = 3664 ----- Directory ExifIFD @ 262 ---- -0000000264 0x829a ExposureTime = 1/200 (0.005) -0000000276 0x829d FNumber = 2/1 (2.0) -0000000288 0x8822 ExposureProgram = 1 -0000000300 0x8827 ISO = 125 -0000000312 0x8830 SensitivityType = 2 -0000000324 0x8832 RecommendedExposureIndex = 125 -0000000336 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000348 0x9003 DateTimeOriginal = 2018:10:20 15:19:58 -0000000360 0x9004 DateTimeDigitized = 2018:10:20 15:19:58 -0000000372 0x9201 ShutterSpeedValue = 7643856/1000000 (7.643856) -0000000384 0x9202 ApertureValue = 2/1 (2.0) -0000000396 0x9204 ExposureCompensation = 0/1 (0.0) -0000000408 0x9205 MaxApertureValue = 2/1 (2.0) -0000000420 0x9207 MeteringMode = 5 -0000000432 0x9209 Flash = 16 -0000000444 0x920a FocalLength = 100/1 (100.0) -0000000456 0x9291 SubSecTimeOriginal = 62 -0000000468 0x9292 SubSecTimeDigitized = 62 -0000000480 0xa001 ColorSpace = 1 -0000000492 0xa20e FocalPlaneXResolution = 49807360/32768 (1520.0) -0000000504 0xa20f FocalPlaneYResolution = 49807360/32768 (1520.0) -0000000516 0xa210 FocalPlaneResolutionUnit = 3 -0000000528 0xa401 CustomRendered = 0 -0000000540 0xa402 ExposureMode = 1 -0000000552 0xa403 WhiteBalance = 0 -0000000564 0xa406 SceneCaptureType = 0 -0000000576 0xa431 BodySerialNumber = 022123002072 -0000000588 0xa432 LensSpecification = [100/1 (100.0), 100/1 (100.0), Invalid rational (0/0), Invalid rational (0/0)] -0000000600 0xa434 LensModel = 100mm -0000000612 0xa435 LensSerialNumber = 0000000000 - ----- Directory IFD1 @ 804 ---- -0000000806 0x0103 Compression = 6 -0000000818 0x011a XResolution = 72/1 (72.0) -0000000830 0x011b YResolution = 72/1 (72.0) -0000000842 0x0128 ResolutionUnit = 2 -0000000854 0x0201 JpgFromRawStart = 898 -0000000866 0x0202 JpgFromRawLength = 10447 - ----- IPTC ---- -Date Created (55) = '20181020' -Time Created (60) = '151958' -Digital Creation Date (62) = '20181020' -Digital Creation Time (63) = '151958' -By-line (80) = 'Jonathan Cooper' -Copyright Notice (116) = '2014' -Caption/Abstract (120) = 'orange fox walking on street' -Keywords (25) = 'canine' -Keywords (25) = 'wildlife' -Keywords (25) = 'red fox' -Keywords (25) = 'pet' -Keywords (25) = 'animal' -Keywords (25) = 'mammal' -Keywords (25) = 'dog' -Keywords (25) = 'fox' - ----- XMP ---- - - - - - - 1.1.8 - 0/1 - 0 - 100mm - 220 - 100/1 100/1 0/0 0/0 - 0000000000 - 022123002072 - - - - - - Jonathan Cooper - - - image/jpeg - - - 2014 - - - - - - 100mm - - - - 2018-10-20T15:19:58.62 - - - - 2018-10-20T15:19:58.62 - Adobe Photoshop Lightroom Classic 8.0 (Macintosh) - 2019-03-04T15:08:58-03:30 - 2019-03-04T15:08:58-03:30 - 0 - - - - - 0D1AECB577F991DDB109A54A11A712CC - 0D1AECB577F991DDB109A54A11A712CC - - xmp.did:56c6df46-c450-4a4f-a3fa-953b81fc65bf - - - - derived - converted from image/x-canon-cr2 to image/jpeg, saved to new location - - - saved - / - xmp.iid:56c6df46-c450-4a4f-a3fa-953b81fc65bf - Adobe Photoshop Lightroom Classic 8.0 (Macintosh) - 2019-03-04T15:08:58-03:30 - - - - xmp.iid:56c6df46-c450-4a4f-a3fa-953b81fc65bf - 0D1AECB577F991DDB109A54A11A712CC - - - - True - 0 - 0 - -50 - 0 - Adobe Standard - 98BA1AFA1155D0472068BB57D3655975 - 0 - 25 - 50 - 50 - 0 - False - 0 - 1 - 0 - 0.157865 - 0.960293 - 0.197572 - 0 - 60 - 40 - 0 - 70 - 30 - 0 - +0.90 - 0 - +16 - 0 - True - True - -100 - +17 - 0 - +58 - 0 - +8 - 0 - +7 - -6 - 0 - 0 - LensDefaults - - - - +8 - 0 - +16 - 0 - 0 - 0 - 0 - +4 - 0 - False - 0 - 75 - 0 - 0 - 50 - 25 - 0 - 0 - 0 - 0.0 - 100 - 0 - 0 - 0.00 - 0.00 - 0 - 11.0 - IMG_0081.CR2 - +9 - 0 - -11 - 0 - 0 - -32 - 0 - 0 - 0 - 0 - 0 - 0 - 0 - 25 - 0 - +1.0 - 25 - 0 - 0 - 0 - 0 - 0 - 5750 - 0 - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - Linear - Custom - - - 0, 26 - 77, 54 - 127, 125 - 179, 195 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - 0 - 0 - 0.5 - 0.5 - 35 - 0 - 0 - False - 6 - 151388160 - 11.0 - +20 - 0 - As Shot - 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_47.txt b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_47.txt index ab81f9e9..f24f01c1 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_47.txt +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/txt/photo_47.txt @@ -1,683 +1,2 @@ File format : JPEG -Resolution : 3038 x 3038 ----- TIFF ---- -Version 42 -Little-endian (Intel, II) ----- Directory IFD0 @ 8 ---- -0000000010 0x010e ImageDescription = OLYMPUS DIGITAL CAMERA -0000000022 0x010f Make = OLYMPUS IMAGING CORP. -0000000034 0x0110 Model = E-M5MarkII -0000000046 0x011a XResolution = 240/1 (240.0) -0000000058 0x011b YResolution = 240/1 (240.0) -0000000070 0x0128 ResolutionUnit = 2 -0000000082 0x0131 Software = Adobe Photoshop Lightroom 6.14 (Windows) -0000000094 0x0132 ModifyDate = 2018:07:16 17:40:38 -0000000106 0x8769 ExifOffset = 258 - ----- Directory ExifIFD @ 258 ---- -0000000260 0x829a ExposureTime = 1/320 (0.003125) -0000000272 0x829d FNumber = 28/10 (2.8) -0000000284 0x8822 ExposureProgram = 3 -0000000296 0x8827 ISO = 500 -0000000308 0x8830 SensitivityType = 1 -0000000320 0x9000 ExifVersion = [0x30, 0x32, 0x33, 0x30] -0000000332 0x9003 DateTimeOriginal = 2018:07:13 19:38:07 -0000000344 0x9004 DateTimeDigitized = 2018:07:13 19:38:07 -0000000356 0x9201 ShutterSpeedValue = 8321928/1000000 (8.321928) -0000000368 0x9202 ApertureValue = 2970854/1000000 (2.970854) -0000000380 0x9204 ExposureCompensation = 0/10 (0.0) -0000000392 0x9205 MaxApertureValue = 768/256 (3.0) -0000000404 0x9207 MeteringMode = 5 -0000000416 0x9208 LightSource = 0 -0000000428 0x9209 Flash = 24 -0000000440 0x920a FocalLength = 150/1 (150.0) -0000000452 0xa001 ColorSpace = 1 -0000000464 0xa20e FocalPlaneXResolution = 87196351/32768 (2661.021454) -0000000476 0xa20f FocalPlaneYResolution = 87196351/32768 (2661.021454) -0000000488 0xa210 FocalPlaneResolutionUnit = 3 -0000000500 0xa300 FileSource = 3 -0000000512 0xa302 CFAPattern = [0x02, 0x00, 0x02, 0x00, 0x00, 0x01, 0x01, 0x02] -0000000524 0xa401 CustomRendered = 0 -0000000536 0xa402 ExposureMode = 0 -0000000548 0xa403 WhiteBalance = 0 -0000000560 0xa404 DigitalZoomRatio = 100/100 (1.0) -0000000572 0xa405 FocalLengthIn35mmFormat = 300 -0000000584 0xa406 SceneCaptureType = 0 -0000000596 0xa407 GainControl = 2 -0000000608 0xa408 Contrast = 0 -0000000620 0xa409 Saturation = 0 -0000000632 0xa40a Sharpness = 0 -0000000644 0xa431 BodySerialNumber = BHEA65641 -0000000656 0xa432 LensSpecification = [40/1 (40.0), 150/1 (150.0), 28/10 (2.8), 28/10 (2.8)] -0000000668 0xa434 LensModel = OLYMPUS M.40-150mm F2.8 -0000000680 0xa435 LensSerialNumber = ABV25833600 - ----- Directory IFD1 @ 902 ---- -0000000904 0x0103 Compression = 6 -0000000916 0x011a XResolution = 72/1 (72.0) -0000000928 0x011b YResolution = 72/1 (72.0) -0000000940 0x0128 ResolutionUnit = 2 -0000000952 0x0201 JpgFromRawStart = 996 -0000000964 0x0202 JpgFromRawLength = 11446 - ----- IPTC ---- -Date Created (55) = '20180713' -Time Created (60) = '193807' -Digital Creation Date (62) = '20180713' -Digital Creation Time (63) = '193807' -Caption/Abstract (120) = 'three yellow ducklings on body of water in close-up photography' -Keywords (25) = 'bird' -Keywords (25) = 'animal' -Keywords (25) = 'outdoors' -Keywords (25) = 'duck' - ----- XMP ---- - - - - - - True - 0/256 - True - OLYMPUS M.40-150mm F2.8 - 40/1 150/1 28/10 28/10 - ABV25833600 - BHEA65641 - - - - - - OLYMPUS DIGITAL CAMERA - - - image/jpeg - - - - 2018-07-13T19:38:07 - - - - 2018-07-13T19:38:07 - Adobe Photoshop Lightroom 6.14 (Windows) - 2018-07-16T17:40:38+03:00 - 2018-07-16T17:40:38+03:00 - 2 - - - - - 19C95676B875B72CBA76DB2803846421 - 19C95676B875B72CBA76DB2803846421 - - xmp.did:b18ed21a-e5ef-ed4b-b9e3-36eb3191b27c - - - - derived - converted from image/x-olympus-raw to image/jpeg, saved to new location - - - saved - / - xmp.iid:b18ed21a-e5ef-ed4b-b9e3-36eb3191b27c - Adobe Photoshop Lightroom 6.14 (Windows) - 2018-07-16T17:40:38+03:00 - - - - xmp.iid:b18ed21a-e5ef-ed4b-b9e3-36eb3191b27c - 19C95676B875B72CBA76DB2803846421 - - - - True - 1 - 134348800 - +25 - -15 - +25 - 160S - O - 0 - 25 - 50 - 50 - +38 - False - 5.22804 - 0.969844 - 0 - 0.185002 - 0.781537 - 0.01425 - 0 - 60 - 40 - 0 - 70 - 30 - 0 - 0.00 - 0 - -10 - -10 - True - True - -25 - 0 - +5 - +18 - +15 - +2 - +30 - +8 - 0 - 0 - 1 - LensDefaults - 0 - -10 - -15 - -25 - 0 - -10 - -20 - 0 - 0 - - - - true - 1.000000 - - - - 0.000000 - - - d 0.404990 0.560042 - - - 0.494000 - 1.000000 - 0.019615 - Mask/Paint - - - - 0.000000 - 0.000000 - 0.100000 - 0.000000 - 0.000000 - 0.000000 - 0.087500 - 0.000000 - 0.000000 - 0.000000 - 0.400000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 240.000000 - 0.000000 - 0.000000 - Correction - - - true - 1.000000 - - - - 0.000000 - - - d 0.376715 0.569064 - d 0.377427 0.558694 - d 0.378138 0.548324 - d 0.380399 0.538425 - d 0.383085 0.528775 - d 0.386593 0.519944 - d 0.385504 0.516475 - d 0.378134 0.517808 - d 0.373985 0.525869 - d 0.374559 0.536246 - d 0.374599 0.546625 - d 0.375754 0.556874 - d 0.377181 0.566903 - - - 0.494000 - 1.000000 - 0.026034 - Mask/Paint - - - 0.000000 - - - d 0.429040 0.654077 - d 0.431665 0.659028 - d 0.437549 0.659064 - d 0.443434 0.659099 - d 0.448315 0.657662 - d 0.449082 0.652453 - d 0.453900 0.655908 - d 0.458937 0.659909 - d 0.464198 0.663141 - d 0.469963 0.663990 - d 0.475610 0.666141 - d 0.481349 0.667865 - d 0.486797 0.670342 - d 0.488500 0.672110 - d 0.482756 0.672949 - d 0.476986 0.671575 - d 0.471209 0.670086 - d 0.465406 0.668817 - d 0.463083 0.668818 - d 0.468608 0.671393 - d 0.474300 0.673380 - d 0.479900 0.675769 - d 0.482506 0.681464 - d 0.487579 0.684993 - d 0.493140 0.687528 - d 0.498897 0.689151 - - - 0.494000 - 1.000000 - 0.019615 - Mask/Paint - - - 0.000000 - - - d 0.429825 0.618925 - d 0.432046 0.615320 - d 0.436548 0.620219 - d 0.434887 0.613064 - d 0.431890 0.606620 - d 0.428821 0.605788 - d 0.424807 0.609080 - d 0.422208 0.615796 - d 0.417310 0.619566 - d 0.412318 0.623297 - - - 0.494000 - 1.000000 - 0.019615 - Mask/Paint - - - - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - -0.038750 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 240.000000 - 0.000000 - 0.000000 - Correction - - - true - 1.000000 - - - - 0.000000 - - - d 0.505018 0.649247 - d 0.512106 0.645025 - d 0.519853 0.643702 - d 0.527454 0.641755 - d 0.534539 0.637449 - d 0.541338 0.632907 - d 0.546924 0.626947 - d 0.549725 0.632085 - d 0.542671 0.636047 - d 0.534953 0.637133 - d 0.533305 0.641372 - d 0.539342 0.646463 - d 0.546993 0.648403 - d 0.554148 0.650706 - d 0.550168 0.646192 - d 0.542418 0.644998 - d 0.535081 0.641677 - d 0.528558 0.635991 - d 0.520798 0.635989 - d 0.513424 0.633180 - d 0.506165 0.629866 - d 0.498387 0.628917 - d 0.490697 0.628553 - - - 0.494000 - 1.000000 - 0.026034 - Mask/Paint - - - 0.000000 - - - d 0.481896 0.612806 - d 0.487198 0.605184 - d 0.492640 0.597716 - d 0.498165 0.590357 - d 0.503923 0.583346 - d 0.509922 0.576991 - d 0.517511 0.574602 - - - 0.494000 - 1.000000 - 0.026034 - Mask/Paint - - - 0.000000 - - - d 0.536332 0.566304 - d 0.544053 0.564737 - d 0.551812 0.563574 - d 0.559609 0.563040 - d 0.567396 0.563587 - d 0.575174 0.564536 - d 0.582669 0.567305 - d 0.590267 0.569631 - d 0.597125 0.574205 - d 0.603653 0.579881 - - - 0.494000 - 1.000000 - 0.026034 - Mask/Paint - - - 0.000000 - - - d 0.600859 0.586107 - d 0.607397 0.591796 - d 0.613840 0.597681 - d 0.619843 0.604318 - d 0.625527 0.611457 - d 0.630492 0.619298 - d 0.635482 0.627244 - d 0.640688 0.634987 - - - 0.494000 - 1.000000 - 0.026034 - Mask/Paint - - - 0.000000 - - - d 0.633463 0.656241 - d 0.625851 0.653977 - d 0.626957 0.648804 - d 0.619501 0.646091 - d 0.611751 0.644916 - d 0.603966 0.644099 - d 0.596167 0.643534 - d 0.602079 0.640163 - d 0.608896 0.637589 - d 0.601158 0.638997 - d 0.593407 0.640210 - d 0.595007 0.638676 - d 0.599933 0.635891 - d 0.592344 0.638348 - d 0.584696 0.640460 - d 0.577605 0.642195 - - - 0.494000 - 1.000000 - 0.026034 - Mask/Paint - - - 0.000000 - - - d 0.406216 0.607369 - d 0.411749 0.605005 - d 0.417231 0.602150 - d 0.421804 0.597585 - d 0.425376 0.591438 - d 0.428118 0.584532 - d 0.428187 0.586151 - d 0.429801 0.584587 - d 0.433960 0.579374 - d 0.437241 0.572974 - - - 0.494000 - 1.000000 - 0.019615 - Mask/Paint - - - 0.000000 - - - d 0.362875 0.604792 - d 0.359960 0.598251 - d 0.356368 0.592537 - d 0.354109 0.585378 - d 0.356147 0.589672 - d 0.359237 0.596344 - d 0.362436 0.602895 - - - 0.494000 - 1.000000 - 0.019615 - Mask/Paint - - - - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.062500 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 0.000000 - 240.000000 - 0.000000 - 0.000000 - Correction - - - - 0 - 75 - 0 - 0 - 60 - 14 - 0 - 0 - 0 - 0.0 - 100 - 0 - 0 - 0.00 - 0.00 - -24 - 50 - 0 - 40 - -10 - 1 - 6.7 - +10 - 0 - +5 - -15 - 0 - -30 - -20 - -5 - -10 - -10 - 0 - 0 - +15 - 6 - 68 - +1.2 - 58 - 0 - 0 - 0 - 0 - 0 - 7400 - +30 - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - - - 0, 0 - 255, 255 - - - Linear - Custom - - - 0, 25 - 54, 60 - 111, 115 - 255, 255 - - - - - 0, 0 - 41, 23 - 119, 124 - 181, 199 - 255, 255 - - - - - 0, 0 - 41, 24 - 120, 118 - 185, 195 - 255, 255 - - - - - 0, 0 - 43, 25 - 120, 120 - 185, 195 - 255, 255 - - - - - 0, 0 - 255, 255 - - - 0 - 0 - 0.5 - 0.5 - 35 - 0 - 0 - False - 6 - 151388160 - 10.1 - 0 - 0 - Auto - 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file +Resolution : 260 x 773 diff --git a/src/commonTest/resources/com/ashampoo/kim/testdata/xmp/photo_41.xmp b/src/commonTest/resources/com/ashampoo/kim/testdata/xmp/photo_41.xmp index 3b66912b..3443ac98 100644 --- a/src/commonTest/resources/com/ashampoo/kim/testdata/xmp/photo_41.xmp +++ b/src/commonTest/resources/com/ashampoo/kim/testdata/xmp/photo_41.xmp @@ -1,35 +1 @@ - - - - - - 1 - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file +46004236502803460-0-4236-50280 \ No newline at end of file diff --git a/src/posixMain/kotlin/com/ashampoo/kim/Main.kt b/src/posixMain/kotlin/com/ashampoo/kim/Main.kt index 8c019245..42dbe7b1 100644 --- a/src/posixMain/kotlin/com/ashampoo/kim/Main.kt +++ b/src/posixMain/kotlin/com/ashampoo/kim/Main.kt @@ -54,7 +54,7 @@ fun main(args: Array) { * Show what the parsing result looks like */ - println("--- Ashampoo Photos Metadata ---") + println("--- Ashampoo Photo Organizer Metadata ---") val photoMetadata = metadata.convertToPhotoMetadata()