Fixed bug 3017433, billboard text node should generate stuff in OnAnimate, not OnRegisterSceneNode
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@3591 dfc29bdd-3216-0410-991c-e03cc46cb475master
parent
62c41e4d3e
commit
128d1e8fe8
|
@ -236,7 +236,7 @@ void CBillboardTextSceneNode::setText(const wchar_t* text)
|
|||
|
||||
|
||||
//! pre render event
|
||||
void CBillboardTextSceneNode::OnRegisterSceneNode()
|
||||
void CBillboardTextSceneNode::OnAnimate(u32 timeMs)
|
||||
{
|
||||
if (!IsVisible || !Font || !Mesh)
|
||||
return;
|
||||
|
@ -319,7 +319,10 @@ void CBillboardTextSceneNode::OnRegisterSceneNode()
|
|||
BBox = Mesh->getBoundingBox();
|
||||
core::matrix4 mat( getAbsoluteTransformation(), core::matrix4::EM4CONST_INVERSE );
|
||||
mat.transformBoxEx(BBox);
|
||||
}
|
||||
|
||||
void CBillboardTextSceneNode::OnRegisterSceneNode()
|
||||
{
|
||||
SceneManager->registerNodeForRendering(this, ESNRP_TRANSPARENT);
|
||||
ISceneNode::OnRegisterSceneNode();
|
||||
}
|
||||
|
|
|
@ -69,6 +69,10 @@ namespace scene
|
|||
//! destructor
|
||||
virtual ~CBillboardTextSceneNode();
|
||||
|
||||
//! sets the vertex positions etc
|
||||
virtual void OnAnimate(u32 timeMs);
|
||||
|
||||
//! registers the node into the transparent pass
|
||||
virtual void OnRegisterSceneNode();
|
||||
|
||||
//! renders the node.
|
||||
|
|
Loading…
Reference in New Issue