From: Marton Balint <cus@passwd.hu> To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> Subject: Re: [FFmpeg-devel] [PATCH v3 2/2] avformat/rtmpproto: support enhanced rtmp Date: Sat, 26 Aug 2023 11:25:35 +0200 (CEST) Message-ID: <c8ac4254-d6b0-3e4-d3e9-d883ea4f1890@passwd.hu> (raw) In-Reply-To: <CADxeRw=hVDtsK_zCxzWEGZMNOA5T8p1-+e9928R1jhETo7U8Hw@mail.gmail.com> On Sat, 26 Aug 2023, Steven Liu wrote: > Marton Balint <cus@passwd.hu> 于2023年8月26日周六 15:52写道: > Hi Marton, [...] >> > >> >> + av_strlcpy(fourcc, fourcc_data, sizeof(fourcc)); >> >> + ff_amf_write_string(&p, fourcc); >> >> + } else { >> >> + av_log(s, AV_LOG_ERROR, "Unsupported codec fourcc, %.*s\n", 4, fourcc_data); >> >> + return AVERROR_PATCHWELCOME; >> >> As far as I saw the specs does not provide an explicit list of fourcc >> that can be used, so we should not limit it either, it makes the code more >> future-proof. Therefore I suggest we accept unknown fourccs, but warn the >> user about them. > I set unsupported codec fourcc, and return a patchwelcome is because > there just add hevc,av1,vp9 codec supported in flvenc and flvdec, > dose not add the others in the flv right, so if user want use another > codecs, it should give a error and patch welcome. Ok, but if you only want to support a strict list, then maybe AV_OPT_TYPE_FLAGS type would be a better option type? Fine with me either way. >> >> >> + } >> >> + >> >> + fourcc_data += 5; >> >> + } >> >> + } >> >> + >> >> if (!rt->is_input) { >> >> ff_amf_write_field_name(&p, "type"); >> >> ff_amf_write_string(&p, "nonprivate"); >> >> @@ -3104,6 +3140,7 @@ static const AVOption rtmp_options[] = { >> >> {"rtmp_conn", "Append arbitrary AMF data to the Connect message", OFFSET(conn), AV_OPT_TYPE_STRING, {.str = NULL }, 0, 0, DEC|ENC}, >> >> {"rtmp_flashver", "Version of the Flash plugin used to run the SWF player.", OFFSET(flashver), AV_OPT_TYPE_STRING, {.str = NULL }, 0, 0, DEC|ENC}, >> >> {"rtmp_flush_interval", "Number of packets flushed in the same request (RTMPT only).", OFFSET(flush_interval), AV_OPT_TYPE_INT, {.i64 = 10}, 0, INT_MAX, ENC}, >> >> + {"rtmp_enhanced_codecs", "Specify the codec(s) to use in an enhanced rtmp live stream", OFFSET(enhanced_codecs), AV_OPT_TYPE_STRING, {.str = NULL }, 0, 0, ENC}, >> >> Maybe make the default "av01,vp09,hevc"? This is a list of codecs the > I think make it null should better, because not should every body's > ffmpeg has been support hevc/av1/vp9 codec, And not everybody is using libavcodec for decoding hevc/av1/vp9, so which decoders are compiled in does not really matter. Do we really want the default to *not support* any recent codec? > so I set it null default, and the other reason is not sure all rtmp > server has beed support enhanced rtmp, so make it null default > when user not use codec hevc/av1/vp9. I'd expect that legacy rtmp servers will just ignore "fourCcList" property as an unknown/unsupported property, but I am not sure what would actually happen... Maybe some tests should be made with the most common implementations. If it actually causes issues, then I am fine with the NULL default. Regards, Marton _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
next prev parent reply other threads:[~2023-08-26 9:28 UTC|newest] Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top 2023-08-24 5:32 [FFmpeg-devel] [PATCH v1 1/2] avformat/rtmppkt: add ff_amf_write_array for write array strings Steven Liu 2023-08-24 5:32 ` [FFmpeg-devel] [PATCH v1 2/2] avformat/rtmpproto: support enhanced rtmp Steven Liu 2023-08-24 20:10 ` Tristan Matthews 2023-08-24 21:45 ` Marton Balint 2023-08-25 5:30 ` [FFmpeg-devel] [PATCH v2 1/2] avformat/rtmppkt: add ff_amf_write_array for write array strings Steven Liu 2023-08-25 5:30 ` [FFmpeg-devel] [PATCH v2 2/2] avformat/rtmpproto: support enhanced rtmp Steven Liu 2023-08-25 9:04 ` Martin Storsjö 2023-08-25 9:11 ` Steven Liu 2023-08-25 9:38 ` Martin Storsjö 2023-08-25 10:00 ` Steven Liu 2023-08-25 10:06 ` Martin Storsjö 2023-08-25 10:05 ` [FFmpeg-devel] [PATCH v3 1/2] avformat/rtmppkt: add ff_amf_write_array for write Steven Liu 2023-08-25 10:05 ` [FFmpeg-devel] [PATCH v3 2/2] avformat/rtmpproto: support enhanced rtmp Steven Liu 2023-08-25 10:09 ` Steven Liu 2023-08-26 7:49 ` Marton Balint 2023-08-26 8:28 ` Steven Liu 2023-08-26 9:25 ` Marton Balint [this message] 2023-08-28 2:00 ` [FFmpeg-devel] [PATCH v4 1/2] avformat/rtmppkt: add ff_amf_write_array for write Steven Liu 2023-08-28 2:00 ` [FFmpeg-devel] [PATCH v4 2/2] avformat/rtmpproto: support enhanced rtmp Steven Liu 2023-08-28 19:33 ` Marton Balint 2023-08-29 1:06 ` Steven Liu 2023-08-25 5:33 ` [FFmpeg-devel] [PATCH v1 " Steven Liu 2023-08-25 5:32 ` Steven Liu 2023-08-24 20:47 ` [FFmpeg-devel] [PATCH v1 1/2] avformat/rtmppkt: add ff_amf_write_array for write array strings Marton Balint
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=c8ac4254-d6b0-3e4-d3e9-d883ea4f1890@passwd.hu \ --to=cus@passwd.hu \ --cc=ffmpeg-devel@ffmpeg.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git