[maemo-developers] [maemo-developers] Xvideo support for Nokia 770?

From: Siarhei Siamashka siarhei.siamashka at gmail.com
Date: Tue Jan 9 23:21:02 EET 2007
On Tuesday 09 January 2007 20:59, Charles 'Buck' Krasic wrote:

> Any chance the Xvideo support in the Bora 3.0  will turn up in a 770 OS?

I asked the same question on #maemo irc channel and daniels explained that
video scaling is done by gpu on N800, so probably the same code can't be
reused on 770: https://mg.pov.lt/maemo-irclog/%23maemo.2007-01-08.log.html

Actually I have been thinking about trying to implement Xvideo support on 770
for some time already. Now as N800 has Xvideo support, it would be nice to
have it on 770 as well for better consistency and software compatibility.

I see the following possible options:

1. Implement it just using ARM core and optimize it as much as possible 
(using dynamically generated code for scaling to get the best performance).
Is quite a straightforward solution and only needs time to implement it.

2. Try using dsp tasks that already exist on the device and are used for
dspfbsink. But the sources of gst plugins contain code that limits 
video resolution for dspfbsink. I wonder if this check was introduced
artificially or it is the limitation of DSP scaler and it can't handle
anything larger than that. Also I wonder if existing video scaler DSP task can
support direct rendering [2]. It would need to support arbitrary number of
memory mapped buffers for video output in order to avoid unnecessary 
memcpy, otherwise performance will suffer.

Maybe we can ask Nokia developers to provide some information about the 
internals of these plugins. The most important questions are:
* What are the real capabilities of DSP based scaler, can it be used for
resolutions let's say up to 800x480?
* Where is the screen update performed after dsp has finished
scaling/converting video from mapped buffer to framebuffer? Is it done on 
ARM side, or probably screen update can be also triggered from DSP directly?
* Is it possible to get direct rendering [2] support with existing dsp tasks
on 770? If not, would it be too hard to implement this feature?
* How are timestamps handled in dsp? Is it possible to just send a one shot
signal to dsp task for rendering video frame from a mapped buffer as fast as

A brief dsp interface description would be welcome. Maybe some questions 
may be trivial, but unfortunately I did not have much time for a detailed walk
through the sources in order to figure out how this all works. If any Nokia 
developer finds time for some short answers, it would really help a lot.

3. Try implementing a new DSP based scaler from scratch. The most 
important thing to know is how to access framebuffer directly from DSP 
and move data to it from mapped buffer without any overhead. The first 
test implementation can just perform nonscaled planar YV12 -> packed YUV422
conversion, if it proves to be fast and useful, it  could be extended to also
support scaling.

PS. This is unrelated to Xvideo support development, but also it would be nice
to have more or less detailed description of dsp based gstreamer elements 
and their properties. While the sources of these plugins are available (with a
hidden dsp part), some docs are needed to know how they are supposed to 
work  in order to use them efficiently and probably improve.

[2] http://www.mplayerhq.hu/DOCS/tech/dr-methods.txt

More information about the maemo-developers mailing list