Linux, FreeBSD, Juniper, Cisco / Network security articles and troubleshooting guides

FAQ
It is currently Mon Dec 11, 2017 8:15 am


System administration, processes administration, jobs, cron, resources, limits, shells, ssh, telnet.

Author Message
admin
Post  Post subject: MAC OS X: read image/jpeg EXIF information on command line  |  Posted: Mon Sep 11, 2017 8:52 am
Site Admin

Joined: Mon Aug 03, 2009 8:43 am
Posts: 104

Offline
 

MAC OS X: read image/jpeg EXIF information on command line

MAC OS X provides a tool to analyze image/jpeg EXIF metadata, including GPS coordinates of the photo, the camera it was taken on and so on.


Quote:
MDLS(1) BSD General Commands Manual MDLS(1)

NAME
mdls -- lists the metadata attributes for the specified file

SYNOPSIS
mdls [-name attributeName] [-raw [-nullMarker markerString]] file ...

DESCRIPTION
The mdls command prints the values of all the metadata attributes associated with the files provided as an argument.

The following options are available:

-name Print only the matching metadata attribute value. Can be used multiple times.

-raw Print raw attribute data in the order that was requested. Fields will be separated with a ASCII NUL character, suitable for piping to xargs(1) -0.

-nullMarker Sets a marker string to be used when a requested attribute is null. Only used in -raw mode. Default is "(null)".

SEE ALSO
mdfind(1), mdutil(1) xargs(1)

Mac OS X June 3, 2004 Mac OS X


See kMDItemLatitude and kMDItemLongitude objects.

Code:
$ mdls IMG_2368.jpg
kMDItemAcquisitionMake         = "Apple"
kMDItemAcquisitionModel        = "iPhone 7"
kMDItemAltitude                = 1741
kMDItemAperture                = 1.695993715632365
kMDItemBitsPerSample           = 32
kMDItemColorSpace              = "RGB"
kMDItemContentCreationDate     = 2017-09-10 12:36:23 +0000
kMDItemContentModificationDate = 2017-09-10 12:36:23 +0000
kMDItemContentType             = "public.jpeg"
kMDItemContentTypeTree         = (
    "public.jpeg",
    "public.image",
    "public.data",
    "public.item",
    "public.content"
)
kMDItemCreator                 = "10.3.1"
kMDItemDateAdded               = 2017-09-10 12:36:23 +0000
kMDItemDisplayName             = "IMG_2368.jpg"
kMDItemEXIFVersion             = "2.2.1"
kMDItemExposureMode            = 0
kMDItemExposureProgram         = 2
kMDItemExposureTimeSeconds     = 0.0007518796992481203
kMDItemFlashOnOff              = 0
kMDItemFNumber                 = 1.8
kMDItemFocalLength             = 3.99
kMDItemFSContentChangeDate     = 2017-09-10 12:36:23 +0000
kMDItemFSCreationDate          = 2017-09-10 12:36:23 +0000
kMDItemFSCreatorCode           = ""
kMDItemFSFinderFlags           = 0
kMDItemFSHasCustomIcon         = (null)
kMDItemFSInvisible             = 0
kMDItemFSIsExtensionHidden     = 0
kMDItemFSIsStationery          = (null)
kMDItemFSLabel                 = 0
kMDItemFSName                  = "IMG_2368.jpg"
kMDItemFSNodeCount             = (null)
kMDItemFSOwnerGroupID          = 935
kMDItemFSOwnerUserID           = 20037
kMDItemFSSize                  = 2122637
kMDItemFSTypeCode              = ""
kMDItemGPSDateStamp            = "2017:09:06"
kMDItemGPSDestBearing          = 6.521270561542825
kMDItemHasAlphaChannel         = 0
kMDItemImageDirection          = 6.521270221689634
kMDItemISOSpeed                = 20
kMDItemKind                    = "JPEG image"
kMDItemLastUsedDate            = 2017-09-11 13:53:31 +0000
kMDItemLatitude                = 45.46824166666666
kMDItemLogicalSize             = 2122637
kMDItemLongitude               = 25.47102166666667
kMDItemOrientation             = 0
kMDItemPhysicalSize            = 2125824
kMDItemPixelCount              = 12192768
kMDItemPixelHeight             = 3024
kMDItemPixelWidth              = 4032
kMDItemProfileName             = "Display P3"
kMDItemRedEyeOnOff             = 0
kMDItemResolutionHeightDPI     = 72
kMDItemResolutionWidthDPI      = 72
kMDItemSpeed                   = 0.01376021798365123
kMDItemTimestamp               = "11:04:53"
kMDItemUseCount                = 3
kMDItemUsedDates               = (
    "2017-09-10 22:00:00 +0000"
)
kMDItemWhiteBalance            = 0


Code:
$ mdls -name kMDItemLatitude -name kMDItemLongitude IMG_2368.jpg
kMDItemLatitude  = 45.46824166666666
kMDItemLongitude = 25.47102166666667

_________________
VPSie - SSD VPS servers in AMS-IX, LINX, DE-CIX
https://vpsie.com





Top
Display posts from previous:  Sort by  
E-mail friendPrint view

Topics related to - "MAC OS X: read image/jpeg EXIF information on command line"
 Topics   Author   Replies   Views   Last post 
There are no new unread posts for this topic. How to read UFS filesystem super block information in FreeBSD

mandrei99

0

1586

Mon Jul 22, 2013 9:52 am

mandrei99 View the latest post

There are no new unread posts for this topic. How to print filesystem super block information in Linux

mandrei99

0

7940

Mon Jul 08, 2013 6:56 am

mandrei99 View the latest post

There are no new unread posts for this topic. Linux network interface pci slot information - lspci / Intel or Broadcom

mandrei99

0

4723

Fri Jan 16, 2015 7:58 pm

mandrei99 View the latest post

There are no new unread posts for this topic. FreeBSD - How to retrieve the newfs command that was used to create an existing UFS filesystem

mandrei99

0

804

Mon Jul 22, 2013 9:55 am

mandrei99 View the latest post

 

Who is online
Users browsing this forum: No registered users and 0 guests
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum
Jump to:  
News News Site map Site map SitemapIndex SitemapIndex RSS Feed RSS Feed Channel list Channel list


Delete all board cookies | The team | All times are UTC - 5 hours [ DST ]



phpBB SEO