PyOpenAirMirror icon indicating copy to clipboard operation
PyOpenAirMirror copied to clipboard

On Raspberry Pi make use of OpenMAX (VideoCore) for decoding+rendering

Open tzwenn opened this issue 10 years ago • 6 comments

Pretty slow with current setup. First investigate if delay is in decryption, decoding or rendering.

tzwenn avatar Feb 19 '15 21:02 tzwenn

Profiling on rPi B shows most delay comes from ffmpeg h264 decoding, but also SDL rendering is at sub-interactive rates.

ncalls  tottime  percall  cumtime  percall filename:lineno(function)
56    8.515    0.152    8.515    0.152 {method 'decodeFrame' of 'h264decode.Decoder' objects}
43    1.335    0.031    1.335    0.031 {method 'display' of 'pygame.overlay' objects}
56    0.003    0.000    0.096    0.002 blockalgo.py:246(decrypt)

Comparison to ffmpeg on i7 (hardware accelerated AES+H.264):

ncalls  tottime  percall  cumtime  percall filename:lineno(function)
267    2.874    0.011    2.874    0.011 {method 'display' of 'pygame.overlay' objects}
267    0.824    0.003    0.824    0.003 {method 'decodeFrame' of 'h264decode.Decoder' objects}
267    0.001    0.000    0.033    0.000 blockalgo.py:246(decrypt)

tzwenn avatar Feb 20 '15 10:02 tzwenn

How to do it ? can u tell me the step ?

joole avatar Dec 02 '16 13:12 joole

Haven't done it yet, since for a weekend project the first glimpse of the OpenMAX API was a bit discouraging.

tzwenn avatar Dec 02 '16 13:12 tzwenn

Yes,I know how to decode h264 packet, but i don't know how to run PyOpenAirMirror on Raspberry, I never success run it on ubuntu ,so please tell me how to run the PyOpenAirMirror on rpi,if i can,i will decode using OPENMAX API to decode it and re-coded it using c++,please help me

joole avatar Dec 04 '16 10:12 joole

Well, I haven't had any issues after installing avahi. And I used a macOS and fplyServer for an external fp-setup handshake. Alternatively you can use https://github.com/espes/Slave-in-the-Magic-Mirror, if you don't have access to macOS.

tzwenn avatar Dec 05 '16 09:12 tzwenn

Thank,I will try it right now

joole avatar Dec 05 '16 10:12 joole