Main Menu

XML to File

Started by armin2017, June 30, 2017, 02:58:28 PM

Previous topic - Next topic

armin2017

Hi, i start to learn how to use exiftool. Is it basically possible to read out the data from an xml file (contains the metadata of a videofile) end bake this into the metadata of this videofile?

I have videofiles recorded with the Odyssey 7q external recorder. This recorder writes i.e. a *.mov and a *.xml file

I want to have these information inside the .mov file. then I can extract the data of the .mov file to a .csv file. This I can import in resolve and I have all informations within the .mov file in resolve

Phil Harvey

Yes, you can do this, but you will probably have to create some user-defined XMP tags to store what you want.  XMP is RDF/XML wrapped in an xpacket  wrapper.  See the sample config file for examples on how to define custom XMP tags.

- 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 ($).

armin2017

Ok. Thanks a lot. I was looking at the link... O.M.G.... I am a video enthusiast and not a programmer
;)

I can't do this. Have to live without Metadata.


armin2017

#3
playing around. I am able to read out the tags I want from xml file and write them into a new .csv file

exiftool -Cd_xmlCd_statsProduct -Cd_xmlLutdataLut_project /Users/armin/Desktop/a.XML -csv -r > /Users/armin/Desktop/out.csv

how can I change the names of the tags in the new .csv file?

i.e. I need -Cd_xmlLutdataLut_project must be -LUT Used On Set

if I change it (for testing) manually in -LUT Used On Set then resolve can read and add it into my clips

Thanks for any help. And again Sorry I am a absolut neewbee to that

Phil Harvey

If you use the CSV option then the column headings are the tag names and you can't change that.

But you can do something like this to write any column heading you want:

exiftool -echo "Cd_xmlCd_statsProduct,LUT Used On Set" -p "$Cd_xmlCd_statsProduct,$Cd_xmlLutdataLut_project" -r DIR

- 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 ($).