Hi all
i was trying to control the cooking of my C++CHOP.
I made a similar CHOP as the LAG CHOP and i wanted my CHOP to stop cooking when it reaches the target value.
I found 2 member variables :
[code]// Set this to true if you want the CHOP to cook every frame, even
// if none of it’s inputs/parameters are changing
// DEFAULT: false
bool cookEveryFrame;
// Set this to true if you want the CHOP to cook every frame, but only
// if someone asks for it to cook. So if nobody is using the output from
// the CHOP, it won't cook. This is difereent from 'cookEveryFrame'
// since that will cause it to cook every frame no matter what.
bool cookEveryFrameIfAsked;[/code]
Explanation of variables are quite clear, but it seems it do not work as i expect.
I tested :
ginfo->cookEveryFrame = false;
ginfo->cookEveryFrameIfAsked = true;
it cooks all the time what ever is connected to output or not
ginfo->cookEveryFrame = false;
ginfo->cookEveryFrameIfAsked = false;
it cooks only when input changes
ginfo->cookEveryFrame = true;
ginfo->cookEveryFrameIfAsked = false;
it cooks all the time what ever is connected to output or not
ginfo->cookEveryFrame = false;
ginfo->cookEveryFrameIfAsked = false;
it cooks only when input changes.
I tryed to keep reference to the Ginfo pointer and set thoes variable in the execute function, but it has no effect. I guess those are changeable only at init.
So is there a way to control cooking ?
Thanks