Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Re: AddColor() / SetColor()



Sascha Volkenandt wrote:
> 
> Am Montag, 24. Mai 2004 10:56 schrieb Klaus Schmidinger:
> > Maybe I should make cOsd::GetBitmap() a 'protected' function, because
> > it really only is of use for a derived cOsd class that actually uses
> > areas...
> 
> If you do that please provide a way to clear a specific area's palette (in
> case there is one). Or maybe you replace the palette automatically if any
> draw operation covers one area completely (for example drawing a cBitmap
> exactly over an area that has been drawn on before).

This is already the case.
Take a look at cBitmap::DrawRectangle():

     if (x1 == 0 && y1 == 0 && x2 == width - 1 && y2 == height - 1)
        Reset();

and of course osd.h:

  void DrawRectangle(int x1, int y1, int x2, int y2, tColor Color);
       ///< Draws a filled rectangle defined by the upper left (x1, y1) and lower right
       ///< (x2, y2) corners with the given Color. If the rectangle covers the entire
       ///< bitmap area, the color palette will be reset, so that new colors can be
       ///< used for drawing.

Klaus


-- 
Info:
To unsubscribe send a mail to ecartis@linuxtv.org with "unsubscribe vdr" as subject.



Home | Main Index | Thread Index