[Idea] Matroska tagging support

Discussion in 'MPTagThat' started by chefkoch, April 1, 2013.

  1. chefkoch
    • Team MediaPortal

    chefkoch Retired Team Member

    Joined:
    October 5, 2004
    Messages:
    3,130
    Likes Received:
    1,456
    Gender:
    Male
    Location:
    Dresden / Munich / Maastricht
    Ratings:
    +1,773 / 1
    Home Country:
    Germany Germany
    Is there any interest in implementing Matroska support?

    For music this might be *.mka files.
    A similar structure (Artist, Album, Track, etc.) can be used for music videos, *.mkv files.
    Series/Episodes and Movies might need a slightly different structure.
    But the metadata itself is always a xml structure. (specification)

    The specification is very flexible and it is possible to build very complex tag structures using it, but I guess the most people would be happy to have a tagger which at least covers the basics, i.e. tagging a movie's summary in one language instead of tagging the summary for different languages.



    I started to write my own basic MkvTagger (forum), but it will tag only one file, not multiple ones.
    Also reinventing the wheel in terms of GUI, settings, files browser etc I would like to avoid.

    There is no matroska tagger available at all, yet. So the user base of MPTagThat will grow a lot if it would support it.

    Cheers,
    Tommy
     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. jameson_uk
    • Team MediaPortal

    jameson_uk Retired Team Member

    Joined:
    January 27, 2005
    Messages:
    7,258
    Likes Received:
    2,228
    Gender:
    Male
    Occupation:
    Data Warehousing Consultant
    Location:
    Birmingham
    Ratings:
    +2,403 / 0
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    I have talked about this before as a route to getting some ac3 music files into MP database. IIRC taglib# supports matroska tags now
     
  4. chefkoch
    • Team MediaPortal

    chefkoch Retired Team Member

    Joined:
    October 5, 2004
    Messages:
    3,130
    Likes Received:
    1,456
    Gender:
    Male
    Location:
    Dresden / Munich / Maastricht
    Ratings:
    +1,773 / 1
    Home Country:
    Germany Germany
    It does, but I took a closer look and it's not very useful in the current state.

    The Matroska specification can be found here:
    http://matroska.org/technical/specs/tagging/index.html
    here are audio & video examples:
    http://matroska.org/technical/specs/tagging/example-audio.html
    http://matroska.org/technical/specs/tagging/example-video.html
    here are some tvseries and movie examples:
    http://wiki.team-mediaportal.com/2_...lopment/3_Concepts/Metadata_system/MkvMatcher

    First of all it only reads the simple tags for: Author, Title, Album and comments
    https://github.com/chefkoch/taglib-sharp/blob/master/src/TagLib/Matroska/File.cs#L469-L479
    While these are not even enough, it also does not care about the TargetTypeValue
    http://matroska.org/technical/specs/tagging/index.html#targettypes
    This means a TITLE within a tag of a TargetTypeValue = 50 is the AlbumTitle, a title within the TargetTypeValue = 30 is the TrackTitle.
    Similar to the examples for TVSeries:
    TargetTypeValue = 70 > Series, TargetTypeValue = 60 > Season, TargetValueType = 50 > Episode
    http://wiki.team-mediaportal.com/2_...kvMatcher#Accurate_series_matching_by_IMDB_id

    So the title might be read not even correct, because it depends whether the Album or the Track title is the last one found in the file and used.
    Besides that taglib-sharp is not able to write Matroska tags.


    Within my tool I used mkvextract and mkvpropedit:
    First is to read the existing XML tags:
    http://www.bunkus.org/videotools/mkvtoolnix/doc/mkvextract.html#mkvextract.description.tags
    http://www.bunkus.org/videotools/mkvtoolnix/doc/mkvextract.html#mkvextract.output_redirection
    mkvpropedit is to write the tags back to the Matroska file without the need to remux it:
    http://www.bunkus.org/videotools/mkvtoolnix/doc/mkvpropedit.html#mkvpropedit.description.tags

    Having support without additional executable would be nice, but using these "official" Matroska tools ensures to create valid Matroska files.
     
  5. hwahrmann
    • Team MediaPortal

    hwahrmann Development Group

    Joined:
    September 15, 2004
    Messages:
    4,491
    Likes Received:
    1,623
    Gender:
    Male
    Location:
    Vienna, Austria
    Ratings:
    +2,248 / 1
    Home Country:
    Austria Austria
    Well, if there's a need, i can enhance taglib# to read the other values.

    I was also thinking of allowing ac3 files to be tagged by having for example something like an APE Tag at the end of the file or via CUE.
     
    • Like Like x 1
  6. chefkoch
    • Team MediaPortal

    chefkoch Retired Team Member

    Joined:
    October 5, 2004
    Messages:
    3,130
    Likes Received:
    1,456
    Gender:
    Male
    Location:
    Dresden / Munich / Maastricht
    Ratings:
    +1,773 / 1
    Home Country:
    Germany Germany
    That would be great, because it would allow all applications which are already using TagLib# to read the Matroska values.
    But like I already explained, it's not simply done by adding other values. The simple tags need to be checked against the targetTypeValue to differentiate correctly between Album tags and Track tags etc...

    Writing the matroska tags is also not implemented in taglib# at all, iirc. Without writing ability the Matroska support MPTagThat is not needed I guess.

    Maybe the Matroska implementation in taglib# could provide some Wrapper additional wrapper classes like: Series & Movie, similar to the extensions they made for ImageTags.
     
    Last edited: April 2, 2013
  7. hwahrmann
    • Team MediaPortal

    hwahrmann Development Group

    Joined:
    September 15, 2004
    Messages:
    4,491
    Likes Received:
    1,623
    Gender:
    Male
    Location:
    Vienna, Austria
    Ratings:
    +2,248 / 1
    Home Country:
    Austria Austria
    I need to look into the Matroska Tag information first.
    Don't know anything about it at the moment.
     
    • Like Like x 2
  8. chefkoch
    • Team MediaPortal

    chefkoch Retired Team Member

    Joined:
    October 5, 2004
    Messages:
    3,130
    Likes Received:
    1,456
    Gender:
    Male
    Location:
    Dresden / Munich / Maastricht
    Ratings:
    +1,773 / 1
    Home Country:
    Germany Germany
    Feel free to ask if you need any samples or I can assist you in any way.
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!