How To Use Callbacks

Sometimes you may want to be able to call a script class method from the c++ application without knowing the name of its script defined class type. To help with that you can use the object type as parameter. It works as a placeholder for any type. Then you can use the helper class owlsl::callback to hold a reference to a script object instance and the method you want to call.