RTP/RTSP Disconnect on IP camera

GeoD gdrht at xmlink.net
Mon May 9 17:41:43 PDT 2011


Trying to play the RTP/RTSP h264 video stream from an IP camera.

VLC works but gstreamer does not. I have narrowed it down to the camera seems
to be misrepresenting its capabilities and VLC continues while
gstreamer errors out
and resets the tcp connection when the second SETUP fails.

How do I tell gstreamer to ignore the camera response and only play
the video stream?

~GeoD


Packet Captures

VLC: http://www.xmlink.net/xfer/vlccap1.txt
GST: http://www.xmlink.net/xfer/gstcap1.txt


Debug log - VLC:

main debug: adding item `rtsp://10.0.2.101/h264' ( rtsp://10.0.2.101/h264 )
qt4 debug: Adding a new MRL to recent ones: rtsp://10.0.2.101/h264
main debug: rebuilding array of current - root Playlist
main debug: rebuild done - 1 items, index -1
main debug: processing request item rtsp://10.0.2.101/h264 node null skip 0
main debug: resyncing on rtsp://10.0.2.101/h264
main debug: rtsp://10.0.2.101/h264 is at 0
main debug: starting new item
main debug: creating new input thread
main debug: Creating an input for 'rtsp://10.0.2.101/h264'
main debug: thread (input) created at priority 10 (input/input.c:220)
main debug: thread started
main debug: using timeshift granularity of 50 MiB
main debug: using timeshift path '/tmp'
main debug: `rtsp://10.0.2.101/h264' gives access `rtsp' demux `' path
`10.0.2.101/h264'
main debug: creating demux: access='rtsp' demux='' path='10.0.2.101/h264'
main debug: looking for access_demux module: 1 candidate
qt4 debug: IM: Setting an input
live555 debug: RTP subsession 'video/H264'
main debug: selecting program id=0
live555 debug: RTP subsession 'audio/G726-16'
live555 error: SETUP of'audio/G726-16' failed no response code in
line: "x-Transport-Options: late-tolerance=1.400000"
live555 debug: setup start: 0.000000 stop:0.000000
live555 debug: We have a timeout of 60 seconds
live555 debug: spawned timeout thread
live555 debug: play start: 0.000000 stop:0.000000


Debug log - GST:

~/dvl$ gst-launch -v playbin2 uri=rtsp://10.0.2.101/h264
Setting pipeline to PAUSED ...
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0: connection-speed = 0
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0: download = FALSE
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0: uri =
"rtsp://10.0.2.101/h264"
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0: use-buffering = FALSE
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0: buffer-duration = -1
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0: buffer-size = -1
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0: source =
(GstRTSPSrc) source
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source/GstRtpBin:rtpbin0:
latency = 2000
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source/GstUDPSrc:udpsrc1:
timeout = 5000000

(gst-launch-0.10:2980): GStreamer-WARNING **: Element udpsrc4 is not
in bin source

(gst-launch-0.10:2980): GStreamer-WARNING **: Element udpsrc5 is not
in bin source
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source:
Could not read from resource.
Additional debug info:
gstrtspsrc.c(3847): gst_rtspsrc_try_send ():
/GstPlayBin2:playbin20/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source:
Could not receive message. (Parse error)
Setting pipeline to NULL ...
Freeing pipeline ...
~/dvl$



Camera response to DESCRIBE

Real Time Streaming Protocol
    Response: RTSP/1.0 200 OK\r\n
        Status: 200
    CSeq: 2\r\n
    Date: Wed, May 04 2011 19:24:52 GMT\r\n
    Content-Base: rtsp://10.0.1.101/h264/\r\n
    Content-type: application/sdp
    Content-length: 613
    x-Accept-Dynamic-Rate: 1\r\n
    \r\n
    Session Description Protocol
        Session Description Protocol Version (v): 0
        Owner/Creator, Session Id (o): - 1304535609930569 1 IN IP4 0.0.0.0
            Owner Username: -
            Session ID: 1304535609930569
            Session Version: 1
            Owner Network Type: IN
            Owner Address Type: IP4
            Owner Address: 0.0.0.0
        Session Name (s): Session streamed by "nessyMediaServer"
        Session Information (i): h264
        Time Description, active time (t): 0 0
            Session Start Time: 0
            Session Stop Time: 0
        Session Attribute (a): tool:LIVE555 Streaming Media
v2010.04.09_dyna_modi_2010.05.05
            Session Attribute Fieldname: tool
            Session Attribute Value: LIVE555 Streaming Media
v2010.04.09_dyna_modi_2010.05.05
        Session Attribute (a): type:broadcast
            Session Attribute Fieldname: type
            Session Attribute Value: broadcast
        Session Attribute (a): control:*
            Session Attribute Fieldname: control
            Session Attribute Value: *
        Session Attribute (a): range:npt=0-
            Session Attribute Fieldname: range
            Session Attribute Value: npt=0-
        Session Attribute (a): x-qt-text-nam:Session streamed by
"nessyMediaServer"
            Session Attribute Fieldname: x-qt-text-nam
            Session Attribute Value: Session streamed by "nessyMediaServer"
        Session Attribute (a): x-qt-text-inf:h264
            Session Attribute Fieldname: x-qt-text-inf
            Session Attribute Value: h264
        Media Description, name and address (m): video 0 RTP/AVP 99
            Media Type: video
            Media Port: 0
            Media Protocol: RTP/AVP
            Media Format: DynamicRTP-Type-99
        Connection Information (c): IN IP4 0.0.0.0
            Connection Network Type: IN
            Connection Address Type: IP4
            Connection Address: 0.0.0.0
        Media Attribute (a): rtpmap:99 H264/90000
            Media Attribute Fieldname: rtpmap
            Media Format: 99
            MIME Type: H264
            Sample Rate: 90000
        Media Attribute (a): fmtp:99
packetization-mode=28;profile-level-id=42E020.;
sprop-parameter-sets=J0LgII1oC0PbAWyAAAH0gAAdTAec9Q==,KM4NyA==
            Media Attribute Fieldname: fmtp
            Media Format: 99 [H264]
            Media format specific parameters: packetization-mode=28
                [Packetization mode: Unknown (28)]
            Media format specific parameters: profile-level-id=42E020.
                Profile: 42E020
                    0100 0010 = Profile_idc: Baseline profile (66)
                    1... .... = Constraint_set0_flag: 1
                    .1.. .... = Constraint_set1_flag: 1
                    ..1. .... = Constraint_set2_flag: 1
                    ...0 .... = Constraint_set3_flag: 0
                    .... 0000 = Reserved_zero_4bits: 0
                    0010 0000 = Level_id: 32 [Level 3.2 20 Mb/s]
            Media format specific parameters:
sprop-parameter-sets=J0LgII1oC0PbAWyAAAH0gAAdTAec9Q==,KM4NyA==
                NAL unit 1 string: J0LgII1oC0PbAWyAAAH0gAAdTAec9Q==
                NAL unit: 2742E0208D680B43DB016C800001F480001D4C079CF5
                    0... .... = Forbidden_zero_bit: 0
                    .01. .... = Nal_ref_idc: 1
                    ...0 0111 = Nal_unit_type: Sequence parameter set (7)
                    0100 0010 = Profile_idc: Baseline profile (66)
                    1... .... = Constraint_set0_flag: 1
                    .1.. .... = Constraint_set1_flag: 1
                    ..1. .... = Constraint_set2_flag: 1
                    ...0 .... = Constraint_set3_flag: 0
                    .... 0000 = Reserved_zero_4bits: 0
                    0010 0000 = Level_id: 32 [Level 3.2 20 Mb/s]
                    1... .... = seq_parameter_set_id: 0
                    .000 1101 = log2_max_frame_num_minus4: 12
                    011. .... = pic_order_cnt_type: 2
                    ...0 10.. = num_ref_frames: 1
                    .... ..0. = gaps_in_frame_num_value_allowed_flag: 0
                    .... ...0  0000 1011  01.. .... =
pic_width_in_mbs_minus1: 44
                    ..00 0011  110. .... = pic_height_in_map_units_minus1: 29
                    ...1 .... = frame_mbs_only_flag: 1
                    .... 1... = direct_8x8_inference_flag: 1
                    .... .0.. = frame_cropping_flag: 0
                    .... ..1. = vui_parameters_present_flag: 1
                    .... ...1 = aspect_ratio_info_present_flag: 1
                    0000 0001 = aspect_ratio_idc: 1
                    0... .... = overscan_info_present_flag: 0
                    .1.. .... = video_signal_type_present_flag: 1
                    ..10 1... = video_format: 5
                    .... .1.. = video_full_range_flag: 1
                    .... ..0. = colour_description_present_flag: 0
                    .... ...0 = chroma_loc_info_present_flag: 0
                    1... .... = timing_info_present_flag: 1
                    .000 0000  0000 0000  0000 0001  1111 0100  1...
.... = num_units_in_tick: 1001
                    .000 0000  0000 0000  0001 1101  0100 1100  0...
.... = time_scale: 15000
                    .0.. .... = fixed_frame_rate_flag: 0
                    ..0. .... = nal_hrd_parameters_present_flag: 0
                    ...0 .... = vcl_hrd_parameters_present_flag: 0
                    .... 0... = pic_struct_present_flag: 0
                    .... .1.. = bitstream_restriction_flag: 1
                    .... ..1. = motion_vectors_over_pic_boundaries_flag: 1
                    .... ...1 = max_bytes_per_pic_denom: 0
                    1... .... = max_bits_per_mb_denom: 0
                    .001 11.. = max_mv_length_horizontal: 6
                    .... ..00  111. .... = log2_max_mv_length_vertical: 6
                    ...1 .... = num_reorder_frames: 0
                    .... 010. = max_dec_frame_buffering: 1
                    .... ...1 = rbsp_stop_bit: 1
                NAL unit 2 string: KM4NyA==
                NAL unit: 28CE0DC8
                    0... .... = Forbidden_zero_bit: 0
                    .01. .... = Nal_ref_idc: 1
                    ...0 1000 = Nal_unit_type: Picture parameter set (8)
                    1... .... = pic_parameter_set_id: 0
                    .1.. .... = seq_parameter_set_id: 0
                    ..0. .... = entropy_coding_mode_flag: 0
                    ...0 .... = pic_order_present_flag: 0
                    .... 1... = num_slice_groups_minus1: 0
                    .... .1.. = num_ref_idx_l0_active_minus1: 0
                    .... ..1. = num_ref_idx_l1_active_minus1: 0
                    .... ...0 = weighted_pred_flag: 0
                    00.. .... = weighted_bipred_idc: 0
                    ..00 110. = pic_init_qp_minus26(se(v)): 3
                    .... ...1 = pic_init_qs_minus26: 0
                    1... .... = chroma_qp_index_offset: 0
                    .1.. .... = deblocking_filter_control_present_flag: 1
                    ..0. .... = constrained_intra_pred_flag: 0
                    ...0 .... = redundant_pic_cnt_present_flag: 0
                    .... 1... = rbsp_stop_bit: 1
                    .... .000 = rbsp_trailing_bits: 0
        Media Attribute (a): control:track1
            Media Attribute Fieldname: control
            Media Attribute Value: track1
        Media Attribute (a): cliprect:0,0,720,480
            Media Attribute Fieldname: cliprect
            Media Attribute Value: 0,0,720,480
        Media Attribute (a): framerate:14.990000
            Media Attribute Fieldname: framerate
            Media Attribute Value: 14.990000
        Media Description, name and address (m): audio 7878 RTP/AVP 98
            Media Type: audio
            Media Port: 7878
            Media Protocol: RTP/AVP
            Media Format: DynamicRTP-Type-98
        Media Attribute (a): rtpmap:98 G726-16/8000/1
            Media Attribute Fieldname: rtpmap
            Media Format: 98
            MIME Type: G726-16
            Sample Rate: 8000/1
        Media Attribute (a): control:track2
            Media Attribute Fieldname: control
            Media Attribute Value: track2


More information about the gstreamer-devel mailing list