HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SOP_EdgeTransport.proto.h
Go to the documentation of this file.
1 /* Automagically Generated by generate_proto.py
2  * Do not Edit
3  */
4 #pragma once
5 
6 #include <SOP/SOP_NodeVerb.h>
7 #include <OP/OP_Utils.h>
8 #include <PRM/PRM_Parm.h>
9 #include <UT/UT_IStream.h>
10 #include <UT/UT_NTStreamUtil.h>
11 #include <UT/UT_Ramp.h>
12 #include <UT/UT_SharedPtr.h>
13 #include <UT/UT_StringHolder.h>
14 #include <UT/UT_StringStream.h>
15 #include <UT/UT_VectorTypes.h>
16 #include <SYS/SYS_Types.h>
17 
18 using namespace UT::Literal;
19 
20 class DEP_MicroNode;
21 namespace SOP_EdgeTransportEnums
22 {
23  enum class Method
24  {
25  CURVE = 0,
26  NET,
27  PARENT
28  };
29  enum class CurveDir
30  {
31  FORWARD = 0,
32  BACKWARD
33  };
34  enum class RootType
35  {
36  FIRST = 0,
37  LAST,
38  GROUP
39  };
40  enum class Operation
41  {
42  COPY = 0,
43  COPYROOT,
44  SUM,
45  MAX,
46  MIN
47  };
48  enum class RootValue
49  {
50  ZERO = 0,
51  HOLD
52  };
53  enum class SplitMethod
54  {
55  COPY = 0,
56  SPLIT
57  };
58  enum class MergeMethod
59  {
60  SUM = 0,
61  MAX,
62  MIN
63  };
64 }
65 
66 
68 {
69 public:
70  static int version() { return 1; }
71 
73  {
74  myMethod = 0;
75  myPointGroup = ""_sh;
76  myPrimitiveGroup = ""_sh;
77  myAttribute = "distance"_sh;
78  myCurveDir = 0;
79  myParentAttribute = "parent"_sh;
80  myRootType = 0;
81  myRootGroup = "0"_sh;
82  myOperation = 2;
83  myRootValue = 0;
84  myIgnoreAttribute = false;
85  myScaleByEdge = false;
86  mySplitMethod = 0;
87  myMergeMethod = 0;
88 
89  }
90 
91  explicit SOP_EdgeTransportParms(const SOP_EdgeTransportParms &) = default;
92 
94 
96  {
97  if (myMethod != src.myMethod) return false;
98  if (myPointGroup != src.myPointGroup) return false;
99  if (myPrimitiveGroup != src.myPrimitiveGroup) return false;
100  if (myAttribute != src.myAttribute) return false;
101  if (myCurveDir != src.myCurveDir) return false;
102  if (myParentAttribute != src.myParentAttribute) return false;
103  if (myRootType != src.myRootType) return false;
104  if (myRootGroup != src.myRootGroup) return false;
105  if (myOperation != src.myOperation) return false;
106  if (myRootValue != src.myRootValue) return false;
107  if (myIgnoreAttribute != src.myIgnoreAttribute) return false;
108  if (myScaleByEdge != src.myScaleByEdge) return false;
109  if (mySplitMethod != src.mySplitMethod) return false;
110  if (myMergeMethod != src.myMergeMethod) return false;
111 
112  return true;
113  }
115  {
116  return !operator==(src);
117  }
125 
126 
127 
128  void buildFromOp(const OP_Node *node, fpreal time, DEP_MicroNode *depnode)
129  {
130  if (true)
131  OP_Utils::evalOpParm(myMethod, node, "method", time, 0);
132  else myMethod = 0;
133  if (true && ( (!(((int64(getMethod())==0)))) ) )
134  OP_Utils::evalOpParm(myPointGroup, node, "ptgroup", time, 0);
135  else myPointGroup = ""_sh;
136  if (true && ( (!(((int64(getMethod())!=0)))) ) )
137  OP_Utils::evalOpParm(myPrimitiveGroup, node, "primgroup", time, 0);
138  else myPrimitiveGroup = ""_sh;
139  if (true)
140  OP_Utils::evalOpParm(myAttribute, node, "attribute", time, 0);
141  else myAttribute = "distance"_sh;
142  if (true)
143  OP_Utils::evalOpParm(myCurveDir, node, "curvedir", time, 0);
144  else myCurveDir = 0;
145  if (true && ( (!(((int64(getMethod())!=2)))) ) )
146  OP_Utils::evalOpParm(myParentAttribute, node, "parentattribute", time, 0);
147  else myParentAttribute = "parent"_sh;
148  if (true && ( (!(((int64(getMethod())!=1)))) ) )
149  OP_Utils::evalOpParm(myRootType, node, "roottype", time, 0);
150  else myRootType = 0;
151  if (true && ( (!(((int64(getRootType())!=2))||((int64(getMethod())!=1)))) ) )
152  OP_Utils::evalOpParm(myRootGroup, node, "rootgroup", time, 0);
153  else myRootGroup = "0"_sh;
154  if (true)
155  OP_Utils::evalOpParm(myOperation, node, "operation", time, 0);
156  else myOperation = 2;
157  if (true && ( (!(((int64(getOperation())!=0)))) ) )
158  OP_Utils::evalOpParm(myRootValue, node, "rootvalue", time, 0);
159  else myRootValue = 0;
160  if (true && ( (!(((int64(getOperation())!=2)))) ) )
161  OP_Utils::evalOpParm(myIgnoreAttribute, node, "ignoreattribute", time, 0);
162  else myIgnoreAttribute = false;
163  if (true && ( (!(((int64(getOperation())!=2)))) ) )
164  OP_Utils::evalOpParm(myScaleByEdge, node, "scalebyedge", time, 0);
165  else myScaleByEdge = false;
166  if (true && ( (!(((int64(getMethod())==0))||((int64(getCurveDir())!=0)))) ) )
167  OP_Utils::evalOpParm(mySplitMethod, node, "splitmethod", time, 0);
168  else mySplitMethod = 0;
169  if (true && ( (!(((int64(getMethod())==0))||((int64(getCurveDir())!=1)))) ) )
170  OP_Utils::evalOpParm(myMergeMethod, node, "mergemethod", time, 0);
171  else myMergeMethod = 0;
172 
173  }
174 
175 
176  virtual void loadFromOpSubclass(const LoadParms &loadparms)
177  {
178  buildFromOp(loadparms.node(), loadparms.context().getTime(), loadparms.depnode());
179  }
180 
181 
182  virtual void copyFrom(const SOP_NodeParms *src)
183  {
184  *this = *((const SOP_EdgeTransportParms *)src);
185  }
186 
187  template <typename T>
188  void
189  doGetParmValue(exint idx, T &value) const
190  {
191  switch (idx)
192  {
193  case 0:
194  coerceValue(value, myMethod);
195  break;
196  case 1:
197  coerceValue(value, myPointGroup);
198  break;
199  case 2:
200  coerceValue(value, myPrimitiveGroup);
201  break;
202  case 3:
203  coerceValue(value, myAttribute);
204  break;
205  case 4:
206  coerceValue(value, myCurveDir);
207  break;
208  case 5:
209  coerceValue(value, myParentAttribute);
210  break;
211  case 6:
212  coerceValue(value, myRootType);
213  break;
214  case 7:
215  coerceValue(value, myRootGroup);
216  break;
217  case 8:
218  coerceValue(value, myOperation);
219  break;
220  case 9:
221  coerceValue(value, myRootValue);
222  break;
223  case 10:
224  coerceValue(value, myIgnoreAttribute);
225  break;
226  case 11:
227  coerceValue(value, myScaleByEdge);
228  break;
229  case 12:
230  coerceValue(value, mySplitMethod);
231  break;
232  case 13:
233  coerceValue(value, myMergeMethod);
234  break;
235 
236  }
237  }
238 
239  void getParmValue(exint idx, exint &value) const
240  { doGetParmValue(idx, value); }
241  void getParmValue(exint idx, fpreal &value) const
242  { doGetParmValue(idx, value); }
244  { doGetParmValue(idx, value); }
246  { doGetParmValue(idx, value); }
248  { doGetParmValue(idx, value); }
250  { doGetParmValue(idx, value); }
252  { doGetParmValue(idx, value); }
254  { doGetParmValue(idx, value); }
256  { doGetParmValue(idx, value); }
258  { doGetParmValue(idx, value); }
260  { doGetParmValue(idx, value); }
261 
262  template <typename T>
263  void
264  doSetParmValue(exint idx, const T &value)
265  {
266  switch (idx)
267  {
268  case 0:
269  coerceValue(myMethod, value);
270  break;
271  case 1:
272  coerceValue(myPointGroup, value);
273  break;
274  case 2:
275  coerceValue(myPrimitiveGroup, value);
276  break;
277  case 3:
278  coerceValue(myAttribute, value);
279  break;
280  case 4:
281  coerceValue(myCurveDir, value);
282  break;
283  case 5:
284  coerceValue(myParentAttribute, value);
285  break;
286  case 6:
287  coerceValue(myRootType, value);
288  break;
289  case 7:
290  coerceValue(myRootGroup, value);
291  break;
292  case 8:
293  coerceValue(myOperation, value);
294  break;
295  case 9:
296  coerceValue(myRootValue, value);
297  break;
298  case 10:
299  coerceValue(myIgnoreAttribute, value);
300  break;
301  case 11:
302  coerceValue(myScaleByEdge, value);
303  break;
304  case 12:
305  coerceValue(mySplitMethod, value);
306  break;
307  case 13:
308  coerceValue(myMergeMethod, value);
309  break;
310 
311  }
312  }
313 
314  void setParmValue(exint idx, const exint &value)
315  { doSetParmValue(idx, value); }
316  void setParmValue(exint idx, const fpreal &value)
317  { doSetParmValue(idx, value); }
318  void setParmValue(exint idx, const UT_Vector2D &value)
319  { doSetParmValue(idx, value); }
320  void setParmValue(exint idx, const UT_Vector3D &value)
321  { doSetParmValue(idx, value); }
322  void setParmValue(exint idx, const UT_Vector4D &value)
323  { doSetParmValue(idx, value); }
324  void setParmValue(exint idx, const UT_Matrix2D &value)
325  { doSetParmValue(idx, value); }
326  void setParmValue(exint idx, const UT_Matrix3D &value)
327  { doSetParmValue(idx, value); }
328  void setParmValue(exint idx, const UT_Matrix4D &value)
329  { doSetParmValue(idx, value); }
331  { doSetParmValue(idx, value); }
333  { doSetParmValue(idx, value); }
335  { doSetParmValue(idx, value); }
336 
337  virtual exint getNumParms() const
338  {
339  return 14;
340  }
341 
342  virtual const char *getParmName(exint fieldnum) const
343  {
344  switch (fieldnum)
345  {
346  case 0:
347  return "method";
348  case 1:
349  return "ptgroup";
350  case 2:
351  return "primgroup";
352  case 3:
353  return "attribute";
354  case 4:
355  return "curvedir";
356  case 5:
357  return "parentattribute";
358  case 6:
359  return "roottype";
360  case 7:
361  return "rootgroup";
362  case 8:
363  return "operation";
364  case 9:
365  return "rootvalue";
366  case 10:
367  return "ignoreattribute";
368  case 11:
369  return "scalebyedge";
370  case 12:
371  return "splitmethod";
372  case 13:
373  return "mergemethod";
374 
375  }
376  return 0;
377  }
378 
379  virtual ParmType getParmType(exint fieldnum) const
380  {
381  switch (fieldnum)
382  {
383  case 0:
384  return PARM_INTEGER;
385  case 1:
386  return PARM_STRING;
387  case 2:
388  return PARM_STRING;
389  case 3:
390  return PARM_STRING;
391  case 4:
392  return PARM_INTEGER;
393  case 5:
394  return PARM_STRING;
395  case 6:
396  return PARM_INTEGER;
397  case 7:
398  return PARM_STRING;
399  case 8:
400  return PARM_INTEGER;
401  case 9:
402  return PARM_INTEGER;
403  case 10:
404  return PARM_INTEGER;
405  case 11:
406  return PARM_INTEGER;
407  case 12:
408  return PARM_INTEGER;
409  case 13:
410  return PARM_INTEGER;
411 
412  }
413  return PARM_UNSUPPORTED;
414  }
415 
416  // Boiler plate to load individual types.
417  static void loadData(UT_IStream &is, int64 &v)
418  { is.bread(&v, 1); }
419  static void loadData(UT_IStream &is, bool &v)
420  { int64 iv; is.bread(&iv, 1); v = iv; }
421  static void loadData(UT_IStream &is, fpreal64 &v)
422  { is.bread<fpreal64>(&v, 1); }
423  static void loadData(UT_IStream &is, UT_Vector2D &v)
424  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1); }
425  static void loadData(UT_IStream &is, UT_Vector3D &v)
426  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
427  is.bread<fpreal64>(&v.z(), 1); }
428  static void loadData(UT_IStream &is, UT_Vector4D &v)
429  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
430  is.bread<fpreal64>(&v.z(), 1); is.bread<fpreal64>(&v.w(), 1); }
431  static void loadData(UT_IStream &is, UT_Matrix2D &v)
432  { for (int r = 0; r < 2; r++) for (int c = 0; c < 2; c++) is.bread<fpreal64>(&v(r, c), 1); }
433  static void loadData(UT_IStream &is, UT_Matrix3D &v)
434  { for (int r = 0; r < 3; r++) for (int c = 0; c < 3; c++) is.bread<fpreal64>(&v(r, c), 1); }
435  static void loadData(UT_IStream &is, UT_Matrix4D &v)
436  { for (int r = 0; r < 4; r++) for (int c = 0; c < 4; c++) is.bread<fpreal64>(&v(r, c), 1); }
437  static void loadData(UT_IStream &is, UT_Vector2I &v)
438  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1); }
439  static void loadData(UT_IStream &is, UT_Vector3I &v)
440  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
441  is.bread<int64>(&v.z(), 1); }
442  static void loadData(UT_IStream &is, UT_Vector4I &v)
443  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
444  is.bread<int64>(&v.z(), 1); is.bread<int64>(&v.w(), 1); }
446  { is.bread(v); }
448  { UT_StringHolder rampdata;
449  loadData(is, rampdata);
450  if (rampdata.isstring())
451  {
452  v.reset(new UT_Ramp());
453  UT_IStream istr((const char *) rampdata, rampdata.length(), UT_ISTREAM_ASCII);
454  v->load(istr);
455  }
456  else v.reset();
457  }
460  loadData(is, data);
461  if (data.isstring())
462  {
463  // Find the data type.
464  char *colon = UT_StringWrap(data).findChar(':');
465  if (colon)
466  {
467  int typelen = colon - data.buffer();
469  type.strncpy(data.buffer(), typelen);
470  UT_IStream istr(((const char *) data) + typelen + 1, data.length() - (typelen + 1), UT_ISTREAM_BINARY);
471 
472  v = PRM_DataFactory::parseBinary(type.buffer(), istr);
473  }
474  }
475  else v.reset();
476  }
477 
478  static void saveData(std::ostream &os, int64 v)
479  { UTwrite(os, &v); }
480  static void saveData(std::ostream &os, bool v)
481  { int64 iv = v; UTwrite(os, &iv); }
482  static void saveData(std::ostream &os, fpreal64 v)
483  { UTwrite<fpreal64>(os, &v); }
484  static void saveData(std::ostream &os, UT_Vector2D v)
485  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y()); }
486  static void saveData(std::ostream &os, UT_Vector3D v)
487  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
488  UTwrite<fpreal64>(os, &v.z()); }
489  static void saveData(std::ostream &os, UT_Vector4D v)
490  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
491  UTwrite<fpreal64>(os, &v.z()); UTwrite<fpreal64>(os, &v.w()); }
492  static void saveData(std::ostream &os, UT_Matrix2D v)
494  static void saveData(std::ostream &os, UT_Matrix3D v)
496  static void saveData(std::ostream &os, UT_Matrix4D v)
498  static void saveData(std::ostream &os, UT_StringHolder s)
499  { UT_StringWrap(s).saveBinary(os); }
500  static void saveData(std::ostream &os, UT_SharedPtr<UT_Ramp> s)
501  { UT_StringHolder result;
502  UT_OStringStream ostr;
503  if (s) s->save(ostr);
504  result = ostr.str();
505  saveData(os, result);
506  }
507  static void saveData(std::ostream &os, PRM_DataItemHandle s)
508  { UT_StringHolder result;
509  UT_OStringStream ostr;
510  if (s)
511  {
512  ostr << s->getDataTypeToken();
513  ostr << ":";
514  s->saveBinary(ostr);
515  }
516  result = ostr.str();
517  saveData(os, result);
518  }
519 
520 
521  void save(std::ostream &os) const
522  {
523  int32 v = version();
524  UTwrite(os, &v);
525  saveData(os, myMethod);
526  saveData(os, myPointGroup);
527  saveData(os, myPrimitiveGroup);
528  saveData(os, myAttribute);
529  saveData(os, myCurveDir);
530  saveData(os, myParentAttribute);
531  saveData(os, myRootType);
532  saveData(os, myRootGroup);
533  saveData(os, myOperation);
534  saveData(os, myRootValue);
535  saveData(os, myIgnoreAttribute);
536  saveData(os, myScaleByEdge);
537  saveData(os, mySplitMethod);
538  saveData(os, myMergeMethod);
539 
540  }
541 
542  bool load(UT_IStream &is)
543  {
544  int32 v;
545  is.bread(&v, 1);
546  if (version() != v)
547  {
548  // Fail incompatible versions
549  return false;
550  }
551  loadData(is, myMethod);
552  loadData(is, myPointGroup);
553  loadData(is, myPrimitiveGroup);
554  loadData(is, myAttribute);
555  loadData(is, myCurveDir);
556  loadData(is, myParentAttribute);
557  loadData(is, myRootType);
558  loadData(is, myRootGroup);
559  loadData(is, myOperation);
560  loadData(is, myRootValue);
561  loadData(is, myIgnoreAttribute);
562  loadData(is, myScaleByEdge);
563  loadData(is, mySplitMethod);
564  loadData(is, myMergeMethod);
565 
566  return true;
567  }
568 
569  Method getMethod() const { return Method(myMethod); }
570  void setMethod(Method val) { myMethod = int64(val); }
571  Method opMethod(const SOP_NodeVerb::CookParms &cookparms) const
572  {
573  SOP_Node *thissop = cookparms.getNode();
574  if (!thissop) return getMethod();
575  int64 result;
576  OP_Utils::evalOpParm(result, thissop, "method", cookparms.getCookTime(), 0);
577  return Method(result);
578  }
579  const UT_StringHolder & getPointGroup() const { return myPointGroup; }
580  void setPointGroup(const UT_StringHolder & val) { myPointGroup = val; }
582  {
583  SOP_Node *thissop = cookparms.getNode();
584  if (!thissop) return getPointGroup();
585  UT_StringHolder result;
586  OP_Utils::evalOpParm(result, thissop, "ptgroup", cookparms.getCookTime(), 0);
587  return result;
588  }
589  const UT_StringHolder & getPrimitiveGroup() const { return myPrimitiveGroup; }
590  void setPrimitiveGroup(const UT_StringHolder & val) { myPrimitiveGroup = val; }
592  {
593  SOP_Node *thissop = cookparms.getNode();
594  if (!thissop) return getPrimitiveGroup();
595  UT_StringHolder result;
596  OP_Utils::evalOpParm(result, thissop, "primgroup", cookparms.getCookTime(), 0);
597  return result;
598  }
599  const UT_StringHolder & getAttribute() const { return myAttribute; }
600  void setAttribute(const UT_StringHolder & val) { myAttribute = val; }
602  {
603  SOP_Node *thissop = cookparms.getNode();
604  if (!thissop) return getAttribute();
605  UT_StringHolder result;
606  OP_Utils::evalOpParm(result, thissop, "attribute", cookparms.getCookTime(), 0);
607  return result;
608  }
609  CurveDir getCurveDir() const { return CurveDir(myCurveDir); }
610  void setCurveDir(CurveDir val) { myCurveDir = int64(val); }
612  {
613  SOP_Node *thissop = cookparms.getNode();
614  if (!thissop) return getCurveDir();
615  int64 result;
616  OP_Utils::evalOpParm(result, thissop, "curvedir", cookparms.getCookTime(), 0);
617  return CurveDir(result);
618  }
619  const UT_StringHolder & getParentAttribute() const { return myParentAttribute; }
620  void setParentAttribute(const UT_StringHolder & val) { myParentAttribute = val; }
622  {
623  SOP_Node *thissop = cookparms.getNode();
624  if (!thissop) return getParentAttribute();
625  UT_StringHolder result;
626  OP_Utils::evalOpParm(result, thissop, "parentattribute", cookparms.getCookTime(), 0);
627  return result;
628  }
629  RootType getRootType() const { return RootType(myRootType); }
630  void setRootType(RootType val) { myRootType = int64(val); }
632  {
633  SOP_Node *thissop = cookparms.getNode();
634  if (!thissop) return getRootType();
635  int64 result;
636  OP_Utils::evalOpParm(result, thissop, "roottype", cookparms.getCookTime(), 0);
637  return RootType(result);
638  }
639  const UT_StringHolder & getRootGroup() const { return myRootGroup; }
640  void setRootGroup(const UT_StringHolder & val) { myRootGroup = val; }
642  {
643  SOP_Node *thissop = cookparms.getNode();
644  if (!thissop) return getRootGroup();
645  UT_StringHolder result;
646  OP_Utils::evalOpParm(result, thissop, "rootgroup", cookparms.getCookTime(), 0);
647  return result;
648  }
649  Operation getOperation() const { return Operation(myOperation); }
650  void setOperation(Operation val) { myOperation = int64(val); }
652  {
653  SOP_Node *thissop = cookparms.getNode();
654  if (!thissop) return getOperation();
655  int64 result;
656  OP_Utils::evalOpParm(result, thissop, "operation", cookparms.getCookTime(), 0);
657  return Operation(result);
658  }
659  RootValue getRootValue() const { return RootValue(myRootValue); }
660  void setRootValue(RootValue val) { myRootValue = int64(val); }
662  {
663  SOP_Node *thissop = cookparms.getNode();
664  if (!thissop) return getRootValue();
665  int64 result;
666  OP_Utils::evalOpParm(result, thissop, "rootvalue", cookparms.getCookTime(), 0);
667  return RootValue(result);
668  }
669  bool getIgnoreAttribute() const { return myIgnoreAttribute; }
670  void setIgnoreAttribute(bool val) { myIgnoreAttribute = val; }
671  bool opIgnoreAttribute(const SOP_NodeVerb::CookParms &cookparms) const
672  {
673  SOP_Node *thissop = cookparms.getNode();
674  if (!thissop) return getIgnoreAttribute();
675  bool result;
676  OP_Utils::evalOpParm(result, thissop, "ignoreattribute", cookparms.getCookTime(), 0);
677  return result;
678  }
679  bool getScaleByEdge() const { return myScaleByEdge; }
680  void setScaleByEdge(bool val) { myScaleByEdge = val; }
681  bool opScaleByEdge(const SOP_NodeVerb::CookParms &cookparms) const
682  {
683  SOP_Node *thissop = cookparms.getNode();
684  if (!thissop) return getScaleByEdge();
685  bool result;
686  OP_Utils::evalOpParm(result, thissop, "scalebyedge", cookparms.getCookTime(), 0);
687  return result;
688  }
689  SplitMethod getSplitMethod() const { return SplitMethod(mySplitMethod); }
690  void setSplitMethod(SplitMethod val) { mySplitMethod = int64(val); }
692  {
693  SOP_Node *thissop = cookparms.getNode();
694  if (!thissop) return getSplitMethod();
695  int64 result;
696  OP_Utils::evalOpParm(result, thissop, "splitmethod", cookparms.getCookTime(), 0);
697  return SplitMethod(result);
698  }
699  MergeMethod getMergeMethod() const { return MergeMethod(myMergeMethod); }
700  void setMergeMethod(MergeMethod val) { myMergeMethod = int64(val); }
702  {
703  SOP_Node *thissop = cookparms.getNode();
704  if (!thissop) return getMergeMethod();
705  int64 result;
706  OP_Utils::evalOpParm(result, thissop, "mergemethod", cookparms.getCookTime(), 0);
707  return MergeMethod(result);
708  }
709 
710 private:
711  int64 myMethod;
712  UT_StringHolder myPointGroup;
713  UT_StringHolder myPrimitiveGroup;
714  UT_StringHolder myAttribute;
715  int64 myCurveDir;
716  UT_StringHolder myParentAttribute;
717  int64 myRootType;
718  UT_StringHolder myRootGroup;
719  int64 myOperation;
720  int64 myRootValue;
721  bool myIgnoreAttribute;
722  bool myScaleByEdge;
723  int64 mySplitMethod;
724  int64 myMergeMethod;
725 
726 };
void save(std::ostream &os) const
static void loadData(UT_IStream &is, UT_Vector2D &v)
void setParmValue(exint idx, const UT_SharedPtr< UT_Ramp > &value)
void setPointGroup(const UT_StringHolder &val)
void getParmValue(exint idx, UT_Vector4D &value) const
SOP_Node * getNode() const
Definition: SOP_NodeVerb.h:494
void setParmValue(exint idx, const UT_StringHolder &value)
void setParentAttribute(const UT_StringHolder &val)
T & z(void)
Definition: UT_Vector4.h:379
const UT_StringHolder & getPrimitiveGroup() const
static void saveData(std::ostream &os, UT_StringHolder s)
static void loadData(UT_IStream &is, UT_Vector4D &v)
bool opScaleByEdge(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, fpreal64 v)
void getParmValue(exint idx, exint &value) const
exint bread(int32 *buffer, exint asize=1)
RootType opRootType(const SOP_NodeVerb::CookParms &cookparms) const
GT_API const UT_StringHolder time
fpreal getTime() const
Definition: OP_Context.h:60
const GLdouble * v
Definition: glcorearb.h:836
void setParmValue(exint idx, const UT_Matrix3D &value)
void setOperation(Operation val)
void doGetParmValue(exint idx, T &value) const
static void loadData(UT_IStream &is, bool &v)
void getParmValue(exint idx, PRM_DataItemHandle &value) const
UT_StringHolder opRootGroup(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, UT_Vector3I &v)
virtual ParmType getParmType(exint fieldnum) const
static void saveData(std::ostream &os, UT_Vector2D v)
const UT_StringHolder & getAttribute() const
SYS_FORCE_INLINE const char * buffer() const
T & x(void)
Definition: UT_Vector2.h:285
An output stream object that owns its own string buffer storage.
void setParmValue(exint idx, const UT_Matrix4D &value)
const UT_StringHolder & getPointGroup() const
virtual exint getNumParms() const
const UT_WorkBuffer & str() const
Returns a read-only reference to the underlying UT_WorkBuffer.
void getParmValue(exint idx, UT_StringHolder &value) const
UT_StringHolder opAttribute(const SOP_NodeVerb::CookParms &cookparms) const
SYS_FORCE_INLINE T & x(void)
Definition: UT_Vector3.h:498
static void saveData(std::ostream &os, UT_Vector3D v)
SplitMethod opSplitMethod(const SOP_NodeVerb::CookParms &cookparms) const
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
bool operator==(const SOP_EdgeTransportParms &src) const
void buildFromOp(const OP_Node *node, fpreal time, DEP_MicroNode *depnode)
void setParmValue(exint idx, const exint &value)
void getParmValue(exint idx, UT_SharedPtr< UT_Ramp > &value) const
void getParmValue(exint idx, UT_Matrix3D &value) const
void setParmValue(exint idx, const fpreal &value)
SYS_FORCE_INLINE T & z(void)
Definition: UT_Vector3.h:502
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
Definition: Dimensions.h:137
static void saveData(std::ostream &os, UT_Matrix2D v)
long long int64
Definition: SYS_Types.h:107
exint length() const
char * findChar(int c) const
Find first occurrance of character. Returns NULL upon failure.
Definition: UT_String.h:550
bool operator!=(const SOP_EdgeTransportParms &src) const
SYS_FORCE_INLINE const char * buffer() const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
Definition: UT_SharedPtr.h:28
int64 exint
Definition: SYS_Types.h:116
static void loadData(UT_IStream &is, fpreal64 &v)
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
const OP_Node * node() const
Definition: SOP_NodeVerb.h:104
double fpreal64
Definition: SYS_Types.h:192
static void saveData(std::ostream &os, bool v)
void setParmValue(exint idx, const PRM_DataItemHandle &value)
void setParmValue(exint idx, const UT_Vector4D &value)
SplitMethod getSplitMethod() const
virtual void loadFromOpSubclass(const LoadParms &loadparms)
static void saveData(std::ostream &os, int64 v)
static void saveData(std::ostream &os, UT_Matrix4D v)
Operation opOperation(const SOP_NodeVerb::CookParms &cookparms) const
void getParmValue(exint idx, UT_Vector2D &value) const
GLboolean * data
Definition: glcorearb.h:130
int int32
Definition: SYS_Types.h:35
const UT_StringHolder & getRootGroup() const
T & y(void)
Definition: UT_Vector4.h:377
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
MergeMethod opMergeMethod(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, PRM_DataItemHandle s)
void saveBinary(std::ostream &os) const
Save string to binary stream.
Definition: UT_String.h:294
static void loadData(UT_IStream &is, UT_Matrix3D &v)
static void loadData(UT_IStream &is, UT_Matrix2D &v)
GT_API const UT_StringHolder version
DEP_MicroNode * depnode() const
Definition: SOP_NodeVerb.h:111
void getParmValue(exint idx, UT_Matrix4D &value) const
void setSplitMethod(SplitMethod val)
void setRootValue(RootValue val)
static void loadData(UT_IStream &is, int64 &v)
static void loadData(UT_IStream &is, UT_StringHolder &v)
static void loadData(UT_IStream &is, UT_Vector4I &v)
void getParmValue(exint idx, UT_Matrix2D &value) const
SYS_FORCE_INLINE T & y(void)
Definition: UT_Vector3.h:500
GLsizei const GLfloat * value
Definition: glcorearb.h:823
double fpreal
Definition: SYS_Types.h:270
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
void setRootGroup(const UT_StringHolder &val)
void setPrimitiveGroup(const UT_StringHolder &val)
void setParmValue(exint idx, const UT_Vector2D &value)
Utility class for containing a color ramp.
Definition: UT_Ramp.h:84
RootValue opRootValue(const SOP_NodeVerb::CookParms &cookparms) const
void setMergeMethod(MergeMethod val)
void doSetParmValue(exint idx, const T &value)
GLuint GLfloat * val
Definition: glcorearb.h:1607
const UT_StringHolder & getParentAttribute() const
#define SOP_API
Definition: SOP_API.h:10
void setParmValue(exint idx, const UT_Matrix2D &value)
void getParmValue(exint idx, fpreal &value) const
static void loadData(UT_IStream &is, UT_Vector3D &v)
GLint GLint GLsizei GLint GLenum GLenum type
Definition: glcorearb.h:107
fpreal getCookTime() const
Definition: SOP_NodeVerb.h:501
void setAttribute(const UT_StringHolder &val)
T & x(void)
Definition: UT_Vector4.h:375
virtual const char * getParmName(exint fieldnum) const
static void loadData(UT_IStream &is, UT_Vector2I &v)
T & y(void)
Definition: UT_Vector2.h:287
GLboolean r
Definition: glcorearb.h:1221
bool opIgnoreAttribute(const SOP_NodeVerb::CookParms &cookparms) const
void getParmValue(exint idx, UT_Vector3D &value) const
T & w(void)
Definition: UT_Vector4.h:381
static void saveData(std::ostream &os, UT_Matrix3D v)
virtual void copyFrom(const SOP_NodeParms *src)
static void saveData(std::ostream &os, UT_Vector4D v)
UT_StringHolder opPrimitiveGroup(const SOP_NodeVerb::CookParms &cookparms) const
const OP_Context & context() const
Definition: SOP_NodeVerb.h:109
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
Definition: PRM_Parm.h:88
CurveDir opCurveDir(const SOP_NodeVerb::CookParms &cookparms) const
MergeMethod getMergeMethod() const
UT_StringHolder opPointGroup(const SOP_NodeVerb::CookParms &cookparms) const
SYS_FORCE_INLINE bool isstring() const
void setParmValue(exint idx, const UT_Vector3D &value)
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
UT_StringHolder opParentAttribute(const SOP_NodeVerb::CookParms &cookparms) const
GLenum src
Definition: glcorearb.h:1792
static void loadData(UT_IStream &is, UT_Matrix4D &v)
Method opMethod(const SOP_NodeVerb::CookParms &cookparms) const