20 using namespace UT::Literal;
36 myInputnumattrib =
"sourceinput"_sh;
37 myPrimnumattrib =
"sourceprim"_sh;
38 myPrimuvwattrib =
"sourceprimuv"_sh;
39 myKeeppointattribs =
true;
49 if (myAgroup != src.myAgroup)
return false;
50 if (myBgroup != src.myBgroup)
return false;
51 if (myUseproxtol != src.myUseproxtol)
return false;
52 if (myProxtol != src.myProxtol)
return false;
53 if (mySplitcurves != src.mySplitcurves)
return false;
54 if (myInputnumattrib != src.myInputnumattrib)
return false;
55 if (myPrimnumattrib != src.myPrimnumattrib)
return false;
56 if (myPrimuvwattrib != src.myPrimuvwattrib)
return false;
57 if (myKeeppointattribs != src.myKeeppointattribs)
return false;
72 graph->
evalOpParm(myAgroup, nodeidx,
"agroup", time, 0);
75 graph->
evalOpParm(myBgroup, nodeidx,
"bgroup", time, 0);
78 graph->
evalOpParm(myUseproxtol, nodeidx,
"useproxtol", time, 0);
80 if (
true && ( (!(((getUseproxtol()==0)))) ) )
81 graph->
evalOpParm(myProxtol, nodeidx,
"proxtol", time, 0);
84 graph->
evalOpParm(mySplitcurves, nodeidx,
"splitcurves", time, 0);
85 myInputnumattrib =
"sourceinput"_sh;
86 if (
true && ( (!((((graph->
getInput(nodeidx,2)>=0)==0)))) ) )
87 graph->
evalOpParm(myInputnumattrib, nodeidx,
"inputnumattrib", time, 0);
88 myPrimnumattrib =
"sourceprim"_sh;
89 if (
true && ( (!((((graph->
getInput(nodeidx,2)>=0)==0)))) ) )
90 graph->
evalOpParm(myPrimnumattrib, nodeidx,
"primnumattrib", time, 0);
91 myPrimuvwattrib =
"sourceprimuv"_sh;
92 if (
true && ( (!((((graph->
getInput(nodeidx,2)>=0)==0)))) ) )
93 graph->
evalOpParm(myPrimuvwattrib, nodeidx,
"primuvwattrib", time, 0);
94 myKeeppointattribs =
true;
95 if (
true && ( (!((((graph->
getInput(nodeidx,2)>=0)==0)))) ) )
96 graph->
evalOpParm(myKeeppointattribs, nodeidx,
"keeppointattribs", time, 0);
112 template <
typename T>
119 if (idx.
size() != instance.
size()+1)
124 coerceValue(value, myAgroup);
127 coerceValue(value, myBgroup);
130 coerceValue(value, myUseproxtol);
133 coerceValue(value, myProxtol);
136 coerceValue(value, mySplitcurves);
139 coerceValue(value, myInputnumattrib);
142 coerceValue(value, myPrimnumattrib);
145 coerceValue(value, myPrimuvwattrib);
148 coerceValue(value, myKeeppointattribs);
155 { doGetParmValue(idx, instance, value); }
157 { doGetParmValue(idx, instance, value); }
159 { doGetParmValue(idx, instance, value); }
161 { doGetParmValue(idx, instance, value); }
163 { doGetParmValue(idx, instance, value); }
165 { doGetParmValue(idx, instance, value); }
167 { doGetParmValue(idx, instance, value); }
169 { doGetParmValue(idx, instance, value); }
171 { doGetParmValue(idx, instance, value); }
173 { doGetParmValue(idx, instance, value); }
175 { doGetParmValue(idx, instance, value); }
177 template <
typename T>
184 if (idx.
size() != instance.
size()+1)
189 coerceValue(myAgroup, value);
192 coerceValue(myBgroup, value);
195 coerceValue(myUseproxtol, value);
198 coerceValue(myProxtol, value);
201 coerceValue(mySplitcurves, value);
204 coerceValue(myInputnumattrib, value);
207 coerceValue(myPrimnumattrib, value);
210 coerceValue(myPrimuvwattrib, value);
213 coerceValue(myKeeppointattribs, value);
220 { doSetParmValue(idx, instance, value); }
222 { doSetParmValue(idx, instance, value); }
224 { doSetParmValue(idx, instance, value); }
226 { doSetParmValue(idx, instance, value); }
228 { doSetParmValue(idx, instance, value); }
230 { doSetParmValue(idx, instance, value); }
232 { doSetParmValue(idx, instance, value); }
234 { doSetParmValue(idx, instance, value); }
236 { doSetParmValue(idx, instance, value); }
238 { doSetParmValue(idx, instance, value); }
240 { doSetParmValue(idx, instance, value); }
256 if (fieldnum.
size() < 1)
269 return "splitcurves";
271 return "inputnumattrib";
273 return "primnumattrib";
275 return "primuvwattrib";
277 return "keeppointattribs";
285 if (fieldnum.
size() < 1)
286 return PARM_UNSUPPORTED;
309 return PARM_UNSUPPORTED;
345 loadData(is, rampdata);
363 int typelen = colon - data.
buffer();
377 {
int64 iv =
v; UTwrite(os, &iv); }
379 { UTwrite<fpreal64>(os, &
v); }
381 { UTwrite<fpreal64>(os, &v.
x()); UTwrite<fpreal64>(os, &v.
y()); }
383 { UTwrite<fpreal64>(os, &v.
x()); UTwrite<fpreal64>(os, &v.
y());
384 UTwrite<fpreal64>(os, &v.
z()); }
386 { UTwrite<fpreal64>(os, &v.
x()); UTwrite<fpreal64>(os, &v.
y());
387 UTwrite<fpreal64>(os, &v.
z()); UTwrite<fpreal64>(os, &v.
w()); }
399 if (s) s->save(ostr);
401 saveData(os, result);
408 ostr << s->getDataTypeToken();
413 saveData(os, result);
417 void save(std::ostream &os)
const
421 saveData(os, myAgroup);
422 saveData(os, myBgroup);
423 saveData(os, myUseproxtol);
424 saveData(os, myProxtol);
425 saveData(os, mySplitcurves);
426 saveData(os, myInputnumattrib);
427 saveData(os, myPrimnumattrib);
428 saveData(os, myPrimuvwattrib);
429 saveData(os, myKeeppointattribs);
442 loadData(is, myAgroup);
443 loadData(is, myBgroup);
444 loadData(is, myUseproxtol);
445 loadData(is, myProxtol);
446 loadData(is, mySplitcurves);
447 loadData(is, myInputnumattrib);
448 loadData(is, myPrimnumattrib);
449 loadData(is, myPrimuvwattrib);
450 loadData(is, myKeeppointattribs);
460 if (!thissop)
return getAgroup();
462 OP_Utils::evalOpParm(result, thissop,
"agroup", cookparms.
getCookTime(), 0);
470 if (!thissop)
return getBgroup();
472 OP_Utils::evalOpParm(result, thissop,
"bgroup", cookparms.
getCookTime(), 0);
480 if (!thissop)
return getUseproxtol();
482 OP_Utils::evalOpParm(result, thissop,
"useproxtol", cookparms.
getCookTime(), 0);
490 if (!thissop)
return getProxtol();
492 OP_Utils::evalOpParm(result, thissop,
"proxtol", cookparms.
getCookTime(), 0);
500 if (!thissop)
return getSplitcurves();
502 OP_Utils::evalOpParm(result, thissop,
"splitcurves", cookparms.
getCookTime(), 0);
510 if (!thissop)
return getInputnumattrib();
512 OP_Utils::evalOpParm(result, thissop,
"inputnumattrib", cookparms.
getCookTime(), 0);
520 if (!thissop)
return getPrimnumattrib();
522 OP_Utils::evalOpParm(result, thissop,
"primnumattrib", cookparms.
getCookTime(), 0);
530 if (!thissop)
return getPrimuvwattrib();
532 OP_Utils::evalOpParm(result, thissop,
"primuvwattrib", cookparms.
getCookTime(), 0);
540 if (!thissop)
return getKeeppointattribs();
542 OP_Utils::evalOpParm(result, thissop,
"keeppointattribs", cookparms.
getCookTime(), 0);
555 bool myKeeppointattribs;
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
void setPrimuvwattrib(const UT_StringHolder &val)
bool getKeeppointattribs() const
static void saveData(std::ostream &os, UT_Vector4D v)
static void saveData(std::ostream &os, UT_Matrix4D v)
UT_StringHolder opAgroup(const SOP_NodeVerb::CookParms &cookparms) const
SOP_Node * getNode() const
static void saveData(std::ostream &os, UT_Matrix2D v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
static void saveData(std::ostream &os, PRM_DataItemHandle s)
static void saveData(std::ostream &os, UT_Vector2D v)
virtual NodeIdx getInput(NodeIdx idx, int input, bool markused=false) const =0
exint bread(int32 *buffer, exint asize=1)
const UT_StringHolder & getPrimnumattrib() const
GT_API const UT_StringHolder time
void doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
GLuint const GLfloat * val
static void loadData(UT_IStream &is, UT_Vector4D &v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
const UT_StringHolder & getInputnumattrib() const
SYS_FORCE_INLINE const char * buffer() const
const SOP_GraphProxy * graph() const
void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
An output stream object that owns its own string buffer storage.
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr< UT_Ramp > &value) override
bool opSplitcurves(const SOP_NodeVerb::CookParms &cookparms) const
const char * getNestParmName(TempIndex fieldnum) const override
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
const UT_WorkBuffer & str()
Returns a read-only reference to the underlying UT_WorkBuffer.
static void loadData(UT_IStream &is, int64 &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
static void loadData(UT_IStream &is, UT_Vector3I &v)
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
void loadFromOpSubclass(const LoadParms &loadparms) override
static void saveData(std::ostream &os, UT_Vector3D v)
static void loadData(UT_IStream &is, UT_Vector2I &v)
void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
void doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
void setSplitcurves(bool val)
bool operator!=(const SOP_IntersectionStitchParms &src) const
void copyFrom(const SOP_NodeParms *src) override
void setBgroup(const UT_StringHolder &val)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
static void saveData(std::ostream &os, int64 v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
const UT_StringHolder & getBgroup() const
static void saveData(std::ostream &os, fpreal64 v)
SYS_FORCE_INLINE const char * buffer() const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
static void saveData(std::ostream &os, UT_StringHolder s)
GLint GLenum GLsizei GLint GLsizei const void * data
static void loadData(UT_IStream &is, UT_Vector2D &v)
void setPrimnumattrib(const UT_StringHolder &val)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
UT_StringHolder opBgroup(const SOP_NodeVerb::CookParms &cookparms) const
ParmType getNestParmType(TempIndex fieldnum) const override
bool load(UT_IStream &is)
static void saveData(std::ostream &os, bool v)
~SOP_IntersectionStitchParms() override
fpreal64 getProxtol() const
void setInputnumattrib(const UT_StringHolder &val)
static void loadData(UT_IStream &is, UT_Matrix4D &v)
void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
fpreal64 opProxtol(const SOP_NodeVerb::CookParms &cookparms) const
SOP_IntersectionStitchParms()
static void loadData(UT_IStream &is, UT_Matrix3D &v)
void saveBinary(std::ostream &os) const
Save string to binary stream.
UT_StringHolder opInputnumattrib(const SOP_NodeVerb::CookParms &cookparms) const
void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
GT_API const UT_StringHolder version
DEP_MicroNode * depnode() const
bool operator==(const SOP_IntersectionStitchParms &src) const
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
UT_StringHolder opPrimuvwattrib(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, UT_StringHolder &v)
static void loadData(UT_IStream &is, UT_Vector4I &v)
void buildFromOp(const SOP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
const UT_StringHolder & getPrimuvwattrib() const
Utility class for containing a color ramp.
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
bool opUseproxtol(const SOP_NodeVerb::CookParms &cookparms) const
GLdouble GLdouble GLdouble r
static void loadData(UT_IStream &is, fpreal64 &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr< UT_Ramp > &value) const override
static void loadData(UT_IStream &is, UT_Vector3D &v)
exint getNestNumParms(TempIndex idx) const override
virtual void evalOpParm(int64 &v, NodeIdx node, const char *parmname, fpreal time, DEP_MicroNode *depnode) const =0
fpreal getCookTime() const
static void saveData(std::ostream &os, UT_Matrix3D v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
bool opKeeppointattribs(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, UT_Matrix2D &v)
const char * findChar(int c) const
void setProxtol(fpreal64 val)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
bool getUseproxtol() const
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
void setUseproxtol(bool val)
void setKeeppointattribs(bool val)
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
static void loadData(UT_IStream &is, bool &v)
GLsizei const GLfloat * value
const UT_StringHolder & getAgroup() const
const OP_Context & context() const
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
void save(std::ostream &os) const
SYS_FORCE_INLINE bool isstring() const
bool getSplitcurves() const
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
void setAgroup(const UT_StringHolder &val)
UT_StringHolder opPrimnumattrib(const SOP_NodeVerb::CookParms &cookparms) const