Commit fe9f5759 authored by Carl Eugen Hoyos's avatar Carl Eugen Hoyos

Warn if s16be is muxed into flv.

Players that conform to the specification can only playback such
files correctly on big-endian hardware.
parent cb36e441
...@@ -233,6 +233,9 @@ static int flv_write_header(AVFormatContext *s) ...@@ -233,6 +233,9 @@ static int flv_write_header(AVFormatContext *s)
audio_enc = enc; audio_enc = enc;
if (get_audio_flags(s, enc) < 0) if (get_audio_flags(s, enc) < 0)
return AVERROR_INVALIDDATA; return AVERROR_INVALIDDATA;
if (enc->codec_id == AV_CODEC_ID_PCM_S16BE)
av_log(s, AV_LOG_WARNING,
"16-bit big-endian audio in flv is valid but most likely unplayable (hardware dependent); use s16le\n");
break; break;
case AVMEDIA_TYPE_DATA: case AVMEDIA_TYPE_DATA:
if (enc->codec_id != AV_CODEC_ID_TEXT) { if (enc->codec_id != AV_CODEC_ID_TEXT) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment