|
|
@ -621,6 +621,12 @@ static ChannelElement *get_che(AACContext *ac, int type, int elem_id) |
|
|
|
* If we seem to have encountered such a stream, transfer |
|
|
|
* If we seem to have encountered such a stream, transfer |
|
|
|
* the LFE[0] element to the SCE[1]'s mapping */ |
|
|
|
* the LFE[0] element to the SCE[1]'s mapping */ |
|
|
|
if (ac->tags_mapped == tags_per_config[ac->oc[1].m4ac.chan_config] - 1 && (type == TYPE_LFE || type == TYPE_SCE)) { |
|
|
|
if (ac->tags_mapped == tags_per_config[ac->oc[1].m4ac.chan_config] - 1 && (type == TYPE_LFE || type == TYPE_SCE)) { |
|
|
|
|
|
|
|
if (!ac->warned_remapping_once && (type != TYPE_LFE || elem_id != 0)) { |
|
|
|
|
|
|
|
av_log(ac->avctx, AV_LOG_WARNING, |
|
|
|
|
|
|
|
"This stream seems to incorrectly report its last channel as %s[%d], mapping to LFE[0]\n", |
|
|
|
|
|
|
|
type == TYPE_SCE ? "SCE" : "LFE", elem_id); |
|
|
|
|
|
|
|
ac->warned_remapping_once++; |
|
|
|
|
|
|
|
} |
|
|
|
ac->tags_mapped++; |
|
|
|
ac->tags_mapped++; |
|
|
|
return ac->tag_che_map[type][elem_id] = ac->che[TYPE_LFE][0]; |
|
|
|
return ac->tag_che_map[type][elem_id] = ac->che[TYPE_LFE][0]; |
|
|
|
} |
|
|
|
} |
|
|
@ -637,6 +643,12 @@ static ChannelElement *get_che(AACContext *ac, int type, int elem_id) |
|
|
|
* If we seem to have encountered such a stream, transfer |
|
|
|
* If we seem to have encountered such a stream, transfer |
|
|
|
* the SCE[1] element to the LFE[0]'s mapping */ |
|
|
|
* the SCE[1] element to the LFE[0]'s mapping */ |
|
|
|
if (ac->tags_mapped == tags_per_config[ac->oc[1].m4ac.chan_config] - 1 && (type == TYPE_LFE || type == TYPE_SCE)) { |
|
|
|
if (ac->tags_mapped == tags_per_config[ac->oc[1].m4ac.chan_config] - 1 && (type == TYPE_LFE || type == TYPE_SCE)) { |
|
|
|
|
|
|
|
if (!ac->warned_remapping_once && (type != TYPE_SCE || elem_id != 1)) { |
|
|
|
|
|
|
|
av_log(ac->avctx, AV_LOG_WARNING, |
|
|
|
|
|
|
|
"This stream seems to incorrectly report its last channel as %s[%d], mapping to SCE[1]\n", |
|
|
|
|
|
|
|
type == TYPE_SCE ? "SCE" : "LFE", elem_id); |
|
|
|
|
|
|
|
ac->warned_remapping_once++; |
|
|
|
|
|
|
|
} |
|
|
|
ac->tags_mapped++; |
|
|
|
ac->tags_mapped++; |
|
|
|
return ac->tag_che_map[type][elem_id] = ac->che[TYPE_SCE][1]; |
|
|
|
return ac->tag_che_map[type][elem_id] = ac->che[TYPE_SCE][1]; |
|
|
|
} |
|
|
|
} |
|
|
|