1 /*****************************************************************************
3 *****************************************************************************
4 * Copyright (C) 2001 VideoLAN
5 * $Id: DrawingTidbits.h,v 1.2 2001/03/21 13:42:33 sam Exp $
7 * Authors: Tony Castley <tcastley@mail.powerup.com.au>
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
22 *****************************************************************************/
24 #ifndef __DRAWING_TIBITS__
25 #define __DRAWING_TIBITS__
27 #include <GraphicsDefs.h>
29 rgb_color ShiftColor(rgb_color , float );
31 bool operator==(const rgb_color &, const rgb_color &);
32 bool operator!=(const rgb_color &, const rgb_color &);
35 Color(int32 r, int32 g, int32 b, int32 alpha = 255)
46 const rgb_color kWhite = { 255, 255, 255, 255};
47 const rgb_color kBlack = { 0, 0, 0, 255};
49 const float kDarkness = 1.06;
50 const float kDimLevel = 0.6;
52 void ReplaceColor(BBitmap *bitmap, rgb_color from, rgb_color to);
53 void ReplaceTransparentColor(BBitmap *bitmap, rgb_color with);