26class EXPCL_PANDA_PGRAPHNODES CallbackNode :
public PandaNode {
28 explicit CallbackNode(
const std::string &name);
41 CallbackNode(
const CallbackNode ©);
50 virtual void output(std::ostream &out)
const;
53 class EXPCL_PANDA_PGRAPHNODES CData :
public CycleData {
56 INLINE CData(
const CData ©);
61 return CallbackNode::get_class_type();
68 PipelineCycler<CData> _cycler;
69 typedef CycleDataReader<CData> CDReader;
70 typedef CycleDataWriter<CData> CDWriter;
77 static TypedWritable *make_from_bam(
const FactoryParams ¶ms);
78 void fillin(DatagramIterator &scan, BamReader *manager);
81 static TypeHandle get_class_type() {
84 static void init_type() {
85 PandaNode::init_type();
87 PandaNode::get_class_type());
89 virtual TypeHandle get_type()
const {
90 return get_class_type();
92 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
95 static TypeHandle _type_handle;
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
This is the fundamental interface for extracting binary objects from a Bam file, as generated by a Ba...
get_cull_callback
Returns the CallbackObject set by set_cull_callback().
get_draw_callback
Returns the CallbackObject set by set_draw_callback().
set_cull_callback
Sets the CallbackObject that will be notified when this node is visited during the cull traversal.
void clear_draw_callback()
Removes the callback set by an earlier call to set_draw_callback().
set_draw_callback
Sets the CallbackObject that will be notified when this node is visited during the draw traversal.
virtual bool cull_callback(CullTraverser *trav, CullTraverserData &data)
This function will be called during the cull traversal to perform any additional operations that shou...
virtual void output(std::ostream &out) const
Writes a brief description of the node to the indicated output stream.
void clear_cull_callback()
Removes the callback set by an earlier call to set_cull_callback().
This is a generic object that can be assigned to a callback at various points in the rendering proces...
This object performs a depth-first traversal of the scene graph, with optional view-frustum culling,...
A single page of data maintained by a PipelineCycler.
A class to retrieve the individual data elements previously stored in a Datagram.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
virtual bool cull_callback(CullTraverser *trav, CullTraverserData &data)
This function will be called during the cull traversal to perform any additional operations that shou...
virtual bool safe_to_combine() const
Returns true if it is generally safe to combine this particular kind of PandaNode with other kinds of...
virtual bool is_renderable() const
Returns true if there is some value to visiting this particular node during the cull traversal for an...
static void register_with_read_factory()
Tells the BamReader how to create objects of type PandaNode.
virtual PandaNode * make_copy() const
Returns a newly-allocated PandaNode that is a shallow copy of this one.
virtual void add_for_draw(CullTraverser *trav, CullTraverserData &data)
Adds the node's contents to the CullResult we are building up during the cull traversal,...
virtual void write_datagram(BamWriter *manager, Datagram &dg)
Writes the contents of this object to the datagram for shipping out to a Bam file.
TypeHandle is the identifier used to differentiate C++ class types.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...