bilibili / ijkplayer

Android/iOS video player based on FFmpeg n3.4, with MediaCodec, VideoToolbox support.
GNU General Public License v2.0
32.54k stars 8.13k forks source link

Buffer issue #1857

Open leon790 opened 8 years ago

leon790 commented 8 years ago

Hi i have this log, my app close when this apear, can some one suppor me please?

av_version_info: ff3.0--ijk0.5.0--dev0.4.5--rc11
ijkmp_set_inject_opaque(0x15339e0f0)
ijkmp_set_inject_opaque()=void
2016-08-18 13:35:56.532 a2eApp[298:14843] OK setup GL
ijkmp_ios_set_view(glView=0x15339fb00)
ijkmp_ios_set_view(glView=0x15339fb00)=void
2016-08-18 13:35:56.536 a2eApp[298:14843] invalidateRenderBuffer
2016-08-18 13:35:56.538 a2eApp[298:15712] IJKSDLGLView: setupDisplay not ready
ijkmp_set_data_source(url="rtsp://172.24.1.1:8554/unicast")
ijkmp_set_data_source(url="rtsp://172.24.1.1:8554/unicast")=0
ijkmp_prepare_async()
[FFPlayer @ 0x153377580] remove 'timeout' option for rtmp.
===== versions =====
[FFPlayer @ 0x153377580] FFmpeg       : ff3.0--ijk0.5.0--dev0.4.5--rc11
[FFPlayer @ 0x153377580] libavutil    : 55.17.103
[FFPlayer @ 0x153377580] libavcodec   : 57.24.102
[FFPlayer @ 0x153377580] libavformat  : 57.25.100
[FFPlayer @ 0x153377580] libswscale   : 4.0.100
[FFPlayer @ 0x153377580] libswresample: 2.0.101
===== options =====
[FFPlayer @ 0x153377580] player-opts : video-pictq-size             = 3
[FFPlayer @ 0x153377580] player-opts : overlay-format               = fcc-_es2
[FFPlayer @ 0x153377580] player-opts : max-fps                      = 30
[FFPlayer @ 0x153377580] player-opts : framedrop                    = 0
[FFPlayer @ 0x153377580] player-opts : videotoolbox-max-frame-width = 960
[FFPlayer @ 0x153377580] player-opts : videotoolbox                 = 0
[FFPlayer @ 0x153377580] player-opts : start-on-prepared            = 1
[FFPlayer @ 0x153377580] format-opts : ijkinject-opaque             = 5691269360
[FFPlayer @ 0x153377580] format-opts : ijkapplication               = 5691270176
[FFPlayer @ 0x153377580] format-opts : user-agent                   = ijkplayer
[FFPlayer @ 0x153377580] format-opts : auto_convert                 = 0
[FFPlayer @ 0x153377580] format-opts : safe                         = 0
[FFPlayer @ 0x153377580] format-opts : reconnect                    = 1
===================
ijkmp_prepare_async()=0
[FFPlayer @ 0x153377580] remove 'timeout' option for rtmp.
[tcp @ 0x1532a0a40] No default whitelist set
2016-08-18 13:35:56.542 a2eApp[298:14843] invalidateRenderBuffer
2016-08-18 13:35:56.543 a2eApp[298:15712] IJKSDLGLView: setupDisplay not ready
[rtsp @ 0x15012fa00] SDP:
v=0

o=- 1471540191908560 1 IN IP4 192.168.1.121

s=LIVE555 Streaming Media v2012.05.17

i=LIVE555 Streaming Media v2012.05.17

t=0 0

a=tool:LIVE555 Streaming Media v2012.05.17

a=type:broadcast

a=control:*

a=range:npt=0-

a=x-qt-text-nam:LIVE555 Streaming Media v2012.05.17

a=x-qt-text-inf:LIVE555 Streaming Media v2012.05.17

m=video 0 RTP/AVP 96

c=IN IP4 0.0.0.0

b=AS:0

a=rtpmap:96 H264/90000

a=fmtp:96 profile-level-id=640028;sprop-parameter-sets=J2QAKKwrQDwBE/LAPEiagA==,KO4CXLA=

a=control:track1

Failed to parse interval end specification ''
[rtsp @ 0x15012fa00] video codec set to: h264
[rtsp @ 0x15012fa00] RTP Profile IDC: 64 Profile IOP: 0 Level: 28
[rtsp @ 0x15012fa00] Extradata set to 0x153284500 (size: 29)
[rtp @ 0x1533b3fe0] No default whitelist set
[udp @ 0x1533b3bc0] No default whitelist set
[udp @ 0x1533b3bc0] end receive buffer size reported is 65536
[udp @ 0x153268bd0] No default whitelist set
[udp @ 0x153268bd0] end receive buffer size reported is 65536
[NULL @ 0x15012ea00] setting jitter buffer size to 500
[rtsp @ 0x15012fa00] hello state=0
Failed to parse interval end specification ''
Option ijkinject-opaque not found.
[h264 @ 0x15012ea00] Frame num gap 55 53
[rtsp @ 0x15012fa00] max delay reached. need to consume packet
[h264 @ 0x15012ea00] RTP: missed 13 packets
[rtsp @ 0x15012fa00] max delay reached. need to consume packet
[h264 @ 0x15012ea00] RTP: missed 2 packets
[h264 @ 0x15012ea00] left block unavailable for requested intra mode at 0 4
[h264 @ 0x15012ea00] error while decoding MB 0 4, bytestream 101624
[h264 @ 0x15012ea00] concealing 7729 DC, 7729 AC, 7729 MV errors in I frame
[rtsp @ 0x15012fa00] max delay reached. need to consume packet
[h264 @ 0x15012ea00] RTP: missed 12 packets
[h264 @ 0x15012ea00] bytestream overread -4
[h264 @ 0x15012ea00] bytestream overread -6
[h264 @ 0x15012ea00] error while decoding MB 12 25, bytestream -6
[h264 @ 0x15012ea00] concealing 5197 DC, 5197 AC, 5197 MV errors in P frame
[h264 @ 0x15012ea00] Frame num gap 4 2
[rtsp @ 0x15012fa00] max delay reached. need to consume packet
[h264 @ 0x15012ea00] RTP: missed 3 packets
[rtsp @ 0x15012fa00] max delay reached. need to consume packet
[h264 @ 0x15012ea00] RTP: missed 15 packets
[rtsp @ 0x15012fa00] max delay reached. need to consume packet
[h264 @ 0x15012ea00] RTP: missed 1 packets
[rtsp @ 0x15012fa00] All info found
[rtsp @ 0x15012fa00] rfps: 29.500000 0.017056
[rtsp @ 0x15012fa00] rfps: 29.583333 0.013669
[rtsp @ 0x15012fa00] rfps: 29.666667 0.010965
[rtsp @ 0x15012fa00] rfps: 29.750000 0.008943
[rtsp @ 0x15012fa00] rfps: 29.750000 0.008943
[rtsp @ 0x15012fa00] rfps: 29.833333 0.007605
[rtsp @ 0x15012fa00] rfps: 29.833333 0.007605
[rtsp @ 0x15012fa00] rfps: 29.916667 0.006951
[rtsp @ 0x15012fa00] rfps: 29.916667 0.006951
[rtsp @ 0x15012fa00] rfps: 30.000000 0.006979
[rtsp @ 0x15012fa00] rfps: 29.970030 0.006890
[FFPlayer @ 0x153377580] max_frame_duration: 10.000
Input #0, rtsp, from 'rtsp://172.24.1.1:8554/unicast':
  Metadata:
    title           : LIVE555 Streaming Media v2012.05.17
    comment         : LIVE555 Streaming Media v2012.05.17
  Duration: N/A, start: 0.026078, bitrate: N/A
    Stream #0:0, 33, 1/90000: Video: h264, 1 reference frame, yuv420p(left), 1920x1080 (1920x1088), 1/180000, 29.97 tbr, 90k tbn, 180k tbc
vtb fail!!! switch to ffmpeg decode!!!! 
[FFPlayer @ 0x153377580] VideoCodec: avcodec, h264
[FFPlayer @ 0x153377580] fps: 29.970030 (normal)
2016-08-18 13:35:57.581 a2eApp[298:14843] FFP_MSG_VIDEO_DECODER_OPEN: false
2016-08-18 13:35:57.582 a2eApp[298:14843] FFP_MSG_VIDEO_SIZE_CHANGED: 1920, 1080
2016-08-18 13:35:57.583 a2eApp[298:14843] FFP_MSG_SAR_CHANGED: 0, 1
ijkmp_get_msg: FFP_MSG_PREPARED
2016-08-18 13:35:57.583 a2eApp[298:14843] FFP_MSG_PREPARED:
ijkmp_get_meta_l
ijkmp_get_meta_l()=void
2016-08-18 13:35:57.584 a2eApp[298:14843] mediaIsPreparedToPlayDidChange
2016-08-18 13:35:57.584 a2eApp[298:14843] loadStateDidChange: IJKMPMovieLoadStatePlaythroughOK: 3
2016-08-18 13:35:57.585 a2eApp[298:14843] IJKMPMoviePlayBackStateDidChange 1: playing
[h264 @ 0x14f806800] Frame num gap 55 53
[h264 @ 0x14f879000] left block unavailable for requested intra mode at 0 4
[h264 @ 0x14f879000] error while decoding MB 0 4, bytestream 101624
[h264 @ 0x14f879000] concealing 7729 DC, 7729 AC, 7729 MV errors in I frame
[h264 @ 0x14f89ba00] bytestream overread -4
[h264 @ 0x14f89ba00] bytestream overread -4
[h264 @ 0x14f89ba00] bytestream overread -4
[h264 @ 0x14f89ba00] bytestream overread -4
[h264 @ 0x14f89ba00] bytestream overread -4
[h264 @ 0x14f89ba00] bytestream overread -4
[h264 @ 0x14f89ba00] bytestream overread -4
[h264 @ 0x14f89ba00] bytestream overread -6
[h264 @ 0x14f89ba00] error while decoding MB 9 25, bytestream -6
[h264 @ 0x14f89ba00] concealing 5200 DC, 5200 AC, 5200 MV errors in P frame
SDL_VoutFFmpeg_CreateOverlay(w=1920, h=1080, fmt=I420(0x30323449, dp=0x1533aa970)
Video: first frame decoded
2016-08-18 13:35:57.759 a2eApp[298:14843] FFP_MSG_VIDEO_SIZE_CHANGED: 1920, 1080
[GLES2] Version = OpenGL ES 2.0 Apple A8 GPU - 77.14
[GLES2] Vendor = Apple Inc.
[GLES2] Renderer = Apple A8 GPU
[GLES2] Extensions = GL_OES_depth_texture GL_OES_depth_texture_cube_map GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_texture_float GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_vertex_array_object GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_label GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_draw_instanced GL_EXT_instanced_arrays GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_pvrtc_sRGB GL_EXT_read_format_bgra GL_EXT_separate_shader_objects GL_EXT_shader_framebuffer_fetch GL_EXT_shader_texture_lod GL_EXT_shadow_samplers GL_EXT_sRGB GL_EXT_texture_filter_anisotropic GL_EXT_texture_rg GL_EXT_texture_storage GL_APPLE_clip_distance GL_APPLE_color_buffer_packed_float GL_APPLE_copy_texture_levels GL_APPLE_framebuffer_multisample GL_APPLE_rgb_422 GL_APPLE_sync GL_APPLE_texture_format_BGRA8888 GL_APPLE_texture_max_level GL_APPLE_texture_packed_float GL_IMG_read_format GL_IMG_texture_compression_pvrtc 
create render yuv420p
use render yuv420p
2016-08-18 13:35:57.767 a2eApp[298:15993] IJKSDLGLView: renderbufferStorage fromDrawable

Message from debugger: Terminated due to memory issue

spaul13 commented 6 years ago

@leon790 @xinzhengzhang , can you please tell me how can I possibly see when an I frame or P frame or a B frame is being decoded while decoding?

Android4MediaPlayer commented 6 years ago

@spaul13 https://github.com/Bilibili/ijkplayer/blob/master/ijkmedia/ijkplayer/ff_ffplay.c#L1558

spaul13 commented 6 years ago

Thanks a lot @Android4MediaPlayer .

But while compiling or building, we are in general using the ijkplayer/android/contrib (compile-ffmpeg.sh). If I change anything in ff_ffplay.c in ijkmedia or want to use ff_ffpipeline.c from ijkmedia/ijkplayer how it can be reflected in the compiled version? This I want to know in order to use the changed compiled ff_ffplay.c to have a different form of decoding.