How to let imx6 decode mjpeg(720p) smoothly

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to let imx6 decode mjpeg(720p) smoothly

ソリューションへジャンプ
3,479件の閲覧回数
huangjacky
Contributor III

Dear All:

I am using webcam 720P from Logitech and I tried successfully mjpeg decode on iMX6. Below are the commands.


gst-launch v4l2src device=/dev/video2 ! image/jpeg,width=1280,height=720,framerate=30/1 ! queue ! jpegdec ! mfw_v4lsink


It works but jerky


How to improve the preformance of the imx6 mjpeg decoder.

follow the imx6 codec datasheet,  imx6 can decode mjpeg up to 1080p!


Thank you advance!

ラベル(3)
0 件の賞賛
返信
1 解決策
1,712件の閲覧回数
LeonardoSandova
Specialist I

Not sure if that element exists. Creating a new custom element is an option but it may take you some time. Another approach is compare the mjpeg header coming from the camera with the ones expected by VPUdec. Check if there is a software to view mjpeg data, then you can compare headers between 'v4l2src - > filesink' and media file that the vpudec can decode fine.

Leo

元の投稿で解決策を見る

0 件の賞賛
返信
5 返答(返信)
1,712件の閲覧回数
LeonardoSandova
Specialist I

Try using vpudec, which is a hardware decoder:

gst-launch v4l2src ! vpudec ! mfw_v4lsink

Leo

0 件の賞賛
返信
1,712件の閲覧回数
huangjacky
Contributor III

Thanks for your reply!

I have try the vpudec before!  but....

IMG_0005.JPG

I got the green screen! 

and the vpudec output the error print as below:

New clock: GstSystemClock

[INFO]  bitstreamMode 1, chromaInterleave 0, mapType 0, tiled2LinearEnable 0

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

[ERR]   JpegDecodeHeader failure

>>V4L_SINK: Actually buffer status:

        hardware buffer : 7

        software buffer : 0

full screen size:1280x720

0 件の賞賛
返信
1,712件の閲覧回数
LeonardoSandova
Specialist I

Please try this:

1. Base on the original pipeline, change to filesrc (with a mjpeg file) instead of v4l2src. I just want to make sure that the decoder is working as expected. Is rendering OK?

2. Base on the original pipeline, change to filesink instead of mfw_v4lsink, just to discard a video sink issue. Playback this file either with gplay or in your host with any player you want. Is playback OK?

Let me know your results.

Leo

0 件の賞賛
返信
1,712件の閲覧回数
huangjacky
Contributor III

Thanks for your reply!

I think it's the mjpeg data stream isn't the standard mjpeg type after testing.

Maybe it's relate to the compatibility of the vpu mjpeg decoder.

how can I transform the mjpeg data stream to the standard mjpeg stream?

Thanks!

0 件の賞賛
返信
1,713件の閲覧回数
LeonardoSandova
Specialist I

Not sure if that element exists. Creating a new custom element is an option but it may take you some time. Another approach is compare the mjpeg header coming from the camera with the ones expected by VPUdec. Check if there is a software to view mjpeg data, then you can compare headers between 'v4l2src - > filesink' and media file that the vpudec can decode fine.

Leo

0 件の賞賛
返信