diff --git a/trunk/src/app/srs_app_rtp.cpp b/trunk/src/app/srs_app_rtp.cpp index 0101e30c52..58d5942489 100644 --- a/trunk/src/app/srs_app_rtp.cpp +++ b/trunk/src/app/srs_app_rtp.cpp @@ -77,6 +77,7 @@ srs_error_t SrsRtpMuxer::frame_to_packet(SrsSharedPtrMessage* shared_frame, SrsF uint8_t header = sample.bytes[0]; uint8_t nal_type = header & kNalTypeMask; + // TODO: FIXME: Magic number? Doc? // ignore SEI nal if (nal_type == 0x06 || nal_type == 0x09) { continue; @@ -253,6 +254,7 @@ void SrsRtp::dispose() } } +// TODO: FIXME: Dead code? srs_error_t SrsRtp::cycle() { srs_error_t err = srs_success; @@ -338,7 +340,8 @@ srs_error_t SrsRtp::on_audio(SrsSharedPtrMessage* shared_audio, SrsFormat* forma srs_error_t SrsRtp::on_video(SrsSharedPtrMessage* shared_video, SrsFormat* format) { srs_error_t err = srs_success; - + + // TODO: FIXME: Maybe it should config on vhost level. if (!enabled) { return err; } diff --git a/trunk/src/app/srs_app_source.cpp b/trunk/src/app/srs_app_source.cpp index 3c3c07c67d..2ef7824a1a 100755 --- a/trunk/src/app/srs_app_source.cpp +++ b/trunk/src/app/srs_app_source.cpp @@ -1122,15 +1122,20 @@ srs_error_t SrsOriginHub::on_video(SrsSharedPtrMessage* shared_video, bool is_se return err; } + // Parse RTMP message to RTP packets, in FU-A if too large. if ((err = rtp->on_video(msg, format)) != srs_success) { + // TODO: We should support more strategies. srs_warn("rtp: ignore video error %s", srs_error_desc(err).c_str()); srs_error_reset(err); rtp->on_unpublish(); } + // TODO: FIXME: Refactor to move to rtp? + // Save the RTP packets for find_rtp_packet() to rtx or restore it. source->rtp_queue->push(msg->rtp_packets); if ((err = hls->on_video(msg, format)) != srs_success) { + // TODO: We should support more strategies. // apply the error strategy for hls. // @see https://github.com/ossrs/srs/issues/264 std::string hls_error_strategy = _srs_config->get_hls_on_error(req->vhost);