Fix warning

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6434 dfc29bdd-3216-0410-991c-e03cc46cb475
This commit is contained in:
cutealien 2022-10-04 12:32:27 +00:00
parent 51f1ff6716
commit 41f2f8654f

View File

@ -164,7 +164,7 @@ void CBillboardSceneNode::setSize(const core::dimension2d<f32>& size)
if (core::equals(Size.Height, 0.0f)) if (core::equals(Size.Height, 0.0f))
Size.Height = 1.0f; Size.Height = 1.0f;
const f32 extent = 0.5f*sqrt(Size.Width*Size.Width + Size.Height*Size.Height); const f32 extent = 0.5f*sqrtf(Size.Width*Size.Width + Size.Height*Size.Height);
BBoxSafe.MinEdge.set(-extent,-extent,-extent); BBoxSafe.MinEdge.set(-extent,-extent,-extent);
BBoxSafe.MaxEdge.set(extent,extent,extent); BBoxSafe.MaxEdge.set(extent,extent,extent);
} }
@ -184,7 +184,7 @@ void CBillboardSceneNode::setSize(f32 height, f32 bottomEdgeWidth, f32 topEdgeWi
TopEdgeWidth = 1.0f; TopEdgeWidth = 1.0f;
} }
const f32 extent = 0.5f*sqrt(Size.Width*Size.Width + Size.Height*Size.Height); const f32 extent = 0.5f*sqrtf(Size.Width*Size.Width + Size.Height*Size.Height);
BBoxSafe.MinEdge.set(-extent,-extent,-extent); BBoxSafe.MinEdge.set(-extent,-extent,-extent);
BBoxSafe.MaxEdge.set(extent,extent,extent); BBoxSafe.MaxEdge.set(extent,extent,extent);
} }