15 #ifndef PYTHONCALLBACKOBJECT_H
16 #define PYTHONCALLBACKOBJECT_H
18 #include "pandabase.h"
23 #include "callbackObject.h"
33 PythonCallbackObject(PyObject *
function = Py_None);
34 virtual ~PythonCallbackObject();
35 ALLOC_DELETED_CHAIN(PythonCallbackObject);
37 void set_function(PyObject *
function);
38 PyObject *get_function();
52 static void init_type() {
53 CallbackObject::init_type();
54 register_type(_type_handle,
"PythonCallbackObject",
55 CallbackObject::get_class_type());
58 return get_class_type();
60 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
66 #include "pythonCallbackObject.I"
This is a generic data block that is passed along to a CallbackObject when a callback is made...
virtual void do_callback(CallbackData *cbdata)
This method called when the callback is triggered; it replaces* the original function.
This is a generic object that can be assigned to a callback at various points in the rendering proces...
TypeHandle is the identifier used to differentiate C++ class types.