Interacting with the ISFScene
Internally, VVISF::ISFScene uses VVISF::ISFDoc to represent the value and state of an ISF file during rendering. This means that you can get an ISFScene's currently-used ISFDoc, and adjust rendering parameters by getting the appropriate attribute from the doc and changing its value.
if (tmpDoc == nullptr)
return;
ISFAttrRef floatAttr = tmpDoc->input(
string(
"floatInputName"));
return;
ISFVal currentVal = floatAttr->currentVal();
ISFVal minVal = floatAttr->minVal();
ISFVal maxVal = floatAttr->maxVal();
double tmpVal = currentVal.getDoubleVal();
tmpVal += 0.01;
if (!maxVal.isNullVal() && tmpVal > maxVal.getDoubleVal()) {
if (!minVal.isNullVal())
tmpVal = minVal.getDoubleVal();
else
tmpVal = 0.;
}
floatAttr->setCurrentVal(currentVal);