Hi,

I have been working on a IMX21 based board which has a LCD controller that can display using 16bpp (5R,6G,5B). I cross compiled libjpeg and tried to write to /dev/fb0 and it works pretty well. So I know that the device funtions properly

I cross compiled ffmpeg, SDL and DirectFB to get video decoding working. The video shows up, but the colors have that washed out feel. Most of the details are gone and I see some crappy picture. I tried to debug the problem and here is what I have found.

1. I cannot draw a rectangle with correct color in directfb standalone application also. The DFBSurface has a pixelformat index of 18 (ARGB) and DFBLayer has a pixelformat index of 1 (RGB16). If I try to set the color index using the DFBSurfaceDescription element (dsc), the pixelformat does not change. It remain 18. I cannot set correct colors using SetColor(). The rectangle shows at the correct place but with wrong colors and shows up only when alpha value is high !!

2. The tools provided, dfbinfo gives this output
(*) DirectFB/Config: Parsing config file '/etc/directfbrc'.

       ---------------------- DirectFB v0.9.25 ---------------------
             (c) 2000-2002  convergence integrated media GmbH
             (c) 2002-2004  convergence GmbH
        -----------------------------------------------------------

(*) DirectFB/Core: Single Application Core. (2006-06-13 08:49)
(*) DirectFB/Graphics: Generic Software Rasterizer 0.6 (convergence integrated media GmbH)
(*) DirectFB/Core/WM: Default 0.2 (Convergence GmbH)
 (!!!)  *** UNIMPLEMENTED [fusion_reactor_set_lock] *** [reactor.c:853]
trying to open /dev/tty0

Screen (00) FBDev Primary Screen            (primary screen)
   Caps: VSYNC POWER_MANAGEMENT

     Layer (00) FBDev Primary Layer             (primary layer)
        Type:    GRAPHICS
        Caps:    SURFACE BRIGHTNESS CONTRAST SATURATION

3. The dfbdump gives following output

(*) DirectFB/Config: Parsing config file '/etc/directfbrc'.

       ---------------------- DirectFB v0.9.25 ---------------------
             (c) 2000-2002  convergence integrated media GmbH
             (c) 2002-2004  convergence GmbH
        -----------------------------------------------------------

(*) DirectFB/Core: Single Application Core. (2006-06-13 08:49)
(*) DirectFB/Graphics: Generic Software Rasterizer 0.6 (convergence integrated media GmbH)
(*) DirectFB/Core/WM: Default 0.2 (Convergence GmbH)
 (!!!)  *** UNIMPLEMENTED [fusion_reactor_set_lock] *** [reactor.c:853]
(!) DirectFB/FBDev: Panning display failed!
    --> Invalid argument
trying to open /dev/tty0
FBDev Primary Layer

Width       240
Height      320
Format      RGB16
Buffermode  BACKSYSTEM

4. I have a directfbrc file with the following

system=fbdev
fbdev=/dev/fb0
mode=240x320
depth=16
pixelformat=RGB16
no-vt-switch
no-vt-switching

5. I have no directfb.modes file. Is this necessary ?

Please help me out in finding what I am doing wrong. Even SDL programs shows the BMP files in wrong colors
I am using static linking at all places


Regards
Prateek


--
Prateek Dayal
http://flickr.com/photos/prateekdayal
_______________________________________________
directfb-users mailing list
[email protected]
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-users

Reply via email to