s->oformat->name);
return AVERROR(EINVAL);
}
+ if ( s->oformat->audio_codec != AV_CODEC_ID_NONE
+ && s->streams[0]->codecpar->codec_type != AVMEDIA_TYPE_AUDIO) {
+ av_log(s, AV_LOG_ERROR, "%s files have exactly one audio stream\n",
+ s->oformat->name);
+ return AVERROR(EINVAL);
+ }
+ if ( s->oformat->video_codec != AV_CODEC_ID_NONE
+ && s->streams[0]->codecpar->codec_type != AVMEDIA_TYPE_VIDEO) {
+ av_log(s, AV_LOG_ERROR, "%s files have exactly one video stream\n",
+ s->oformat->name);
+ return AVERROR(EINVAL);
+ }
return 0;
}
};
#endif
+#if CONFIG_AVS2_MUXER
+AVOutputFormat ff_avs2_muxer = {
+ .name = "avs2",
+ .long_name = NULL_IF_CONFIG_SMALL("raw AVS2-P2/IEEE1857.4 video"),
+ .extensions = "avs,avs2",
+ .audio_codec = AV_CODEC_ID_NONE,
+ .video_codec = AV_CODEC_ID_AVS2,
+ .write_header = force_one_stream,
+ .write_packet = ff_raw_write_packet,
+ .flags = AVFMT_NOTIMESTAMPS,
+};
+#endif
+
#if CONFIG_CAVSVIDEO_MUXER
AVOutputFormat ff_cavsvideo_muxer = {
.name = "cavsvideo",