st->codec->codec_id = old_codec_id;
st->codec->codec_type = old_codec_type;
}
+ if ((st->codec->codec_id == AV_CODEC_ID_NONE ||
+ (st->request_probe > 0 && st->request_probe < AVPROBE_SCORE_STREAM_RETRY / 5)) &&
+ !avcodec_is_open(st->codec) &&
+ stream_type == STREAM_TYPE_PRIVATE_DATA) {
+ st->codec->codec_type = AVMEDIA_TYPE_DATA;
+ st->codec->codec_id = AV_CODEC_ID_BIN_DATA;
+ st->request_probe = AVPROBE_SCORE_STREAM_RETRY / 5;
+ }
return 0;
}
case 0x05: /* registration descriptor */
st->codec->codec_tag = bytestream_get_le32(pp);
av_log(fc, AV_LOG_TRACE, "reg_desc=%.4s\n", (char *)&st->codec->codec_tag);
- if (st->codec->codec_id == AV_CODEC_ID_NONE)
+ if (st->codec->codec_id == AV_CODEC_ID_NONE || st->request_probe > 0)
mpegts_find_stream_type(st, st->codec->codec_tag, REGD_types);
break;
case 0x52: /* stream identifier descriptor */