On Mar 6, 2010, at 2:42 PM, Silvia Pfeiffer wrote:
>
> I don't think we need to make it this complicated.
>
> If I understand it correctly, in MPEG, track groups are built by
> giving each track of the same group the same identifier. This could
> just be replicated in the JavaScript API:
>
> interface MediaTrack {
> ...
> readonly attribute DOMString groupname;
> ...
> }
>
> Then the functions of getting all tracks that belong to the same group
> can be built as convenience functions on top of this one attribute.
>
> Seeing as the majority of use cases will not include grouping (e.g. I
> wasn't able to find a single MPEG file that has track groups), this
> simpler JavaScript API looks preferable to me and will be easier to
> deal with for a script author IMHO.
>
I agree that we should not make this overly complicated and I agree with your suggestion generally, but I think "groupId" would be a better name for the attribute than "groupname". Alternate group in ISO and QuickTime files is an integer, and while it may be a string in other container formats I don't think we should imply that the attribute is anything but an identifier.
eric