That’s an excellent question, and I’m glad you asked. I hadn’t decided on the way I feel is best for that yet. Let me offer a couple of options and see what folks think.
Option 1: Using an apis
record
The first option: add an apis
record to each container and codec record to indicate browser support for the container or codec in that API. Something like the following:
"mp4": {
...
"apis": {
"html": {
"__compat": {
"support": {
"firefox": {
"version_added": "48"
}
},
"status": {
"experimental": false,
"standard_track": true,
"deprecated": false
}
}
},
"webaudio": {
"__compat": {
"support": {
"firefox": {
"version_added": "50"
}
},
"status": {
"experimental": false,
"standard_track": true,
"deprecated": false
}
}
},
"webrtc": {
"__compat": {
"support": {
"firefox": {
"version_added": "59"
}
},
"status": {
"experimental": false,
"standard_track": true,
"deprecated": false
}
}
}
},
This indicates that MP4 files work in HTML media elements in Firefox 48, in Web Audio in Firefox 50, and in WebRTC in 59. This could be added to other levels of the JSON hierarchy to indicate that specific component (or codec) capabilities were introduced later in one API than in others.
Option 2: Separate BCD files for each API
The second option is to make media
the top level of a set of directories that cover the various media APIs’ support for media capabilities:
media/
: Contains a folder for each API, such as…media/html
: Contains JSON files covering compatibility of containers and codecs in HTML elementsmedia/html/mp4.json
(etc)
media/webaudio
: JSON files covering containers and codecs that work in Web Audiomedia/webrtc
: Same for WebRTC