Page 1 of 2

Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 12:05
by timoteo
Is there a way to search metadata? Specifically I want to search WAV files that have keywords in the "Comments" section of the metadata . Is this possible?

Thanks!

-Tim

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 12:25
by highend
Upload such a file (that contains a comment)...

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 12:57
by timoteo
I'll try to find something. Most of the stuff is copyrighted, so I can't upload those. However, I can tell you that it is Comments with the field ID "ICMT" if that helps. Also, see the attached screen shot to see the field I am talking about inside Xyplorer. Does that help?

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 13:26
by highend
Get this script: viewtopic.php?p=150223#p150223

Extract it and run it while that "BWF_AmbCity-32_w..." file is selected. Does the output of it show a column that has the Ambience, City, Traffic, Birds content?
If yes, show it...

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 13:37
by timoteo
Here you go ...

...
IDs with names & values: 31
===========================
#001 | Size: 16.5 MB
#002 | Item type: Windows Media Player
#003 | Date modified: 9/4/2020 6:53 AM
#004 | Date created: 9/4/2020 6:53 AM
#005 | Date accessed: 9/4/2020 6:53 AM
#006 | Attributes: A
#009 | Perceived type: Audio
#010 | Owner: Administrators
#011 | Kind: Music
#013 | Contributing artists: BWFX
#015 | Year: 2015
#016 | Genre: Ambience
#019 | Rating: Unrated
#020 | Authors: BWFX
#021 | Title: Amb City-w-traff
#024 | Comments: Ambience, City, Traffic, Birds

...

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 13:48
by highend
Try this in the Name: field (Name & Location tab):
prop:comments:<search term>
e.g.
prop:comments:traffic

if comments doesn't work, use #024 instead:
prop:#024:traffic

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 13:54
by timoteo
Second one (prop:#024:traffic) was the ticket! THANKS highend!! Lifesaver! :appl:

One final question though ... Probably won't come up too often, but let's say I wanted to search for a specific name of the file ... how can I enter that AND the "prop:#024:xxxxx" meta search at the same time? Is this possible?

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 14:00
by highend
:name:<part of a file name> AND prop:#24:traffic

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 14:07
by timoteo
AWESOME! THANK YOU!!!!

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 15:06
by timoteo
While I have your "ear" ... Is there a way in XY to edit metadata ... that is, could I edit the "Comments"? I looked at EXIFTOOLGUI, but it appears to only have a limited number of fields it can edit, and is geared more towards images.

EDIT: I actually can do it in SoundForge (and I'm sure other audio editors) but it is not as efficient of course, as opposed to working in something like XY.

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 15:11
by highend
Only via scripting and not without a third party CLI tool. So if e.g. exiftool is able to write these tags, it's possible...

Re: Is there a way to search metadata in .wav files?

Posted: 04 Sep 2020 21:18
by mazot
I thought of ffmpeg as a CLI tool , and searched and found loads of info on metadata , BUT of course with ffmpeg nothings
straight forward .
I did a search on https://forum.level1techs.com/t/wav-fil ... r/125792/5 and found this "Mastic_Warrior
Mar '18
WAV files were not designed or amended to store complex metadata. If this is for a personal music collection, I would recommend using FLAAC instead. That is basically a wrapper around an uncompressed WAV (if you encode it properly). You can then do the nifty MP3 tag stuff with that and still have your high bit rate audio."
IHTH.

Re: Is there a way to search metadata in .wav files?

Posted: 05 Sep 2020 02:35
by timoteo
mazot wrote: ↑04 Sep 2020 21:18 I thought of ffmpeg as a CLI tool , and searched and found loads of info on metadata , BUT of course with ffmpeg nothings
straight forward .
I did a search on https://forum.level1techs.com/t/wav-fil ... r/125792/5 and found this "Mastic_Warrior
Mar '18
WAV files were not designed or amended to store complex metadata. If this is for a personal music collection, I would recommend using FLAAC instead. That is basically a wrapper around an uncompressed WAV (if you encode it properly). You can then do the nifty MP3 tag stuff with that and still have your high bit rate audio."
IHTH.
Unfortunately, Mastic_Warrior managed to get almost every single thing wrong in that post, lol. WAV files most certainly were/are made to include complex metadata. In fact, that is one of their most powerful features. They will even retain markers and notes on those markers for sound editing programs. Also, WAV files are (almost) always an uncompressed format, and FLAAC is not a wrapper around a uncompressed WAV. FLAAC, while lossless, is a compression format -- think of it almost like the lossless zip file of the audio domain. Honestly not sure what type of embedding it supports as I've never really had a need to use it.

This is definitely a case of "don't trust everything you read on the internet".

Re: Is there a way to search metadata in .wav files?

Posted: 07 Sep 2020 11:46
by highend
At least you could use ffmpeg to script the whole thing, although not without creating (at least) a temporary file (no in-place editing of metadata)...

Re: Is there a way to search metadata in .wav files?

Posted: 08 Sep 2020 09:39
by highend
Starting the script (reads the metadata of the selected file):
01.png
After editing the metadata:
02.png
And this is how it looks when ffmpeg outputs of what was written:
03.png
You need to edit the path to ffmpeg in the script!
Not heavily tested...
It does not handle deleting the original file and renaming the new one into the old name (I don't want to destroy the original file)...
Write .wav metadata [ffmpeg]_v0.1.xys