1
0

Merging r6426 through r6466 from trunk to ogl-es branch

Note: Updated IShaderConstantSetCallBack not yet supported by ogl-es drivers


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/branches/ogl-es@6467 dfc29bdd-3216-0410-991c-e03cc46cb475
This commit is contained in:
cutealien
2023-04-22 21:50:32 +00:00
parent e184e4aedb
commit 621bad3111
118 changed files with 12767 additions and 444 deletions

View File

@@ -143,7 +143,7 @@ void CBillboardSceneNode::updateMesh(const irr::scene::ICameraSceneNode* camera)
//! returns the axis aligned bounding box of this node
const core::aabbox3d<f32>& CBillboardSceneNode::getBoundingBox() const
{
// Really wrong when scaled.
// Really wrong when scaled (as the node does not scale it's vertices - maybe it should?)
return BBoxSafe;
}
@@ -164,9 +164,9 @@ void CBillboardSceneNode::setSize(const core::dimension2d<f32>& size)
if (core::equals(Size.Height, 0.0f))
Size.Height = 1.0f;
const f32 avg = (Size.Width + Size.Height)/6;
BBoxSafe.MinEdge.set(-avg,-avg,-avg);
BBoxSafe.MaxEdge.set(avg,avg,avg);
const f32 extent = 0.5f*sqrtf(Size.Width*Size.Width + Size.Height*Size.Height);
BBoxSafe.MinEdge.set(-extent,-extent,-extent);
BBoxSafe.MaxEdge.set(extent,extent,extent);
}
@@ -184,9 +184,9 @@ void CBillboardSceneNode::setSize(f32 height, f32 bottomEdgeWidth, f32 topEdgeWi
TopEdgeWidth = 1.0f;
}
const f32 avg = (core::max_(Size.Width,TopEdgeWidth) + Size.Height)/6;
BBoxSafe.MinEdge.set(-avg,-avg,-avg);
BBoxSafe.MaxEdge.set(avg,avg,avg);
const f32 extent = 0.5f*sqrtf(Size.Width*Size.Width + Size.Height*Size.Height);
BBoxSafe.MinEdge.set(-extent,-extent,-extent);
BBoxSafe.MaxEdge.set(extent,extent,extent);
}