Camera getCullingFrustum() returns 0

Problems building or running the engine, queries about how to use features etc.
Post Reply
white_waluigi
Goblin
Posts: 253
Joined: Sat Sep 28, 2013 3:46 pm
x 10

Camera getCullingFrustum() returns 0

Post by white_waluigi »

I need the Frustumj of a Camera return as an Ogre::frustum, but it just returns 0, even though tzhe camera is initialised.
Is therer another way to get the the Frustum of a Camera?
User avatar
Kojack
OGRE Moderator
OGRE Moderator
Posts: 7157
Joined: Sun Jan 25, 2004 7:35 am
Location: Brisbane, Australia
x 534

Re: Camera getCullingFrustum() returns 0

Post by Kojack »

Camera inherits from Frustum. You can either use the camera directly or cast it's pointer to a frustum pointer.

getCullingFrustum() actually returns a custom culling frustum that you have to first set manually using setCullingFrustum(). It's an alternative frustum to cull against instead of the camera's own frustum.
white_waluigi
Goblin
Posts: 253
Joined: Sat Sep 28, 2013 3:46 pm
x 10

Re: Camera getCullingFrustum() returns 0

Post by white_waluigi »

Thx, worked.
Maybe rename the funciton to getCustomCullingFrustum to avoid future confusion?
Post Reply