Cropping a CR2 file using the XMP profile
Posted: 2012-10-04T08:27:13-07:00
I was all set to write a custom cropping script using the crs:Crop settings in the XML profile by calculating those values as percentages of the original image dimensions. Then I noticed IM can read the profile using the -profile switch with an xmp: prefix on the profile filename. I tried running the command "convert abc005_L.CR2 -profile xmp:abc005_L.xmp abc005_L.tif" but the resulting tiff was uncropped. So is there a way for IM to automatically create a cropped version of a cr2 file on the command line (like I see when I open the cr2 in Photoshop) or will I have to go ahead and calculate the geometries and use them with a -crop switch as was my original plan?
crs:CropTop="0.342177"
crs:CropLeft="0.245271"
crs:CropBottom="0.830426"
crs:CropRight="0.776552"
crs:CropAngle="-0.450656"
crs:CropConstrainToWarp="1"
crs:HasCrop="True"
Thanks!
crs:CropTop="0.342177"
crs:CropLeft="0.245271"
crs:CropBottom="0.830426"
crs:CropRight="0.776552"
crs:CropAngle="-0.450656"
crs:CropConstrainToWarp="1"
crs:HasCrop="True"
Thanks!