# This example uses an Adaptation Set selection criteria that is based not just
# on the value of a direct Adaptation Set attribute, but can also be based on
# those of its Representations.
# The "codecs" attribute in fact can be present at Adaptation Set level, but
# can also be absent: in that case, it is present at Representation level.
#
# For this reason, the applied selection logic is the following:
# - First, try to match the codecs attribute at Adaptation Set level
# - If the field is present and matches, the AdSet is selected
# - If the field is present and doesn't match, the AdSet is not selected
# - If the field is not present, then check each Representation:
#   - If the field is present in every Representation and the regular expression
#     matches all the values, then the AdSet is selected
#   - In all other cases, the AdSet is not selected
mpd:
- manifest_edit.plugins.mpd.adaptation_sets_switching:
    periods:
      - '*' : '.*'
        adaptationSets:
          - codecs: 'avc1.*'
            plugin_config:
              switching_set: '1'
              destination: 'essential_property'
          - codecs: 'hev1.1.6.*'
            plugin_config:
              switching_set: '2'
              destination: 'essential_property'
          - codecs: 'hev1.2.4.*'
            plugin_config:
              switching_set: '3'
              destination: 'essential_property'
          - codecs: 'dvhe.05.*'
            plugin_config:
              switching_set: '4'
              destination: 'essential_property'

- manifest_edit.plugins.mpd.descriptor_add:

