I recently had to reinstall my computer and so started again with a new install of Picard. I used to have a plugin which read .mkv and some other video files into Picard and could rename them… I now can’t find it to reinstall… does it still exist (I’m still using 2.6.4)
At a cursory glance, it looks like that plugin may have removed around 6 months ago:
1 Like
Yes, I removed this plugin recently because it was utterly broken since Picard switched to Python 3, all the tag writing code no longer worked. I wanted to actually write a proper Matroska plugin, but did not find the time to finish this yet.
If your only goal is to be able to load and rename Matroska files, without reading and writing tags, then you could use this simple plugin (untested):
PLUGIN_NAME = "Matroska file format"
PLUGIN_AUTHOR = "Philipp Wolfer"
PLUGIN_DESCRIPTION = "Allow loading and renaming Matroska files. No tagging."
PLUGIN_VERSION = '0.1'
PLUGIN_API_VERSIONS = ["2.0", "2.1", "2.2", "2.3", "2.4", "2.5", "2.6", "2.7", "2.8"]
PLUGIN_LICENSE = "GPL-2.0-or-later"
PLUGIN_LICENSE_URL = "https://www.gnu.org/licenses/gpl-2.0.html"
from picard.file import File
from picard.formats import register_format
from picard.metadata import Metadata
class MatroskaFile(File):
EXTENSIONS = [".mka", ".mkv", ".webm"]
NAME = "Matroska"
def _load(self, filename):
metadata = Metadata()
# Implement loading and parsing the file here.
# This method is supposed to return a Metadata instance filled
# with all the metadata read from the file.
metadata['~format'] = self.NAME
return metadata
def _save(self, filename, metadata):
# Implement saving the metadata to the file here.
pass
register_format(MatroskaFile)
Just put the above in a text file, call it e.g. matroska.py
and load that via “Install plugin” in Picard Options > Plugins
4 Likes
Thanks.
I was just a bit mystified … will test that code sometime