I’m writing a custom CHOP C++ operator and I’d like to expose a few custom internal values (strings or numbers) from the CHOP so they can be displayed in an Info DAT connected to that CHOP.
For example: internal state, identifiers, counters, or metadata held by the CHOP instance.
Is this possible from a CHOP C++ operator?
If yes, which methods should be implemented?
Or is the Info DAT for a CHOP limited to built-in TouchDesigner info only?
Yes all C++ nodes support writing data to Info DAT and Info CHOP.
Both have seperate methods to configure how much data is written, and another method to set the actual data.
All documentation is in the base header file (in that file do a find for “Info DAT”), but to write to an Info DAT you’ll need to override getInfoDATSize and getInfoDATEntries.
Worked smoothly !
Thanks.
Next step, how to get the node instance name + TD project opened (file) from with a Custom Op… Will also check headers and not only docs etc as you mentioned
great! I’m not sure if TD project name is available in the C++ SDK, but else you can always add a custom parameter to your C++ node with project.name as the expression value.