source type codecs Parameter Lookup

Builds a source MIME type with a quoted codecs parameter from a restricted codec-identifier profile (ASCII letters, digits, dot, underscore and hyphen). It does not identify or guarantee browser codec support.

Description

A media type may include a codecs parameter identifying encoded formats more precisely.

A media type may include a codecs parameter identifying encoded formats more precisely. Correct quoting and HTML attribute escaping are separate formatting steps.1

The tool returns typeValue, attribute. The fields describe the supplied local pattern or effective state, or contain the formatted markup shown below.

When to use source type codecs Parameter Lookup

Use this for the following task: Builds a source MIME type with a quoted codecs parameter from a restricted codec-identifier profile (ASCII letters, digits, dot, underscore and hyphen). It does not identify or guarantee browser codec support. Provide the requested local fields extracted from the relevant element or attribute.

How to use source type codecs Parameter Lookup and understand its results

  1. Prepare the parsed element names, attribute values or direct element-child lists requested below. Keep attribute presence separate from its value.
  2. Enter mediaType, codecs according to the field table, then run the tool.
  3. Read typeValue, attribute. Check the effective state, recognized-token flags or generated markup against the rules below.
  4. Correct any reported local mismatch and check the resulting markup in its intended document and browser context.
Input fieldMeaningValue type and boundsRequirement
mediaTypeMedia Typestring; maximum text length 200Required
codecsCodecslist of string; minimum entries 1; maximum entries 100; each entry: maximum text length 200Required

Enter a MIME type without parameters and 1..100 codec identifiers. Require supported ASCII token syntax, join codecs with commas inside quotes and escape the complete type value for a double-quoted attribute.

typeValue=lowercase MIME type + ; codecs="comma-joined codec identifiers"

The symbols and boundary conditions refer to the supplied fields and the implementation described above.

Output fieldMeaningValue type
typeValueType Valuestring
attributeAttributestring
json
{
  "input": {
    "mediaType": "video/mp4",
    "codecs": [
      "avc1.42E01E",
      "mp4a.40.2"
    ]
  },
  "output": {
    "typeValue": "video/mp4; codecs=\"avc1.42E01E,mp4a.40.2\"",
    "attribute": "type=\"video/mp4; codecs="avc1.42E01E,mp4a.40.2"\""
  }
}

Limitations and assumptions

Codec identifiers use the restricted letters/digits/dot/underscore/hyphen profile. The tool does not inspect media bytes or guarantee decoding support.

The tool does not fetch a page, run a browser or validate an entire HTML document. Malformed tool requests produce input errors; valid requests can still report unrecognized values or failed local checks.

Alternative or Complementary methods

Choose track kind subtitles/captions/chapters when you need its operation: Resolves track kind with subtitles as missing default and metadata as invalid default. Empty present values are invalid. This does not validate track language or WebVTT content. Choose audio preload metadata/none/auto Values for the complementary operation: Resolves audio preload hints none, metadata or auto, with empty present value mapping to auto. Both omitted and invalid attributes are implementation-defined; this does not predict network buffering.

Background reference: The Codecs and Profiles Parameters for Bucket Media Types.

References

  1. The Codecs and Profiles Parameters for Bucket Media Types — Internet Engineering Task Force, RFC 6381

Similar or alternative tools

  • track kind subtitles/captions/chapters

    Resolves track kind with subtitles as missing default and metadata as invalid default. Empty present values are invalid. This does not validate track language or WebVTT content.

  • audio preload metadata/none/auto Values

    Resolves audio preload hints none, metadata or auto, with empty present value mapping to auto. Both omitted and invalid attributes are implementation-defined; this does not predict network buffering.

Don't forget to set a bookmark for tool.io!
Privacy | Imprint | Cookies