I'm looking for a way to know if a bounding box is inside the camera view frustrum.
I've seen in the doc that there's the SViewFrustrum class, but, i don't think i must use it because on each frame irrlicht ALREADY calculates if the bounding box is inside the ViewFrustrum.
Does anyone has a suggestion ? Am i wrong ? What should i do ?
ICameraSceneNode* camera=SceneManager->getActiveCamera();
const SViewFrustrum* vfr=camera->getViewFrustrum();
if(vfr->getBoundingBox().intersectsWithBox(theBox)){
// do some usefull things
}
this gets the current camera, and checks the viewfrustrums bounding box against your box, I'm not shure if there is also a method which checks if
the box is completely inside? but this should get you startet anyway.