你好!
我想播放解码h264视频并显示,视频分辨率为1024×768。我使用了openmax下的decode_display例子播放这个视频,首先我把原始参数width从1920改成1024,而height从1080改成768。能正常显示,但是输出的视频分辨率还是1080p,只是一帧图像变成我设置的大小。后来我查看资料,有几个问题想请教一下:
1.decode_display这个例子是否只支持1080p和720p分辨率输出。
2.openmax手册中说venc只支持720p和1080p,为什么我修改了omx capture_encode例子,它却能采集编码成1024×768的h264文件。
3.那我能不能修改omx中decode_display例子,让他能显示出成1024×768?如果能,能给我写意见吗?不能的话,那有什么办法解码显示1024×768分辨率的视频?
yu bin1:
回复 Chris Meng:
Chris Meng ,
谢谢你的答复。当时我们评估板光碟就是ezsdk,所以一直使用。hdmi分辨率一直可以调,就按你发给我的贴上说的方法一样。但是omx中encd组件只能支持720p和1080p。因为我们需要解码,所以我们想修改decode_display例子,除了720p和1080p,其他都会报错。以下是错误:
input file: good.h264width: 1024height: 768frame_rate: 30gfx: fbdev disablecodec: h264display_id: 0 Decoder-Display example =============================== OMX_Init completed UIAClient is ready to send a UIA configuration commandUIAClient received UIA_CONFIGURE_ACKUIAClient is done sending requestsUIAClient is ready to send a UIA configuration commandUIAClient received UIA_CONFIGURE_ACKUIAClient is done sending requests opening file decoder compoenent is created PADX: 32 PADY: 24 level set is 12 scalar compoenent is created set input port params (width = 1024, height = 768) set output port params (width = 1024, height = 768) set number of channels set input resolution set output resolution enable scalar input port got eventEnable/Disable Event enable scalar output port got eventEnable/Disable Event found handle 0x1405f8 for component OMX.TI.VPSSM3.VFDC got display handle found handle 0x144100 for component OMX.TI.VPSSM3.CTRL.DCBuffer Size computed: 1572864set input port params (width = 1024, height = 768) setting input and output memory type to defaultenable input port got eventEnable/Disable Event connect call for decoder-scalar connect call for scalar-display decoder inport buffers allocated decoder outport buffers allocated got eventState changed to: OMX_StateIdle state IDLE Scalar input port use buffer done scalar outport buffers allocated got eventState changed to: OMX_StateIdle scalar state IDLE got eventState changed to: OMX_StateIdle ctrl-dc state IDLE got eventState changed to: OMX_StateIdle display state IDLE got eventState changed to: OMX_StateExecuting display control state execute hello OMX_SendCommandgot event*** unrecoverable error: OMX_ErrorBadParameter (0x80001005)
我想问能否有办法修改decode_display能让他支持其他分辨率。是不是要增加对其他分辨支持要修改hdvicp2的程序,但是在ezsdk中找不到hdvicp2的程序。再次期待你的答复,谢谢。
Chris Meng:
回复 yu bin1:
Bin Yu,
抱歉EZSDK我不是很熟悉,而且M3的源码代码也没有。
从错误看不出来,错误是在编码侧,还是在显示侧。现在显示支持1024×768么?
yu bin1:
回复 Chris Meng:
谢谢,你的答复,这个问题已经解决。