[matroska-devel] Re: Matroska Tags

Pamel Paul at msn.com
Sun Apr 13 02:06:34 CEST 2003


I was talking with Jory about where to put the tags and I would like to
share some of the solutions.  The problem is that there can be informational
tags that relate to just a track, just a chapter, multiple tracks/chapters,
or the whole file.  There are also two places to store the tags, in the Info
element, and under the Chapters element.

First, we decided to condense all of this information together in the same
place to avoid duplication.  Then, we create a new Tags sub-element under
the Information element to store all of the tags under.  There can be
multiple Tags sub-elements, each with an identifying element in it to
indicate what Tracks/Chapters/All the tags contained therein belong to.  All
informational (non-technical/unneeded) elements are to be moved here.

Second, because the track numbers can change, and people will give multiple
tracks the same name, we decided to create a unique ID for each track and
chapter.  This ID is like the SegmentUID, except that it will only be 16bits
instead of 128bits, so save space.  The identifier tag will use this to
associate the track/chapter so that it doesn't matter if the track/chapter
number/name is changed, the tags will still be properly associated.

Third, there are a lot of dates that people like to store in tags.  To
lessen the number of dates, will will create an element like the MultiEntity
element to deal specificaly with Dates.  For the explanation we will call
there MultiDate, DateFunction, Date, DateEnd, and Comments.

Fourth, the comments.  Something in the WMP9 specs that currently has us
beat is the ability to store comments in multiple languages, and to specify
the language you are using for each comment.  So, we will be adding a
generic MultiComments sub-element to hold the Comments element and the
Language element.

This will add about 11 new elements, but will remove about 20 old ones.  So,
the changes will decrease the total number of needed elements defined, and
will increase the functionality of those that are left, as well as resolving
some logistical issues.  Below is an example of what the tags should look
like.


<Info>
    <Tags>
        <TrackTag>
        <ChapterTag>
        <MultiEntity>
              <EntityFunction>
              <EntityName>
              <EntityURL>
              <EntityEmail>
              <EntitySort>
              <MultiComment>
                  <Comment>
                  <Language>
        <MultiDate>
            <DateFunction>
            <Date>
            <DateEnd>
                <MultiComment>
                    <Comment>
                    <Language>
        <OtherTags>


And again in proper XML.

<Info>
  <Tags>
    <Track />
    <Chapter />
    <MultiEntity>
      <EntityFunction />
      <EntityName />
      <EntityURL />
      <EntityEmail />
      <EntitySort />
      <MultiComment>
        <Comment />
        <Language />
      </MultiComment>
    </MultiEntity>
    <MultiDate>
      <DateFunction />
      <Date />
      <DateEnd />
      <MultiComment>
        <Comment />
        <Language />
      </MultiComment>
    </MultiDate>
    <OtherTags />
  </Tags>
</Info>


Pamel



http://www.matroska.org



More information about the Matroska-devel mailing list