Cannot fix makernotes offset

Started by Archive, May 12, 2010, 08:54:23 AM

Previous topic - Next topic

Archive

[Originally posted by ignavia on 2008-07-22 09:49:58-07]

I have been using F-Spot for managing my photos, but now I am very disappointed with it. First, I got a new camera in March that supports world time. I've noticed that F-Spot was displaying GMT for the EXIF time on all my photos, but I only recently discovered that it was REWRITING the EXIF times to reflect it! A big no-no! Then, when I tried to correct the errors with exiftool, I got the maker notes offset error. Unfortunately, the -F option did not fix my problem.

If anyone can help me, you can see one of my affected images here.

Also, here is another photo, this one straight from my camera, unaffected by F-Spot. Would someone would be willing to compare the EXIF data and tell me how I can most easily return my images to normal?

Thanks.

Joe

Archive

[Originally posted by exiftool on 2008-07-22 10:47:19-07]

There are no makernotes at all on the first image you posted.
(No makernote errors either, because they are completely
missing.)

- Phil

Archive

[Originally posted by ignavia on 2008-07-22 16:32:14-07]

Oh, apparently Flickr fixes that field when the photo is uploaded.

Try these:

Original photo from camera

After F-spot changes (with bad makernotes offset)

Thanks.

Archive

[Originally posted by exiftool on 2008-07-22 17:10:09-07]

Wow, this is a new one for me.  FSpot has deleted the makernotes
but left in the makernote tag with a data length of zero.  Since
it is not uncommon for some cameras write a data length which is
too small, exiftool allows the data to run outside the specified bounds.
Unfortunately, for this image this results in exiftool reading complete
garbage for the makernotes.  This is actually exiftool's problem, and
I will add a test to prevent this from happening.  What FSpot really
should have done was just remove the makernotes tag (since the
data itself is already gone).  You can do this with the following
exiftool command:

Code:
exiftool -makernotes:all= FILE

This, apparently, is what Flickr did too.

So the bottom line is that FSpot deleted your makernote information,
and there is no way to restore it unless you made backups of your
original images. Sad

- Phil

Archive

[Originally posted by ignavia on 2008-07-22 17:42:53-07]

But there are no makernotes in the straight-from-camera files, right? So I wouldn't be losing anything?

That should let me run the date correction command, which will take care of the big things, but I would like to restore the EXIF data completely to how it was straight from the camera. Looking at the edited vs unedited images, how could I do that? I know exiftool allows copying from one image to another, so I'm guessing that would be involved. Would it even be possible?

Thanks.

Archive

[Originally posted by exiftool on 2008-07-22 18:09:59-07]

If you have the original image, you can use it to copy the makernote
information to the edited image:

Code:
exiftool -tagsfromfile original.jpg -makernotes edited.jpg

There is a wealth of makernote information that comes in each image
straight out of a K10D.  Here is what exiftool decodes from the
makernotes of your original IMGP7255.JPG:

Code:
PentaxVersion: 3.0.0.0
PentaxModelType: 0
PreviewImageSize: 640x480
PreviewImageLength: 26557
PreviewImageStart: 2284
PentaxModelID: K10D
Date: 2008:07:20
Time: 11:01:10
Quality: Best
FlashMode: Off; Internal
FocusMode: AF-S
AFPointSelected: Upper-left
ISO: 100
ExposureCompensation: 0
MeteringMode: Multi-segment
AutoBracketing: 0 EV, No Extended Bracket
WhiteBalance: Flash
WhiteBalanceMode: User-Selected
WorldTimeLocation: Hometown
HometownCity: Chicago
DestinationCity: New York
HometownDST: No
DestinationDST: No
DSPFirmwareVersion: 1.30.00.18
CPUFirmwareVersion: 1.30.00.18
EffectiveLV: 12.5
ImageProcessing: Unprocessed
PictureMode: Flash X-Sync Speed AE; 1/3 EV steps
DriveMode: Single-frame; No Timer; Remote Control; Single Exposure
PreviewImageBorders: 26 26 0 0
LensType: smc PENTAX-FA 50mm F1.4
SensitivityAdjust: 0
ImageProcessingCount: 0
CameraTemperature: 25 C
AELock: Off
NoiseReduction: Off
FlashExposureComp: 0
ImageTone: Natural
SRResult: Not ready
ShakeReduction: Off
SRHalfPressTime: 0.00 s
SRFocalLength: 52 mm
ShutterCount: 7554
BlackPoint: 0 0 0 0
WhitePoint: 13632 8192 8192 8576
PictureMode2: Flash X-Sync Speed AE
ProgramLine: Normal
EVSteps: 1/3 EV steps
E-DialInProgram: Tv or Av
ApertureRingUse: Permitted
FlashOptions: Normal
MeteringMode2: Multi-segment
AFPointMode: Select
FocusMode2: AF-S
AFPointSelected2: Upper-left
ISOFloor: 100
DriveMode2: Remote Control
ExposureBracketStepSize: 0.7
BracketShotNumber: n/a
WhiteBalanceSet: Flash
MultipleExposureSet: Off
RawAndJpgRecording: RAW+JPEG (PEF, Best)
JpgRecordedPixels: 10 MP
FlashOptions2: Normal
MeteringMode3: Multi-segment
SRActive: No
Rotation: Rotate 90 CW
ISOSetting: Auto
SensitivitySteps: As EV Steps
TvExposureTimeSetting: 0.3
AvApertureSetting: 5.7
SvISOSetting: 100
BaseExposureCompensation: 0
AEExposureTime: 1/171
AEAperture: 5.7
AE_ISO: 100
AEXv: 0
AEBXv: 0
AEMinExposureTime: 1/3862
AEProgramMode: Av, B or X
AEMaxAperture: 1.4
AEMaxAperture2: 1.4
AEMinAperture: 23
AEMeteringMode: Multi-segment
FlashExposureCompSet: 0
AutoAperture: On
MinAperture: 22
LensFStops: 8
NominalMaxAperture: 1.4
NominalMinAperture: 23
MaxAperture: 1.4
FlashStatus: Off
InternalFlashMode: Off, Normal
ExternalFlashMode: Off
InternalFlashStrength: 40
TTL_DA_AUp: 0
TTL_DA_ADown: 0
TTL_DA_BUp: 0
TTL_DA_BDown: 0
ExternalFlashGuideNumber: n/a
ExternalFlashExposureComp: n/a
ExternalFlashBounce: n/a
AEMeteringSegments: 5.0 5.4 5.9 5.1 5.4 5.1 5.4 5.5 5.1 4.9 5.0 5.5 5.1 5.2 5.4 5.1
FlashMeteringSegments: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
SlaveFlashMeteringSegments: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
WB_RGGBLevelsDaylight: 13600 8192 8192 8765
WB_RGGBLevelsShade: 16128 8192 8192 6635
WB_RGGBLevelsCloudy: 14560 8192 8192 7782
WB_RGGBLevelsTungsten: 8192 8192 8192 20971
WB_RGGBLevelsFluorescentD: 17376 8192 8192 8847
WB_RGGBLevelsFluorescentN: 14528 8192 8192 10076
WB_RGGBLevelsFluorescentW: 13088 8192 8192 12206
WB_RGGBLevelsFlash: 13632 8192 8192 8601
ManufactureDate: 2007:11:16
ProductionCode: 2.1
InternalSerialNumber: 4682868
PowerSource: Body Battery
BatteryStates: Body Battery Full; Grip Battery Empty or Missing
BatteryADBodyNoLoad: 172 (7.6V, 48%)
BatteryADBodyLoad: 167 (7.3V, 44%)
BatteryADGripNoLoad: 5
BatteryADGripLoad: 1
AFPredictor: -43
AFDefocus: 31
AFIntegrationTime: 134 ms
AFPointsInFocus: Upper-left, Top
WBShiftAB: 0
WBShiftMG: 0

- Phil

Archive

[Originally posted by ignavia on 2008-07-22 19:39:38-07]

Ack! That's a lot of lost data. Now that I'm comparing the output of exiftool side by side for the images, I can see the difference.

Is there any way that data is still in the image file? Is there any possibility of getting it back? I've imported all my photos into F-spot, unfortunately, so if it's gone, it's gone for all of them.

I do not have any originals (except the ones I haven't imported since I discovered this issue.

Thanks for all your help, Phil.

Archive

[Originally posted by exiftool on 2008-07-23 00:02:57-07]

Sorry.  I took a close look at the image you posted and couldn't
find any trace of the original makernote data.  So I think it
is gone for good. Sad

- Phil

Archive

[Originally posted by exiftool on 2008-07-23 00:05:44-07]

I should mention that F-spot isn't the only utility that deletes
the makernotes.  Adobe Photoshop also does this. (At least older
versions -- I haven't verified that  CS3 still does this,
but it would surprise me if they didn't.)

- Phil

Archive

[Originally posted by justin on 2008-07-23 08:05:20-07]

I have learnt this lesson the hard way too - having 'evaluated' many applications in ignorance of the finer details of meta data storage. I have recently concluded that I am best served by keeping a master library of images as shot and having a working library to assign meta et. al.

The only correction I can think I would like to make to the master images is possibly a time shift due to forgetting to change the camera's time but right now I'm even sceptical about doing that - especially with RAW images. Phil - are you able to comment on whether or not exiftool can shift a time on, for example, a Nikon RAW image file (.NEF) without changing anything else in the meta? I seem to recall a thread where someone said that by default the date time info was stored in the Exif and IFD0 areas and yet exiftool only updates the Exif data - setting the IFD0 to null?

Archive

[Originally posted by ignavia on 2008-07-23 09:40:47-07]

But the difference is that Photoshop is an image editor. While it's still not great, I would almost expect it there. But F-spot is not supposed to be changing my images at all. What I found out is that it does not, as long as you don't allow writing tags to files. By enabling that, I destroyed a lot of data. Fortunately, the image data and all the essential EXIF data is intact. Those are most important.

Archive

[Originally posted by exiftool on 2008-07-23 09:54:34-07]

Hi Justin,

IFD0 is one directory in the EXIF information.  ExifTool does not zero this.
You may be referring to the problem where some tags are duplicated
between the ExifIFD and IFD0.  ExifTool will remove the duplicate tag
if it exists when you are writing that specific tag.  However, no information
is lost since this tag exists in another location (and it really shouldn't
have been duplicated to begin with).  I'm not sure that NEF images have
this duplicated tag problem anyway.

I always recommend keeping backups of your originals, but there should
be absolutely no information or image loss when editing NEF with exiftool.

- Phil

Archive

[Originally posted by justin on 2008-07-23 10:21:33-07]

Thanks Phil, that's reassuring. I guess if I've been forgetful when travelling and not changed the camera's time, I can always keep a before and after time shift copy in my master archive. Justin..