A couple more things.
1. What you want to do is use the function in the above code for determining if a sphere that encloses your object is in the frustum. It's up to to you calculate this sphere. I just figure out the smallest box that will enclose the entity, an then make a sphere with a radius from the center of the box to the corner of the box so the sphere encloses the box.
2. I make no guarantees that trying to cull objects like this will be any faster than just letting Blitz do the job.
But I have known Blitz to fail to cull objects that are outside the camera view and cause slowdown as a result, such as when bulding a starfield for a 2D style shooter with a bunch of entities in a grid.
1. What you want to do is use the function in the above code for determining if a sphere that encloses your object is in the frustum. It's up to to you calculate this sphere. I just figure out the smallest box that will enclose the entity, an then make a sphere with a radius from the center of the box to the corner of the box so the sphere encloses the box.
2. I make no guarantees that trying to cull objects like this will be any faster than just letting Blitz do the job.
But I have known Blitz to fail to cull objects that are outside the camera view and cause slowdown as a result, such as when bulding a starfield for a 2D style shooter with a bunch of entities in a grid.