Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

Lamp::Color4c Class Reference

四要素キャラクタカラー More...

#include <Color4c.h>

List of all members.

Public Member Functions

 Color4c ()
 コンストラクタ

 Color4c (u_char sourceR, u_char sourceG, u_char sourceB, u_char sourceA=255)
 コンストラクタ

 Color4c (const Color3c &source)
 コンストラクタ

 Color4c (const Color3f &source)
 コンストラクタ

 Color4c (const Color4f &source)
 コンストラクタ

void set (u_char sourceR, u_char sourceG, u_char sourceB, u_char sourceA=255)
 値の設定

void set (const Color3c &source)
 三要素キャラクタカラーの設定

void set (const Color3f &source)
 三要素実数カラーの設定

void set (const Color4f &source)
 四要素実数カラーの設定

void setARGB (u_int source)
 ARGBカラーの設定.

u_int getARGB () const
 ARGBカラーの取得.

Color4c operator+ (const Color4c &addColor) const
 加算

Color4c operator- (const Color4c &subColor) const
 減算

Color4c operator * (const Color4c &mulColor) const
 乗算

Color4c operator * (float mulValue) const
 乗算

Color4c & operator+= (const Color4c &addColor)
 代入加算

Color4c & operator-= (const Color4c &subColor)
 代入減算

Color4c & operator *= (const Color4c &mulColor)
 代入乗算

Color4c & operator *= (float mulValue)
 代入乗算

Color4c & negative ()
 反対色

bool operator== (const Color4c &target) const
 同じ値かどうか

bool operator!= (const Color4c &target) const
 同じ値でないかどうか

String toString () const
 文字列化


Static Public Member Functions

Color4c lerp (const Color4c &source, const Color4c &target, float alpha)
 色の線形補間


Static Public Attributes

const Color4c white
 白

const Color4c gray
 灰色

const Color4c black
 黒

const Color4c red
 赤

const Color4c green
 緑

const Color4c blue
 青

const Color4c yellow
 黄

const Color4c cyan
 青緑

const Color4c magenta
 赤紫


Friends

Color4c operator * (float mulValue, const Color4c &mulColor)
 乗算


Detailed Description

四要素キャラクタカラー

このクラスは継承しないで下さい。

Definition at line 42 of file Color4c.h.


Constructor & Destructor Documentation

Lamp::Color4c::Color4c (   )  [inline]
 

コンストラクタ

このコンストラクタは初期値の設定を行わないため値は不定です。

Definition at line 103 of file Color4c.h.

Referenced by operator *(), operator+(), and operator-().

Lamp::Color4c::Color4c (  u_char  sourceR,
u_char  sourceG,
u_char  sourceB,
u_char  sourceA = 255
)  [inline]
 

コンストラクタ

Parameters:
sourceR 赤の初期値
sourceG 緑の初期値
sourceB 青の初期値
sourceA アルファの初期値

Definition at line 112 of file Color4c.h.

References a, b, g, and r.

Lamp::Color4c::Color4c (  const Color3c &  source  )  [explicit]
 

コンストラクタ

Parameters:
source 設定する色

Definition at line 65 of file Color4c.cpp.

Lamp::Color4c::Color4c (  const Color3f &  source  )  [explicit]
 

コンストラクタ

Parameters:
source 設定する色

Definition at line 70 of file Color4c.cpp.

References set().

Lamp::Color4c::Color4c (  const Color4f &  source  )  [explicit]
 

コンストラクタ

Parameters:
source 設定する色

Definition at line 75 of file Color4c.cpp.

References set().


Member Function Documentation

u_int Lamp::Color4c::getARGB (   )  const [inline]
 

ARGBカラーの取得.

Returns:
ARGBカラー

Definition at line 189 of file Color4c.h.

References a, b, g, r, and u_int.

Referenced by Lamp::ColorSpriteState::apply(), Lamp::GraphicsDevice::clear(), Lamp::SpritePictureRGBA8::compileImage(), Lamp::PictureRGBA8::compileImage(), Lamp::BasicFramework::drawInformationString(), Lamp::PrimitiveRenderer::renderRequest(), Lamp::FixedShader::resetFogOptionFixed(), Lamp::RenderingDevice::setAmbientColor(), and Lamp::RenderingDevice::setFog().

Color4c Lamp::Color4c::lerp (  const Color4c &  source,
const Color4c &  target,
float  alpha
)  [inline, static]
 

色の線形補間

Parameters:
source 開始色
target 対象色
alpha ブレンド係数
Returns:
線形補間された色

Definition at line 419 of file Color4c.h.

References a, b, g, r, and u_char.

Color4c& Lamp::Color4c::negative (   )  [inline]
 

反対色

アルファ値は変化しません。

Returns:
反転された色

Definition at line 407 of file Color4c.h.

References a, b, g, r, and set().

Color4c Lamp::Color4c::operator * (  float  mulValue  )  const [inline]
 

乗算

Parameters:
mulValue 乗算する値
Returns:
乗算された色

Definition at line 249 of file Color4c.h.

References a, b, Color4c(), g, and r.

Color4c Lamp::Color4c::operator * (  const Color4c &  mulColor  )  const [inline]
 

乗算

Parameters:
mulColor 乗算する色
Returns:
乗算された色

Definition at line 236 of file Color4c.h.

References a, b, Color4c(), g, and r.

Color4c& Lamp::Color4c::operator *= (  float  mulValue  )  [inline]
 

代入乗算

Parameters:
mulValue 乗算する値
Returns:
乗算された色

Definition at line 369 of file Color4c.h.

References a, b, g, r, and set().

Color4c& Lamp::Color4c::operator *= (  const Color4c &  mulColor  )  [inline]
 

代入乗算

Parameters:
mulColor 乗算する色
Returns:
乗算された色

Definition at line 355 of file Color4c.h.

References a, b, g, r, and set().

bool Lamp::Color4c::operator!= (  const Color4c &  target  )  const [inline]
 

同じ値でないかどうか

Parameters:
target 比較するカラー
Returns:
同じ値でなければtrueを返す

Definition at line 448 of file Color4c.h.

References a, b, g, and r.

Color4c Lamp::Color4c::operator+ (  const Color4c &  addColor  )  const [inline]
 

加算

Parameters:
addColor 加算する色
Returns:
加算された色

Definition at line 202 of file Color4c.h.

References a, b, Color4c(), g, and r.

Color4c& Lamp::Color4c::operator+= (  const Color4c &  addColor  )  [inline]
 

代入加算

Parameters:
addColor 加算する色
Returns:
加算された色

Definition at line 319 of file Color4c.h.

References a, b, g, r, and set().

Color4c Lamp::Color4c::operator- (  const Color4c &  subColor  )  const [inline]
 

減算

Parameters:
subColor 減算する色
Returns:
減算された色

Definition at line 219 of file Color4c.h.

References a, b, Color4c(), g, and r.

Color4c& Lamp::Color4c::operator-= (  const Color4c &  subColor  )  [inline]
 

代入減算

Parameters:
subColor 減算する色
Returns:
減算された色

Definition at line 337 of file Color4c.h.

References a, b, g, r, and set().

bool Lamp::Color4c::operator== (  const Color4c &  target  )  const [inline]
 

同じ値かどうか

Parameters:
target 比較するカラー
Returns:
同じ値であればtrueを返す

Definition at line 438 of file Color4c.h.

References a, b, g, and r.

void Lamp::Color4c::set (  const Color4f &  source  ) 
 

四要素実数カラーの設定

Parameters:
source 設定する色

Definition at line 102 of file Color4c.cpp.

References Lamp::Color4f::a, Lamp::Color4f::b, Lamp::Color4f::g, Lamp::Color4f::r, and set().

void Lamp::Color4c::set (  const Color3f &  source  ) 
 

三要素実数カラーの設定

Parameters:
source 設定する色

Definition at line 85 of file Color4c.cpp.

References Lamp::Color3f::b, Lamp::Color3f::g, Lamp::Color3f::r, and set().

void Lamp::Color4c::set (  const Color3c &  source  ) 
 

三要素キャラクタカラーの設定

Parameters:
source 設定する色

Definition at line 80 of file Color4c.cpp.

References Lamp::Color3c::b, Lamp::Color3c::g, Lamp::Color3c::r, and set().

void Lamp::Color4c::set (  u_char  sourceR,
u_char  sourceG,
u_char  sourceB,
u_char  sourceA = 255
)  [inline]
 

値の設定

Parameters:
sourceR 赤の設定値
sourceG 緑の設定値
sourceB 青の設定値
sourceA アルファの設定値

Definition at line 145 of file Color4c.h.

References a, b, g, and r.

Referenced by Lamp::PrimitiveDrawRequestBuilder::buildGrid(), Color4c(), Lamp::LinearMinificationFilter::filter(), Lamp::TargaLoader::loadImage(), negative(), operator *=(), operator+=(), operator-=(), set(), and Lamp::SimpleFramework::SimpleFramework().

void Lamp::Color4c::setARGB (  u_int  source  )  [inline]
 

ARGBカラーの設定.

Parameters:
source 

Definition at line 175 of file Color4c.h.

References a, b, g, r, and u_char.

String Lamp::Color4c::toString (   )  const [inline]
 

文字列化

Returns:
カラーの文字列表記

Definition at line 460 of file Color4c.h.

References a, b, Lamp::String::format(), g, and r.


Friends And Related Function Documentation

Color4c operator * (  float  mulValue,
const Color4c &  mulColor
)  [friend]
 

乗算

Parameters:
mulValue 乗算する値
mulColor 乗算される色
Returns:
乗算された色

Definition at line 283 of file Color4c.h.


The documentation for this class was generated from the following files:
Generated on Wed Mar 16 10:29:45 2005 for Lamp by doxygen 1.3.2