Quoting Ville Syrjälä:

> On Fri, Jan 26, 2007 at 12:12:20AM +0100, Stefan Lucke wrote:
> > On Donnerstag 25 Januar 2007 22:30, Ville Syrjälä wrote:
> > > On Thu, Jan 25, 2007 at 06:54:02PM +0000, Mark Adams wrote:
> > > > > But now I've a real strange situation:
> > > > > For clearing the OSD (full transparent) I've to use Clear(r, b, g, a) 
> > > > > with
> > > > > Clear(0, 0, 0, 0) which is "normal" transparent black.
> > > > >
> > > > > But for OSD drawing into the surface I've to invert alpha:
> > > > > transparent black is (0, 0, 0, 0xff) solid black is (0, 0, 0, 0) .
> > > >
> > > > I was just looking into that, thinking it was probably an obvious typo
> > > > on my part but I'm not sure it is.
> > > >
> > > > What's puzzling me is that
> > > >
> > > >   Clear(r,g,b,a)
> > > >
> > > > is equivalent to
> > > >
> > > >   SetColor(r,g,b,a)
> > > >   SetDrawingFlags(DSDRAW_NOFX)
> > > >   FillRectangle(...)
> > > >
> > > > If you're seeing a difference, I can only assume that you're using
> > > > some other drawing flags, e.g. DSDRAW_BLEND.  If that's the case then
> > > > your drawing operations will be using the software fallback since we
> > > > can't do hardware accelerated blending on AiRGB surfaces.
> > > >
> > > > So it looks to me like the problem is in the software renderer, which
> > > > is not my area of expertise I'm afraid.
> > >
> > > I found a bug in AiRGB color handling in the sw rendering code, and
> > > commited a fix to CVS. Stefan, let me know if the problem still
> > > persists.
> >
> > Thanks, but no, the situation is still the same.
> > To see video after OSD is closed, I still have to use (check for VIA
> > should be dropped):
> >
> >       /* 
> > ---------------------------------------------------------------------
> >        * In case of of AiRGB we have to reset clearAlpha value for VIA
> >        */
> >       if (fmt == DSPF_AiRGB && isVIAUnichrome)
> >         clearAlpha = 0;
> >
> >
> > And at OSD close (with: "#define COLORKEY 0,0,0") :
> >       tmpSurface->Clear(COLORKEY,clearAlpha); //clear and
> >       tmpSurface->Flip(); // Flip the field
> >
> > Same behaviour is shown when I use the following in ClearOSD():
> >       //tmpSurface->Clear(COLORKEY,clearAlpha); //clear and
> >       tmpSurface->SetColor(COLORKEY,clearAlpha);
> >       tmpSurface->SetBlittingFlags(DSBLIT_NOFX);
>
> SetDrawingFlags(DSDRAW_NOFX)?

Damm.

>
> >       tmpSurface->FillRectangle(0,0, Xres, Yres);
> >       tmpSurface->Flip(); // Flip the field
>
> These two methods (if you use DSDRAW_NOFX in the latter case) should
> provide identical results (and use the same code paths). Is that not the
> case?

They provide the same result, even for sw rendering (no-hardware).
clearAlpha must be set to 0.

(*) DirectFB/Graphics: Acceleration disabled (by 'no-hardware')
(*) DirectFB/Core/WM: Default 0.3 (directfb.org)

Code path should be the same as I used (0,0, Yres, Yres) for FillR..() in the
first case an wondered about an right part of OSD which was not removed.

>
> > I guess thats an indicator (but no proove) that I'm _not_ using
> > SW rendering for Clear() .
>
> You can use the no-hardware directfbrc option to force software
> rendering.

Stefan Lucke

_______________________________________________
directfb-dev mailing list
[email protected]
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-dev

Reply via email to