![]() |
CMGDK r49-rc2
|
#include <TileGroup.H>
公有成员 | |
TileObject * | operator[] (int n) |
[]操作符重载 | |
TileGroup (TileData *td) | |
TileGroup (TileData *td, TDFNode *tdf, int max_count=-1) | |
TileGroup (TileData *td, Stream *str, int max_count=-1) | |
TileGroup (TileData *td, const wchar_t *fn, int max_count=-1) | |
TileGroup (TileData *td, HAC *hac, const wchar_t *fn, int max_count=-1) | |
virtual | ~TileGroup () |
void | Add (TDFNode *, int max_count=-1) |
从TDF节点增加一个图片到本群组 | |
void | Add (Stream *, int max_count=-1) |
从流中增加一个图片到本群组 | |
void | Add (const wchar_t *, int max_count=-1) |
从指定文件增加一个图片到本群组 | |
void | Add (HAC *, const wchar_t *, int max_count=-1) |
从指定文件增加一个图片到本群组 | |
virtual void | Add (uint8 *, int, int, ColorType, int max_count=-1) |
直接增加指定格式的图块 | |
void | Draw (int n, float l, float t) const |
<在l,t处绘制第n个Tile | |
void | Draw (int n, float l, float t, float w, float h) const |
<在l,t处以w,h为缩放比绘制第n个Tile | |
template<typename T > | |
void | Draw (int n, const RectScope2< T > &rs) const |
void | Draw (DrawArray *da, int n, float l, float t) const |
void | Draw (DrawArray *da, int n, float l, float t, float w, float h) const |
template<typename T > | |
void | Draw (DrawArray *da, const RectScope2< T > &rs) const |
公有属性 | |
Property< int > | Count |
Tile数量 | |
保护成员 | |
int | GetCount () |
virtual TileObject * | SplitTile (uint8 *, int, int, int, int, ColorType) |
void | LoadFromTDF (TDFNode *, int max_count=-1) |
void | InitPrivate (TileData *) |
保护属性 | |
TileData * | tile_data |
int | tile_count |
TileObject ** | tile_object |
TileGroup是控制一个或一批Tile的加载、渲染、排列等等的程序基类。
这个基类可以自动的拆分较大的图片到Tile的大小。
hgl::TileGroup::TileGroup | ( | TileData * | td | ) | [inline] |
hgl::TileGroup::TileGroup | ( | TileData * | td, |
HAC * | hac, | ||
const wchar_t * | fn, | ||
int | max_count = -1 |
||
) | [inline] |
hgl::TileGroup::~TileGroup | ( | ) | [virtual] |
void hgl::TileGroup::Add | ( | const wchar_t * | filename, |
int | max_count = -1 |
||
) |
从指定文件增加一个图片到本群组
从指定文件增加一个图片到本群组
void hgl::TileGroup::Add | ( | uint8 * | data, |
int | width, | ||
int | height, | ||
ColorType | color, | ||
int | max_count = -1 |
||
) | [virtual] |
直接增加指定格式的图块
被hgl::TilePicture重载。
void hgl::TileGroup::Draw | ( | DrawArray * | da, |
const RectScope2< T > & | rs | ||
) | const [inline] |
void hgl::TileGroup::Draw | ( | DrawArray * | da, |
int | n, | ||
float | l, | ||
float | t, | ||
float | w, | ||
float | h | ||
) | const [inline] |
void hgl::TileGroup::Draw | ( | int | n, |
float | l, | ||
float | t | ||
) | const [inline] |
<在l,t处绘制第n个Tile
void hgl::TileGroup::Draw | ( | int | n, |
const RectScope2< T > & | rs | ||
) | const [inline] |
void hgl::TileGroup::Draw | ( | int | n, |
float | l, | ||
float | t, | ||
float | w, | ||
float | h | ||
) | const [inline] |
<在l,t处以w,h为缩放比绘制第n个Tile
int hgl::TileGroup::GetCount | ( | ) | [inline, protected] |
void hgl::TileGroup::InitPrivate | ( | TileData * | td | ) | [protected] |
TileObject* hgl::TileGroup::operator[] | ( | int | n | ) | [inline] |
[]操作符重载
TileObject * hgl::TileGroup::SplitTile | ( | uint8 * | data, |
int | l, | ||
int | t, | ||
int | w, | ||
int | h, | ||
ColorType | color | ||
) | [protected, virtual] |
被hgl::TilePicture重载。
Tile数量
int hgl::TileGroup::tile_count [protected] |
TileData* hgl::TileGroup::tile_data [protected] |
TileObject** hgl::TileGroup::tile_object [protected] |