prefect
7dee30e24c
- explicitly split ambient and diffuse - add renderer.shadowZBias to bias depths in the depth texture and avoid flickering artifacts caused by Z fighting - cantabrian_generated uses new light values so that shadows aren't pitch black This was SVN commit r3508.
45 lines
855 B
C
Executable File
45 lines
855 B
C
Executable File
///////////////////////////////////////////////////////////////////////////////
|
|
//
|
|
// Name: Color.h
|
|
// Author: Rich Cross
|
|
// Contact: rich@wildfiregames.com
|
|
//
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
#ifndef _COLOR_H
|
|
#define _COLOR_H
|
|
|
|
#include "Vector3D.h"
|
|
#include "Vector4D.h"
|
|
#include "lib/types.h"
|
|
|
|
// simple defines for 3 and 4 component floating point colors - just map to
|
|
// corresponding vector types
|
|
typedef CVector3D RGBColor;
|
|
typedef CVector4D RGBAColor;
|
|
|
|
// SColor3ub: structure for packed RGB colors
|
|
struct SColor3ub
|
|
{
|
|
u8 R;
|
|
u8 G;
|
|
u8 B;
|
|
};
|
|
|
|
// SColor4ub: structure for packed RGBA colors
|
|
struct SColor4ub
|
|
{
|
|
u8 R;
|
|
u8 G;
|
|
u8 B;
|
|
u8 A;
|
|
|
|
SColor4ub() { }
|
|
SColor4ub(u8 _r, u8 _g, u8 _b, u8 _a) : R(_r), G(_g), B(_b), A(_a) { }
|
|
};
|
|
|
|
extern u32 (*ConvertRGBColorTo4ub)(const RGBColor& src);
|
|
|
|
|
|
#endif
|