32 myUseInputWhenEmpty =
false;
33 myStashFile =
""_UTsh;
34 raw_myStashFile =
""_UTsh;
47 if (myStash != src.myStash)
49 if (myUseInputWhenEmpty != src.myUseInputWhenEmpty)
return false;
50 if (myStashFile != src.myStashFile)
return false;
51 if (raw_myStashFile != src.raw_myStashFile)
return false;
70 myUseInputWhenEmpty =
false;
72 graph->
evalOpParm(myUseInputWhenEmpty, nodeidx,
"useinputwhenempty", time, graph->
isDirect()?
nullptr:depnode);
73 myStashFile =
""_UTsh;
74 if (
true && ( (
true&&!(((getUseInputWhenEmpty()!=0)))) ) )
75 graph->
evalOpParm(myStashFile, nodeidx,
"stashfile", time, graph->
isDirect()?
nullptr:depnode);
76 raw_myStashFile =
""_UTsh;
77 if (
true && ( (
true&&!(((getUseInputWhenEmpty()!=0)))) ) )
101 if (idx.
size() != instance.
size()+1)
128 { doGetParmValue(idx, instance, value); }
130 { doGetParmValue(idx, instance, value); }
132 { doGetParmValue(idx, instance, value); }
134 { doGetParmValue(idx, instance, value); }
136 { doGetParmValue(idx, instance, value); }
138 { doGetParmValue(idx, instance, value); }
140 { doGetParmValue(idx, instance, value); }
142 { doGetParmValue(idx, instance, value); }
144 { doGetParmValue(idx, instance, value); }
146 { doGetParmValue(idx, instance, value); }
148 { doGetParmValue(idx, instance, value); }
150 template <
typename T>
157 if (idx.
size() != instance.
size()+1)
175 { doSetParmValue(idx, instance, value); }
177 { doSetParmValue(idx, instance, value); }
179 { doSetParmValue(idx, instance, value); }
181 { doSetParmValue(idx, instance, value); }
183 { doSetParmValue(idx, instance, value); }
185 { doSetParmValue(idx, instance, value); }
187 { doSetParmValue(idx, instance, value); }
189 { doSetParmValue(idx, instance, value); }
191 { doSetParmValue(idx, instance, value); }
193 { doSetParmValue(idx, instance, value); }
195 { doSetParmValue(idx, instance, value); }
211 if (fieldnum.
size() < 1)
218 return "useinputwhenempty";
228 if (fieldnum.
size() < 1)
229 return PARM_UNSUPPORTED;
276 loadData(is, rampdata);
294 int typelen = colon - data.
buffer();
308 {
int64 iv =
v; UTwrite(os, &iv); }
310 { UTwrite<fpreal64>(os, &
v); }
312 { UTwrite<fpreal64>(os, &v.
x()); UTwrite<fpreal64>(os, &v.
y()); }
314 { UTwrite<fpreal64>(os, &v.
x()); UTwrite<fpreal64>(os, &v.
y());
315 UTwrite<fpreal64>(os, &v.
z()); }
317 { UTwrite<fpreal64>(os, &v.
x()); UTwrite<fpreal64>(os, &v.
y());
318 UTwrite<fpreal64>(os, &v.
z()); UTwrite<fpreal64>(os, &v.
w()); }
330 if (s) s->save(ostr);
332 saveData(os, result);
339 ostr << s->getDataTypeToken();
344 saveData(os, result);
348 void save(std::ostream &os)
const
352 saveData(os, myStash);
353 saveData(os, myUseInputWhenEmpty);
354 saveData(os, myStashFile);
355 saveData(os, raw_myStashFile);
368 loadData(is, myStash);
369 loadData(is, myUseInputWhenEmpty);
370 loadData(is, myStashFile);
371 loadData(is, raw_myStashFile);
381 if (!thissop)
return getStash();
383 OP_Utils::evalOpParm(result, thissop,
"stash", cookparms.
getCookTime(), 0);
391 if (!thissop)
return getUseInputWhenEmpty();
393 OP_Utils::evalOpParm(result, thissop,
"useinputwhenempty", cookparms.
getCookTime(), 0);
401 if (!thissop)
return getStashFile();
403 OP_Utils::evalOpParm(result, thissop,
"stashfile", cookparms.
getCookTime(), 0);
411 if (!thissop)
return raw_getStashFile();
413 OP_Utils::evalOpParmRaw(result, thissop,
"stashfile", cookparms.
getCookTime(), 0);
419 bool myUseInputWhenEmpty;
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
static void saveData(std::ostream &os, int64 v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
void setUseInputWhenEmpty(bool val)
static void loadData(UT_IStream &is, UT_Vector4I &v)
static void loadData(UT_IStream &is, fpreal64 &v)
static void saveData(std::ostream &os, fpreal64 v)
static void saveData(std::ostream &os, UT_Matrix4D v)
SOP_Node * getNode() const
static void saveData(std::ostream &os, UT_Vector2D v)
static void loadData(UT_IStream &is, UT_Vector2I &v)
GT_API const UT_StringHolder time
constexpr SYS_FORCE_INLINE T & y() noexcept
UT_StringHolder raw_opStashFile(const SOP_NodeVerb::CookParms &cookparms) const
const char * getNestParmName(TempIndex fieldnum) const override
GLsizei const GLfloat * value
bool operator!=(const SOP_StashParms &src) const
PRM_DataItemHandle getStash() const
const OP_Context & context() const
virtual void evalOpParmRaw(UT_StringHolder &v, NodeIdx node, const char *parmname, fpreal time, DEP_MicroNode *depnode) const =0
constexpr SYS_FORCE_INLINE T & z() noexcept
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
SYS_FORCE_INLINE const char * buffer() const
void setStashFile(const UT_StringHolder &val)
An output stream object that owns its own string buffer storage.
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
void loadFromOpSubclass(const LoadParms &loadparms) override
void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr< UT_Ramp > &value) override
static void saveData(std::ostream &os, UT_Vector4D v)
**But if you need a result
static void loadData(UT_IStream &is, int64 &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
const UT_WorkBuffer & str()
Returns a read-only reference to the underlying UT_WorkBuffer.
constexpr SYS_FORCE_INLINE T & x() noexcept
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
const UT_StringHolder & raw_getStashFile() const
void buildFromOp(const OP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
void save(std::ostream &os) const
bool opUseInputWhenEmpty(const SOP_NodeVerb::CookParms &cookparms) const
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
constexpr SYS_FORCE_INLINE T & x() noexcept
bool getUseInputWhenEmpty() const
exint getNestNumParms(TempIndex idx) const override
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
static void loadData(UT_IStream &is, UT_Vector3D &v)
static void saveData(std::ostream &os, UT_Matrix3D v)
PRM_DataItemHandle opStash(const SOP_NodeVerb::CookParms &cookparms) const
bool operator==(const SOP_StashParms &src) const
static void saveData(std::ostream &os, bool v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
SYS_FORCE_INLINE const char * buffer() const
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
constexpr SYS_FORCE_INLINE T & z() noexcept
void raw_setStashFile(const UT_StringHolder &val)
void doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
const OP_GraphProxy * graph() const
static void loadData(UT_IStream &is, UT_Vector2D &v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
static void saveData(std::ostream &os, PRM_DataItemHandle s)
bool isParmColorRamp(exint idx) const override
void copyFrom(const OP_NodeParms *src) override
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
static void saveData(std::ostream &os, UT_Vector3D v)
void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
static void loadData(UT_IStream &is, UT_Matrix2D &v)
virtual void evalOpParm(int64 &v, NodeIdx node, const char *parmname, fpreal time, DEP_MicroNode *depnode) const =0
void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr< UT_Ramp > &value) const override
void saveBinary(std::ostream &os) const
Save string to binary stream.
GT_API const UT_StringHolder version
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
ParmType getNestParmType(TempIndex fieldnum) const override
void coerceValue(T &result, const S &src) const
void setStash(PRM_DataItemHandle val)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
static void loadData(UT_IStream &is, UT_Vector4D &v)
DEP_MicroNode * depnode() const
static void loadData(UT_IStream &is, bool &v)
Utility class for containing a color ramp.
constexpr SYS_FORCE_INLINE T & w() noexcept
virtual UT_StringHolder baseGetSignature() const
static void loadData(UT_IStream &is, UT_Vector3I &v)
static void loadData(UT_IStream &is, UT_Matrix4D &v)
static void loadData(UT_IStream &is, UT_StringHolder &v)
fpreal getCookTime() const
const char * findChar(int c) const
exint bread(uint8 *buffer, exint asize=1)
void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
static void saveData(std::ostream &os, UT_StringHolder s)
void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
constexpr SYS_FORCE_INLINE T & y() noexcept
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
static void loadData(UT_IStream &is, UT_Matrix3D &v)
UT_StringHolder opStashFile(const SOP_NodeVerb::CookParms &cookparms) const
void doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
virtual bool isDirect() const =0
Direct proxies mirror actual nodes:
const UT_StringHolder & getStashFile() const
bool load(UT_IStream &is)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
constexpr SYS_FORCE_INLINE T & y() noexcept
SYS_FORCE_INLINE bool isstring() const
OP_NodeParms & operator=(const OP_NodeParms &)=default
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
static void saveData(std::ostream &os, UT_Matrix2D v)
constexpr SYS_FORCE_INLINE T & x() noexcept