Hi,
   Is your video layer also uses DirectFB.
The problem what i feel is, as you are setting the primary layer to full transparent, So in case of T.V you might know there is a Compositor. So this compositor is blending the alpha provided by you for the primary screen, with the Alphs provided by the Video layer, and since you have given full transparency for primary screen, you video is also getting blanked.

   You can try giving intermediate value and see if you are getting video.

What i suggest is, if you have some compositor, or a display feeder, you can just check the driver provided by that device, and see is there any way to disable the graphics layer, So when you have finished Drawing just disable the Primary layer, and again when you are about to draw enable the Primary layer.

   Just try this, Else we need to see how this can be done.

regards
Animesh.


Alex Vazquez wrote:
Hi,

i'm using directfb 1.0. The hardware it runs on supports five layers; two of them are the video layer and the primary layer. I use the primary layer to draw a semi-transparent gui (osd) over the video.

The problem i have is that i don't know how to clear the surface of the primary layer keeping the transparent effect over the video. The only way i can clear the primary surface is doing a primary_srfc->Clear (primary_srfc, 0, 0, 0, 255) but that way i can't see the video through the primary layer. I guess it has something to do with the layer/surface configuration.

This is how i create the primary surface:

  dsc.flags      = DSDESC_CAPS;
  dsc.caps      = DSCAPS_PRIMARY | DSCAPS_FLIPPING;
  DFBCHECK(dfb -> CreateSurface(dfb, &dsc, &primary_srfc));

  DFBCHECK(primary_srfc -> SetDrawingFlags(primary_srfc, DSDRAW_BLEND));

DFBCHECK (primary_srfc -> SetBlittingFlags (primary_srfc, DSBLIT_BLEND_ALPHACHANNEL));

Then, i draw things and this is how i try to clear it (i also tried one more Flip and one more clear):

  DFBCHECK (primary_srfc -> Clear (primary_srfc, 0, 0, 0, 0));
DFBCHECK (primary_srfc -> Flip (primary_srfc, NULL, DSFLIP_WAITFORSYNC | DSFLIP_BLIT));
  DFBCHECK (primary_srfc -> Clear (primary_srfc, 0, 0, 0, 0));

which doesn't to anything visible. If i clear with total opacity (0,0,0,255) the screen goes black and i can't see the video.

If you need some more info i can provide it. Any help is appreciated.

Thanks,

--
Alejandro Vazquez Fente
------------------------------------------------------------------------

_______________________________________________
directfb-users mailing list
directfb-users@directfb.org
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-users

_______________________________________________
directfb-users mailing list
directfb-users@directfb.org
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-users

Reply via email to