I'm having no luck trying to use the DVD subpicture layer (unichrome
driver). I have confirmed that the layer surface has a sensible
palette and that its pixels are being set to non-transparent values.
However, I don't see anything on the screen (just the video and
graphics layers).
Any ideas? Is there any example code around that uses this layer (I
haven't been able to find any)?
I'm using the unichrome driver's video underlay mode but have tried a
number of the DirectFB test apps with and without this option: I just
get a black screen when using the subpicture layer.
Any help appreciated.
I'm also interested to know if this layer scales with the video plane
or not (for my purposes I'd rather it didn't).
If it helps, my current test code is below (C++ with ++DFB).
Regards,
Mark
---- code fragment ----
IDirectFBDisplayLayer spic_layer = sm_dfb.GetDisplayLayer(2);
spic_layer.SetCooperativeLevel(DLSCL_EXCLUSIVE);
spic_layer.SetOpacity(255);
IDirectFBSurface spic_surface = spic_layer.GetSurface();
void *data;
int pitch;
spic_surface.Lock(DSLF_WRITE, &data, &pitch);
for (int y=100; y<200; y++)
for (int x=100; x<200; x++)
*(reinterpret_cast<char *>(data) + pitch * y + x) = 0x88;
spic_surface.Unlock();
---- end code fragment ----
NB I have checked the default palette and 0x88 is red. The default
layer config is sensible: dfblayer -l2 reports the following
VIA Unichrome DVD Subpicture
Width 720
Height 576
Format ALUT44
Buffermode FRONTONLY
Options none
_______________________________________________
directfb-users mailing list
[email protected]
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-users