void njPtclSpriteStart( texid, col, flag )
Sint32 texid
Uint32 col
Sint32 flag
texid テクスチャ番号 col パーティクルの色 flag 半透明フラグ
なし
テクスチャ付きのパーティクル群の描画の開始を宣言します。この関数とnjPtclSpriteEnd()関数の間に実行する、njPtclDrawSprite()関数で実際の描画を行います。 njPtclSpriteStart関数とnjPtclSpriteEnd()関数の間では 何度でも njPtclDrawSprite()関数を呼ぶことができますが、他の描画関数を呼ぶことはできません。
UVの指定できませんので、1枚のテクスチャ全体が1パーティクルとなります。 引数 col に指定する色はARGB32ビットパックカラーです。
NJS_POINT3 ptcl[100] = { { 0.f, 0.f, 0.f }, { 1.f, 0.f, 0.f }, { 0.f, 1.f, 0.f }, : }; njPtclSpriteStart( 0, 0xffffffff, 0 ); njPtclDrawSprite( ptcl, 100, 10,f, 10,f ); njRotateXYZ( NULL, 0x1000, 0x1000, 0x1000 ); njPtclDrawSprite( ptcl, 100, 10,f, 10,f ); njPtclSpriteEnd();
njPtclSpriteEnd() パーティクルスプライトの描画の終了 njPtclDrawSprite() パーティクルスプライトの描画