Was the camera used rear or front?

Started by 11august, February 23, 2020, 04:05:24 PM

Previous topic - Next topic

11august

Hi guys,

Is there a simple way, just by looking metadata, to determine if a smartphone (not Apple, but rather Samsung, Huawei...) photograph was taken either with a front camera or with a back camera?

I've extracted with the -g option all the metadata from a bunch of front/rear photos taken with a Samsung SM-J510N, Samsung SM-A202F and Huawei TRT-LX1 but can't really find any indication anywhere about the camera type used. I thought at first that the "exif.photo.scenecapturetype" tag could be interesting for that matter, but unfortunately there's no consistency in the way Samsung gives either the "0" or "4" value to this tag...

Any other idea?

Thanks! :)

Phil Harvey

I don't have a sample from either of these cameras, but you send me one from each of the cameras I'll take a look (4 pictures total).  My email is philharvey66 at gmail.com

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

11august

Hi Phil,

Thank you. I've just sent you six pictures total (two rear and front from the three camera).

Tonio

Phil Harvey

Hi Tonio,

You can tell the front camera for the Samsung SM-J510FN like this:

exiftool tmp2/20170821_1558* -SamsungTrailer_0x0910Name -u
======== tmp2/20170821_155805.jpg
======== tmp2/20170821_155845.jpg
Samsung Trailer 0x0910 Name     : Front_Cam_Selfie_Info
    2 image files read


(note: I may give this tag a name and extract it without the -u option if future versions of ExifTool).

As far as the other pictures go, I can't find any way to determine front/back camera for those.  (The other images may have had their metadata stripped, because I don't see the expected trailer for the Samsung images, and the Huawei images don't have the expected maker notes.)

Is it OK if I add these samples to the ExifTool metadata repository?  The image itself will be removed, and only the original thumbnail and metadata will be included.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

11august

Hi Phil and many thanks.

Of course, you can add my samples images to the repository.

As for the two other sets, it's somewhat odd as these are directly taken off the camera without any further modification/manipulation. But possibly no trailer/maker notes for these specifically?

Anyway, I've tried your code on a large bunch of Samsung sample photos and sometime it comes up with no results, sometimes it works with some other Samsung cameras, such as the SM-J500FN.

About the Huawei cameras, well no results at all, at the exception of MakerNotes Warning:

.\exiftool -HuaweiTrailer_x0910Name -u C:/4
======== C:/4/IMG_20171026_102936.jpg
Warning: [minor] Unknown APP9 segment - C:/4/IMG_20171026_102936.jpg
======== C:/4/IMG_20180422_151157.jpg
Warning: [minor] Unrecognized MakerNotes - C:/4/IMG_20180422_151157.jpg
======== C:/4/IMG_20180817_224621.jpg
======== C:/4/IMG_20190430_172842.jpg
Warning: [minor] Unrecognized MakerNotes - C:/4/IMG_20190430_172842.jpg
======== C:/4/IMG_20190518_005651.jpg
======== C:/4/tel elo19 1390.jpg
Warning: [minor] Unrecognized MakerNotes - C:/4/tel elo19 1390.jpg
======== C:/4/tel elo19 2399.jpg
Warning: [minor] Unrecognized MakerNotes - C:/4/tel elo19 2399.jpg
    1 directories scanned
    7 image files read


Phil Harvey

Thanks.

For the Huawei images with maker notes:  It is possible that the information you want is in there, but ExifTool doesn't decode Huawei maker notes yet.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).