28 return _current_thread;
45 return _has_tag_state_key;
54 return _tag_state_key;
62 return _scene_setup->get_camera_transform();
76 return _scene_setup->get_world_transform();
85 return _initial_state;
105 _camera_mask = camera_mask;
122 _view_frustum = view_frustum;
136 return _view_frustum;
145 _cull_handler = cull_handler;
153 return _cull_handler;
161 _portal_clipper = portal_clipper;
169 return _portal_clipper;
181 return _effective_incomplete_render;
189 _nodes_pcollector.flush_level();
190 _geom_nodes_pcollector.flush_level();
191 _geoms_pcollector.flush_level();
192 _geoms_occluded_pcollector.flush_level();
198 INLINE
void CullTraverser::
200 if (is_in_view(data)) {
201 if (pgraph_cat.is_spam()) {
203 <<
"\n" << data.get_node_path()
204 <<
" " << data._draw_mask <<
"\n";
210 if (fancy_bits == 0 && data._cull_planes->is_empty()) {
222 data.apply_transform_and_state(
this);
225 node_reader->
get_state()->get_attrib(FogAttrib::get_class_slot());
227 if (fog !=
nullptr && fog->
get_fog() !=
nullptr) {
235 if (fancy_bits & PandaNode::FB_cull_callback) {
237 if (!node->cull_callback(
this, data)) {
A basic node of the scene graph or data graph.
bool has_tag_state_key() const
Returns true if a nonempty tag state key has been specified for the scene's camera,...
void set_camera_mask(const DrawMask &camera_mask)
Changes the visibility mask for the camera viewing the scene.
CullHandler * get_cull_handler() const
Returns the object that will receive the culled Geoms.
const TransformState * get_camera_transform() const
Returns the position of the camera relative to the starting node.
static void flush_level()
Flushes the PStatCollectors used during traversal.
const RenderEffects * get_effects() const
Returns the complete RenderEffects that will be applied to this node.
virtual void traverse_below(CullTraverserData &data)
Traverses all the children of the indicated node, with the given data, which has been converted into ...
Thread * get_current_thread() const
Returns the currently-executing thread object, as passed to the CullTraverser constructor.
const RenderState * get_state() const
Returns the complete RenderState that will be applied to all nodes at this level and below,...
get_fog
If the FogAttrib is not an 'off' FogAttrib, returns the fog that is associated.
This collects together the pieces of data that are accumulated for each node while walking the scene ...
Applies a Fog to the geometry at and below this node.
PortalClipper * get_portal_clipper() const
Returns the _portal_clipper pointer.
bool get_effective_incomplete_render() const
Returns true if the cull traversal is effectively in incomplete_render state, considering both the GS...
This is another abstract class, for a general class of bounding volumes that actually enclose points ...
void set_portal_clipper(PortalClipper *portal_clipper)
Specifies _portal_clipper object pointer that subsequent traverse() or traverse_below may use.
bool has_show_bounds() const
This function is provided as an optimization, to speed up the render-time checking for the existance ...
const std::string & get_tag_state_key() const
Returns the tag state key that has been specified for the scene's camera, if any.
bool get_depth_offset_decals() const
Returns true, as depth offsets are the only way that we implement decals nowadays.
This defines the abstract interface for an object that receives Geoms identified by the CullTraverser...
This object performs a depth-first traversal of the scene graph, with optional view-frustum culling,...
void set_view_frustum(GeometricBoundingVolume *view_frustum)
Specifies the bounding volume that corresponds to the view frustum.
const TransformState * get_world_transform() const
Returns the position of the starting node relative to the camera.
GraphicsStateGuardianBase * get_gsg() const
Returns the GraphicsStateGuardian in effect.
This represents a unique collection of RenderAttrib objects that correspond to a particular renderabl...
This is a base class for the GraphicsStateGuardian class, which is itself a base class for the variou...
A thread; that is, a lightweight process.
const RenderState * get_initial_state() const
Returns the initial RenderState at the top of the scene graph we are traversing, or the empty state i...
GeometricBoundingVolume * get_view_frustum() const
Returns the bounding volume that corresponds to the view frustum, or NULL if the view frustum is not ...
Encapsulates the data from a PandaNode, pre-fetched for one stage of the pipeline.
int get_fancy_bits() const
Returns the union of all of the enum FancyBits values corresponding to the various "fancy" attributes...
SceneSetup * get_scene() const
Returns the SceneSetup object.
const DrawMask & get_camera_mask() const
Returns the visibility mask from the camera viewing the scene.
This object holds the camera position, etc., and other general setup information for rendering a part...
This represents a unique collection of RenderEffect objects that correspond to a particular renderabl...
bool has_show_tight_bounds() const
If has_show_bounds() returns true, this will return true if the ShowBoundsEffect in question requests...
void set_cull_handler(CullHandler *cull_handler)
Specifies the object that will receive the culled Geoms.