I’ve been looking for a method that works for removing the Title and Comments section of file properties. I’d prefer it to be via command prompt to setup a script to loop through a directory but im open to any suggestions. I’ve found some options via google but haven’t been able to get any of them to work on video files. Most results seem to only work on picture files or PDF’s.
The issue im having is plex reads the Title or Comment section over the file name. If i delete the Title and Comment section the file gets auto named properly in plex. This is a easy method but i’ve got about a few hundred files located in various sub folders among about 2000 some files.
You should be able to script something with https://www.mp3tag.de
Take a look into their support forums.
You can select hundreds at the same time and goto the prop window and remove the metadata that way.
The only other method I know involves removing all metadata from mp4(I’m assuming this is the type).
It’s a command prompt .CMD script I use myself BUT it clears ALL data including track information such as track language(need to fix, too lazy) and track comments. It takes a few seconds per file as it re-muxes the file. I’m not sure if it will copy subtitles and such cause MKV are reserved for that. I do not use any other container when it comes to subtitles.
ffmpeg.exe -y -i "TheFileToMux.mp4" -c copy -map_metadata -1 "TheNewFile.mp4"
@ECHO OFF
FOR %%F IN ("*.mp4") DO (
REM # Replace any existing file(Not the original file though)
REM ffmpeg.exe -y -i "%%F" -c copy -map_metadata -1 "%%F.MetadataRemoved.mp4"
REM # Prompt to replace any existing file(Not the original file though)
ffmpeg.exe -i "%%F" -c copy -map_metadata -1 "%%F.MetadataRemoved.mp4"
)
PAUSE
EDIT: If it matters. This snippet uses ffmpeg.exe v3.4.2. It may work with older versions but I haven’t tested…
Interesting enough. If you change the option -map_metadata -1 to -map_metadata:c -1 it will clear out the track comments and keep the track language. Definitely a bonus. But it won’t remove the two fields you are asking for. But there are so many options to choose from. Here’s the documentation.
https://www.ffmpeg.org/ffmpeg.html
I couldn’t help myself.
ffmpeg.exe -i "%%F" -c copy -metadata title="" -metadata comment="" -metadata:s language=und -metadata:s:a: language=eng "%%F.MetadataRemoved.mp4"
Seems to clear out the title and comments, also clears out the video track comments and audio track comment and set the video language to und(nothing) and the audio track language to English.
Not really sure how all the -metadata work together but they seem to. Again, I’m not sure about sub’s.
Awesome! that did the trick cleaning the files of the meta data. Thanks!!