Force hardware decoding
Posted: 02 Aug 2013 22:00
Hello,
I would like to force hardware decoding for an h264 stream.
Question #1: which hardware is currently supported for hardware decoding?
Question #2: I guess that the following log is software decoding. Correct?
Question #3: How can I force hardware decoding? Would it be correct to add libvlc_media_add_option(p_md, ":codec=iomx"); at the end of new_media in libvlcjni.c?
I would like to force hardware decoding for an h264 stream.
Question #1: which hardware is currently supported for hardware decoding?
Question #2: I guess that the following log is software decoding. Correct?
Code: Select all
D/VLC ( 9437): main input: Creating an input for 'rtsp://192.168.10.4:8554/stream'
D/VLC ( 9437): main stream output: using sout chain=`stream_out_duplicate{dst=display,dst=std{access=file,mux=ts,dst=/sdcard/MeCam/20130802_122921/video.mpg}}'
D/VLC ( 9437): main stream output: stream=`stream_out_duplicate'
D/VLC ( 9437): main stream out: looking for sout stream module matching "stream_out_duplicate": 20 candidates
D/audio_hw_primary( 180): adev_open_input_stream: enter
D/audio_hw_primary( 180): adev_open_input_stream: exit
D/VLC ( 9437): stream_out_duplicate stream out: creating 'duplicate'
D/VLC ( 9437): stream_out_duplicate stream out: * adding `display'
D/VLC ( 9437): main stream output: stream=`display'
D/VLC ( 9437): main stream out: looking for sout stream module matching "display": 20 candidates
D/VLC ( 9437): main stream out: using sout stream module "stream_out_display"
D/VLC ( 9437): stream_out_duplicate stream out: * adding `std{access=file,mux=ts,dst=/sdcard/MeCam/20130802_122921/video.mpg}'
D/VLC ( 9437): main stream output: stream=`std'
D/VLC ( 9437): main stream out: looking for sout stream module matching "std": 20 candidates
D/VLC ( 9437): main stream out: set config option: sout-standard-access to file
D/VLC ( 9437): main stream out: set config option: sout-standard-mux to ts
D/VLC ( 9437): main stream out: set config option: sout-standard-dst to /sdcard/MeCam/20130802_122921/video.mpg
D/VLC ( 9437): main access out: looking for sout access module matching "file": 7 candidates
D/VLC ( 9437): access_output_file access out: file access output opened (/sdcard/MeCam/20130802_122921/video.mpg)
D/VLC ( 9437): main access out: using sout access module "access_output_file"
D/VLC ( 9437): main mux: looking for sout mux module matching "ts": 10 candidates
D/VLC ( 9437): mux_ts mux: shaping=200000 pcr=70000 dts_delay=400000
D/VLC ( 9437): main mux: using sout mux module "mux_ts"
D/VLC ( 9437): main stream output: muxer support adding stream at any time
D/VLC ( 9437): stream_out_standard stream out: using `file/ts:///sdcard/MeCam/20130802_122921/video.mpg'
D/VLC ( 9437): main stream out: using sout stream module "stream_out_standard"
D/VLC ( 9437): main stream out: using sout stream module "stream_out_duplicate"
D/VLC ( 9437): main input: using timeshift granularity of 50 MiB, in path '/tmp'
D/audio_hw_primary( 180): in_standby: enter
D/audio_hw_primary( 180): in_standby: exit: status(0)
D/VLC ( 9437): main input: `rtsp://192.168.10.4:8554/stream' gives access `rtsp' demux `' path `192.168.10.4:8554/stream'
D/VLC ( 9437): main input: creating demux: access='rtsp' demux='' location='192.168.10.4:8554/stream' file='(null)'
D/VLC ( 9437): main demux: looking for access_demux module matching "rtsp": 4 candidates
D/VLC ( 9437): live555 demux: version 2012.12.18
D/audio_hw_primary( 180): in_set_parameters: enter: kvpairs=input_source=1;routing=-2147483644
D/audio_hw_primary( 180): in_set_parameters: exit: status(11)
D/audio_hw_primary( 180): start_input_stream: enter: usecase(3)
D/audio_hw_primary( 180): select_devices: out_snd_device(0: none) in_snd_device(15: handset-mic)
D/audio_hw_primary( 180): enable_snd_device: sending audio calibration for snd_device(15) acdb_id(4)
E/ACDB-LOADER( 180): Error: ACDB AudProc vol returned = -8
D/audio_hw_primary( 180): enable_snd_device: snd_device(15: handset-mic)
D/audio_hw_primary( 180): enable_audio_route: apply mixer path: audio-record
D/audio_hw_primary( 180): start_input_stream: exit
D/VLC ( 9437): live555 demux: RTP subsession 'video/H264'
D/VLC ( 9437): main input: selecting program id=0
D/VLC ( 9437): live555 demux: setup start: 0.000000 stop:0.000000
D/VLC ( 9437): live555 demux: We have a timeout of 60 seconds
D/VLC ( 9437): live555 demux: spawned timeout thread
D/VLC ( 9437): live555 demux: play start: 0.000000 stop:0.000000
D/VLC ( 9437): main demux: using access_demux module "live555"
D/VLC ( 9437): main decoder: looking for packetizer module matching "any": 20 candidates
D/VLC ( 9437): packetizer_h264 decoder: found NAL_SPS (sps_id=0)
D/VLC ( 9437): packetizer_h264 decoder: found NAL_PPS (pps_id=0 sps_id=0)
D/VLC ( 9437): main decoder: using packetizer module "packetizer_h264"
D/VLC ( 9437): main input: starting in async mode
D/VLC ( 9437): main demux meta: looking for meta reader module matching "any": 1 candidates
D/VLC ( 9437): main demux meta: no meta reader modules matched
D/VLC ( 9437): main input: `rtsp://192.168.10.4:8554/stream' successfully opened
D/VLC ( 9437): main input: switching to sync mode
D/VLC ( 9437): main input: Buffering 0%
D/VLC ( 9437): main input: Buffering 7%
D/VLC ( 9437): main input: Buffering 15%
D/VLC ( 9437): main input: Buffering 24%
D/VLC ( 9437): main input: Buffering 32%
D/VLC ( 9437): main input: Buffering 41%
D/VLC ( 9437): main input: Buffering 49%
D/VLC ( 9437): main input: Buffering 58%
D/VLC ( 9437): main input: Buffering 66%
D/VLC ( 9437): main input: Buffering 75%
D/VLC ( 9437): main input: Buffering 83%
D/VLC ( 9437): main input: Buffering 92%
D/VLC ( 9437): main input: Stream buffering done (503 ms in 500 ms)
D/VLC ( 9437): main input: Decoder buffering done in 0 ms
D/VLC ( 9437): live555 demux: lost 22852 bytes
D/VLC ( 9437): live555 demux: increasing buffer size to 200000
D/VLC ( 9437): main stream output: adding a new sout input (sout_input:0x78312028)
D/VLC ( 9437): stream_out_duplicate stream out: duplicated a new stream codec=h264 (es=0 group=0)
D/VLC ( 9437): main decoder: looking for decoder module matching "any": 31 candidates
D/VLC ( 9437): avcodec decoder: trying to use direct rendering
D/VLC ( 9437): avcodec decoder: allowing 4 thread(s) for decoding
D/VLC ( 9437): avcodec decoder: avcodec codec (H264 - MPEG-4 AVC (part 10)) started
D/VLC ( 9437): avcodec decoder: using frame thread mode with 4 threads
D/VLC ( 9437): main decoder: using decoder module "avcodec"
D/VLC ( 9437): main packetizer: looking for packetizer module matching "any": 20 candidates
D/VLC ( 9437): packetizer_h264 packetizer: found NAL_SPS (sps_id=0)
D/VLC ( 9437): packetizer_h264 packetizer: found NAL_PPS (pps_id=0 sps_id=0)
D/VLC ( 9437): main packetizer: using packetizer module "packetizer_h264"
D/VLC ( 9437): stream_out_duplicate stream out: - added for output 0
D/VLC ( 9437): main mux: adding a new input
D/VLC ( 9437): mux_ts mux: adding input codec=h264 pid=68
D/VLC ( 9437): mux_ts mux: new PCR PID is 68
D/VLC ( 9437): stream_out_duplicate stream out: - added for output 1
W/VLC ( 9437): main mux: late buffer for mux input (116866)
D/VLC ( 9437): avcodec decoder: available software decoder output format 0 (yuv420p)
D/VLC ( 9437): main spu text: looking for text renderer module matching "any": 1 candidates
D/VLC ( 9437): freetype spu text: using fontsize: 2
D/VLC ( 9437): main spu text: using text renderer module "freetype"
D/VLC ( 9437): main scale: looking for video filter2 module matching "any": 32 candidates
D/VLC ( 9437): swscale scale: 32x32 chroma: YUVA -> 16x16 chroma: RGBA with scaling using Bicubic (good quality)
D/VLC ( 9437): main scale: using video filter2 module "swscale"
D/VLC ( 9437): main scale: looking for video filter2 module matching "any": 32 candidates
D/VLC ( 9437): yuvp scale: YUVP to YUVA converter
D/VLC ( 9437): main scale: using video filter2 module "yuvp"
D/VLC ( 9437): main video output: Deinterlacing available
D/VLC ( 9437): main video output: deinterlace 0, mode blend, is_needed 0
D/VLC ( 9437): main video output: Opening vout display wrapper
D/VLC ( 9437): main vout display: looking for vout display module matching "any": 2 candidates
D/VLC ( 9437): android_surface vout display: Pixel format RV32
D/VLC ( 9437): main vout display: VoutDisplayEvent 'fullscreen' 0
D/VLC ( 9437): main vout display: using vout display module "android_surface"
D/VLC ( 9437): main vout display: A filter to adapt decoder to display is needed
D/VLC ( 9437): main filter: looking for video filter2 module matching "any": 32 candidates
D/VLC ( 9437): yuv_rgb_neon filter: I420(1280x720) to RV32(1280x720)
D/VLC ( 9437): main filter: using video filter2 module "yuv_rgb_neon"
D/VLC ( 9437): main vout display: Filter 'yuv_rgb_neon' (0x798c5c6c) appended to chain
D/VLC ( 9437): main video output: original format sz 1280x720, of (0,0), vsz 1280x720, 4cc I420, sar 1:1, msk r0x0 g0x0 b0x0
D/VLC ( 9437): avcodec decoder: enabling direct rendering
E/VLC ( 9437): main vout display: Failed to change zoom
E/VLC ( 9437): main vout display: Failed to set on top
E/VLC ( 9437): main vout display: Failed to change source AR
W/VLC ( 9437): yuv_rgb_neon filter: can't get output picture
W/VLC ( 9437): yuv_rgb_neon filter: can't get output picture
D/VLC ( 9437): main vout display: auto hiding mouse cursor
D/VLC ( 9437): live555 demux: tk->rtpSource->hasBeenSynchronizedUsingRTCP()
E/VLC ( 9437): main input: ES_OUT_RESET_PCR called
D/VLC ( 9437): main input: Buffering 0%
D/VLC ( 9437): main input: Buffering 8%
D/VLC ( 9437): main input: Buffering 16%
D/VLC ( 9437): main input: Buffering 24%
D/VLC ( 9437): main input: Buffering 33%
D/VLC ( 9437): main input: Buffering 41%
D/VLC ( 9437): main input: Buffering 50%
D/VLC ( 9437): main input: Buffering 58%
D/VLC ( 9437): main input: Buffering 66%
D/VLC ( 9437): main input: Buffering 75%
D/VLC ( 9437): main input: Buffering 75%
D/VLC ( 9437): main input: Buffering 75%
D/VLC ( 9437): main input: Buffering 83%
D/VLC ( 9437): main input: Buffering 91%
D/VLC ( 9437): main input: Buffering 99%
D/VLC ( 9437): main input: Stream buffering done (539 ms in 518 ms)
D/VLC ( 9437): main input: Decoder buffering done in 0 ms
D/dalvikvm( 9437): GC_FOR_ALLOC freed 5420K, 15% free 32857K/38316K, paused 76ms, total 76ms
W/VLC ( 9437): mux_ts mux: packet with too strange dts (dts=10764539955,old=10764551112,pcr=10764551112)
D/dalvikvm( 511): GC_CONCURRENT freed 2084K, 24% free 17531K/23020K, paused 2ms+4ms, total 72ms
D/dalvikvm( 9437): GC_FOR_ALLOC freed 7879K, 13% free 32853K/37448K, paused 17ms, total 17ms