luqmaan / Curved-App

1 stars 0 forks source link

How to use ALAsset metadata to determine if image is a panorama #8

Open luqmaan opened 11 years ago

luqmaan commented 11 years ago

This is what I got after plugging in one of Adam's panorama images.

What FAST ways can you think of for determining if the image is a panorama?

Only ways I can think of is:

Metadata

TestAssetLibrary[42042:c07] 3 ALAsset - Type:Photo, URLs:assets-library://asset/asset.JPG?id=9C719D79-2E05-4848-AA70-6A455CCB2513&ext=JPG
2013-01-05 12:15:39.553 TestAssetLibrary[42042:c07] {
    ColorModel = RGB;
    DPIHeight = 72;
    DPIWidth = 72;
    Depth = 8;
    Orientation = 1;
    PixelHeight = 2352;
    PixelWidth = 8704;
    "{Exif}" =     {
        ApertureValue = "2.526069";
        BrightnessValue = "9.813173";
        ColorSpace = 1;
        ComponentsConfiguration =         (
                                           0,
                                           0,
                                           0,
                                           1
                                           );
        CustomRendered = 6;
        DateTimeDigitized = "2012:10:06 13:12:43";
        DateTimeOriginal = "2012:10:06 13:12:43";
        ExifVersion =         (
                               2,
                               2,
                               1
                               );
        ExposureMode = 0;
        ExposureProgram = 2;
        ExposureTime = "0.0005530973";
        FNumber = "2.4";
        Flash = 0;
        FlashPixVersion =         (
                                   1,
                                   0
                                   );
        FocalLenIn35mmFilm = 33;
        FocalLength = "4.13";
        ISOSpeedRatings =         (
                                   50
                                   );
        MeteringMode = 5;
        PixelXDimension = 8704;
        PixelYDimension = 2352;
        SceneCaptureType = 0;
        SensingMethod = 2;
        ShutterSpeedValue = "10.82043";
        WhiteBalance = 0;
    };
    "{TIFF}" =     {
        DateTime = "2012:10:06 13:12:43";
        Make = Apple;
        Model = "iPhone 5";
        Orientation = 1;
        ResolutionUnit = 2;
        Software = "6.0";
        XResolution = 72;
        YResolution = 72;
        "_YCbCrPositioning" = 1;
    };
}
luqmaan commented 11 years ago

@adeaux Can you send me some regular photos from your iPhone 5 for comparison please?

luqmaan commented 11 years ago

In the normal photo this line is missing.

CustomRendered = 6;

In the panorama photo, this is missing. However, I think this number would also be missing for images where the subject area (that touch and focus on an area thing ?) is not set. Although, isn't it always set when you take a photo with the camera app? http://developer.apple.com/library/mac/#releasenotes/AudioVideo/RN-AVFoundation/_index.html#//apple_ref/doc/uid/TP40010717-CH1-DontLinkElementID_15

SubjectArea = (
    1631,
    1223,
    881,
    881
);

In the panorama this is Quicktime, in the normal photo it is 6.0:

Software = "QuickTime 7.7.1";

Failed attempts:

luqmaan commented 11 years ago

@adeaux Could you also make sure your iPhone is up to date and take another panorama and send that to me please?

I want to see if the line Software = "QuickTime 7.7.1"; changes. The current version of QuickTime is 7.7.3. I also want to see if your normal photos have the Software = "6.0.2".

adeaux commented 11 years ago

6.0.2 has some pretty bad known battery issues, must I?

Photos attached

On Saturday, January 5, 2013 at 12:50 PM, Luqmaan Dawoodjee wrote:

@adeaux https://github.com/adeaux Could you also make sure your iPhone is up to date and take another panorama and send that to me please?

I want to see if the line Software = "QuickTime 7.7.1"; changes. The current version of QuickTime is 7.7.3. I also want to see if your normal photos have the Software = "6.0.2".

— Reply to this email directly or view it on GitHubhttps://github.com/createch/Curved-App/issues/8#issuecomment-11917067.

luqmaan commented 11 years ago

You don't need to. Thanks homie.

On Jan 6, 2013, at 3:07 PM, adeaux notifications@github.com wrote:

6.0.2 has some pretty bad known battery issues, must I?

Photos attached

On Saturday, January 5, 2013 at 12:50 PM, Luqmaan Dawoodjee wrote:

@adeaux https://github.com/adeaux Could you also make sure your iPhone is up to date and take another panorama and send that to me please?

I want to see if the line Software = "QuickTime 7.7.1"; changes. The current version of QuickTime is 7.7.3. I also want to see if your normal photos have the Software = "6.0.2".

— Reply to this email directly or view it on GitHubhttps://github.com/createch/Curved-App/issues/8#issuecomment-11917067.

— Reply to this email directly or view it on GitHubhttps://github.com/createch/Curved-App/issues/8#issuecomment-11933431.