HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SOP_GroupFindPath.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_API.h>
7 #include <SOP/SOP_NodeVerb.h>
8 #include <OP/OP_GraphProxy.h>
9 
10 #include <OP/OP_Utils.h>
11 #include <PRM/PRM_Parm.h>
12 #include <UT/UT_IStream.h>
13 #include <UT/UT_NTStreamUtil.h>
14 #include <UT/UT_Ramp.h>
15 #include <UT/UT_SharedPtr.h>
16 #include <UT/UT_StringHolder.h>
17 #include <UT/UT_StringStream.h>
18 #include <UT/UT_VectorTypes.h>
19 #include <UT/UT_EnvControl.h>
20 #include <SYS/SYS_Types.h>
21 
22 class DEP_MicroNode;
23 namespace SOP_GroupFindPathEnums
24 {
25  enum class Grouptype
26  {
27  AUTO = 0,
28  EDGES,
29  POINTS,
30  PRIMS,
31  VERTICES
32  };
33 
35  getToken(Grouptype enum_value)
36  {
37  using namespace UT::Literal;
38  switch (enum_value) {
39  case Grouptype::AUTO: return "auto"_sh;
40  case Grouptype::EDGES: return "edges"_sh;
41  case Grouptype::POINTS: return "points"_sh;
42  case Grouptype::PRIMS: return "prims"_sh;
43  case Grouptype::VERTICES: return "vertices"_sh;
44  default: UT_ASSERT(false); return ""_sh;
45  }
46  }
47 
48  enum class Pathcontroltype
49  {
50  CONTROLS = 0,
51  STARTS,
52  STARTEND
53  };
54 
57  {
58  using namespace UT::Literal;
59  switch (enum_value) {
60  case Pathcontroltype::CONTROLS: return "controls"_sh;
61  case Pathcontroltype::STARTS: return "starts"_sh;
62  case Pathcontroltype::STARTEND: return "startend"_sh;
63  default: UT_ASSERT(false); return ""_sh;
64  }
65  }
66 
67  enum class Operation
68  {
69  PATH = 0,
72  };
73 
75  getToken(Operation enum_value)
76  {
77  using namespace UT::Literal;
78  switch (enum_value) {
79  case Operation::PATH: return "path"_sh;
80  case Operation::EXTENDEDPATH: return "extendedpath"_sh;
81  case Operation::CLOSEDPATH: return "closedpath"_sh;
82  default: UT_ASSERT(false); return ""_sh;
83  }
84  }
85 
86  enum class Edgestyle
87  {
88  AUTO = 0,
89  LOOP,
90  RING
91  };
92 
94  getToken(Edgestyle enum_value)
95  {
96  using namespace UT::Literal;
97  switch (enum_value) {
98  case Edgestyle::AUTO: return "auto"_sh;
99  case Edgestyle::LOOP: return "loop"_sh;
100  case Edgestyle::RING: return "ring"_sh;
101  default: UT_ASSERT(false); return ""_sh;
102  }
103  }
104 
105  enum class Colgrouptype
106  {
107  AUTO = 0,
108  EDGES,
109  POINTS,
110  PRIMS,
111  VERTICES
112  };
113 
115  getToken(Colgrouptype enum_value)
116  {
117  using namespace UT::Literal;
118  switch (enum_value) {
119  case Colgrouptype::AUTO: return "auto"_sh;
120  case Colgrouptype::EDGES: return "edges"_sh;
121  case Colgrouptype::POINTS: return "points"_sh;
122  case Colgrouptype::PRIMS: return "prims"_sh;
123  case Colgrouptype::VERTICES: return "vertices"_sh;
124  default: UT_ASSERT(false); return ""_sh;
125  }
126  }
127 
128 }
129 
130 
132 {
133 public:
134  static int version() { return 1; }
135 
137  {
138  myOutgroup = ""_UTsh;
139  myGroup = ""_UTsh;
140  myGrouptype = 0;
141  myPathcontroltype = 0;
142  myOperation = 0;
143  myAvoidprevious = true;
144  myEdgestyle = 0;
145  myUseuvattrib = false;
146  myUvattrib = "uv"_UTsh;
147  myUsecolgroup = false;
148  myColgroup = ""_UTsh;
149  myColgrouptype = 0;
150  myColgroupinvert = false;
151  myColgrouponbnd = false;
152 
153  }
154 
155  explicit SOP_GroupFindPathParms(const SOP_GroupFindPathParms &) = default;
157  SOP_GroupFindPathParms(SOP_GroupFindPathParms &&) noexcept = default;
158  SOP_GroupFindPathParms &operator=(SOP_GroupFindPathParms &&) noexcept = default;
159 
160  ~SOP_GroupFindPathParms() override {}
161 
163  {
164  if (myOutgroup != src.myOutgroup) return false;
165  if (myGroup != src.myGroup) return false;
166  if (myGrouptype != src.myGrouptype) return false;
167  if (myPathcontroltype != src.myPathcontroltype) return false;
168  if (myOperation != src.myOperation) return false;
169  if (myAvoidprevious != src.myAvoidprevious) return false;
170  if (myEdgestyle != src.myEdgestyle) return false;
171  if (myUseuvattrib != src.myUseuvattrib) return false;
172  if (myUvattrib != src.myUvattrib) return false;
173  if (myUsecolgroup != src.myUsecolgroup) return false;
174  if (myColgroup != src.myColgroup) return false;
175  if (myColgrouptype != src.myColgrouptype) return false;
176  if (myColgroupinvert != src.myColgroupinvert) return false;
177  if (myColgrouponbnd != src.myColgrouponbnd) return false;
178 
179 
180  if (baseGetSignature() != src.baseGetSignature()) return false;
181 
182  return true;
183  }
185  {
186  return !operator==(src);
187  }
193 
194 
195 
196  void buildFromOp(const OP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
197  {
198  myOutgroup = ""_UTsh;
199  if (true)
200  graph->evalOpParm(myOutgroup, nodeidx, "outgroup", time, graph->isDirect()?nullptr:depnode);
201  myGroup = ""_UTsh;
202  if (true)
203  graph->evalOpParm(myGroup, nodeidx, "group", time, graph->isDirect()?nullptr:depnode);
204  myGrouptype = 0;
205  if (true)
206  graph->evalOpParm(myGrouptype, nodeidx, "grouptype", time, graph->isDirect()?nullptr:depnode);
207  myPathcontroltype = 0;
208  if (true)
209  graph->evalOpParm(myPathcontroltype, nodeidx, "pathcontroltype", time, graph->isDirect()?nullptr:depnode);
210  myOperation = 0;
211  if (true)
212  graph->evalOpParm(myOperation, nodeidx, "operation", time, graph->isDirect()?nullptr:depnode);
213  myAvoidprevious = true;
214  if (true)
215  graph->evalOpParm(myAvoidprevious, nodeidx, "avoidprevious", time, graph->isDirect()?nullptr:depnode);
216  myEdgestyle = 0;
217  if (true && ( (true&&!(((int64(getGrouptype())==2))||((int64(getGrouptype())==3))||((int64(getGrouptype())==4)))) ) )
218  graph->evalOpParm(myEdgestyle, nodeidx, "edgestyle", time, graph->isDirect()?nullptr:depnode);
219  myUseuvattrib = false;
220  if (true)
221  graph->evalOpParm(myUseuvattrib, nodeidx, "useuvattrib", time, graph->isDirect()?nullptr:depnode);
222  myUvattrib = "uv"_UTsh;
223  if (true && ( (true&&!(((getUseuvattrib()==0)))) ) )
224  graph->evalOpParm(myUvattrib, nodeidx, "uvattrib", time, graph->isDirect()?nullptr:depnode);
225  myUsecolgroup = false;
226  if (true)
227  graph->evalOpParm(myUsecolgroup, nodeidx, "usecolgroup", time, graph->isDirect()?nullptr:depnode);
228  myColgroup = ""_UTsh;
229  if (true && ( (true&&!(((getUsecolgroup()==0)))) ) )
230  graph->evalOpParm(myColgroup, nodeidx, "colgroup", time, graph->isDirect()?nullptr:depnode);
231  myColgrouptype = 0;
232  if (true && ( (true&&!(((getUsecolgroup()==0)))) ) )
233  graph->evalOpParm(myColgrouptype, nodeidx, "colgrouptype", time, graph->isDirect()?nullptr:depnode);
234  myColgroupinvert = false;
235  if (true && ( (true&&!(((getUsecolgroup()==0)))) ) )
236  graph->evalOpParm(myColgroupinvert, nodeidx, "colgroupinvert", time, graph->isDirect()?nullptr:depnode);
237  myColgrouponbnd = false;
238  if (true && ( (true&&!(((getUsecolgroup()==0))||((getColgroupinvert()==1)))) ) )
239  graph->evalOpParm(myColgrouponbnd, nodeidx, "colgrouponbnd", time, graph->isDirect()?nullptr:depnode);
240 
241  }
242 
243 
244  void loadFromOpSubclass(const LoadParms &loadparms) override
245  {
246  buildFromOp(loadparms.graph(), loadparms.nodeIdx(), loadparms.context().getTime(), loadparms.depnode());
247  }
248 
249 
250  void copyFrom(const OP_NodeParms *src) override
251  {
252  *this = *((const SOP_GroupFindPathParms *)src);
253  }
254 
255  template <typename T>
256  void
257  doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
258  {
259  if (idx.size() < 1)
260  return;
261  UT_ASSERT(idx.size() == instance.size()+1);
262  if (idx.size() != instance.size()+1)
263  return;
264  switch (idx[0])
265  {
266  case 0:
267  coerceValue(value, myOutgroup);
268  break;
269  case 1:
270  coerceValue(value, myGroup);
271  break;
272  case 2:
273  coerceValue(value, myGrouptype);
274  break;
275  case 3:
276  coerceValue(value, myPathcontroltype);
277  break;
278  case 4:
279  coerceValue(value, myOperation);
280  break;
281  case 5:
282  coerceValue(value, myAvoidprevious);
283  break;
284  case 6:
285  coerceValue(value, myEdgestyle);
286  break;
287  case 7:
288  coerceValue(value, myUseuvattrib);
289  break;
290  case 8:
291  coerceValue(value, myUvattrib);
292  break;
293  case 9:
294  coerceValue(value, myUsecolgroup);
295  break;
296  case 10:
297  coerceValue(value, myColgroup);
298  break;
299  case 11:
300  coerceValue(value, myColgrouptype);
301  break;
302  case 12:
303  coerceValue(value, myColgroupinvert);
304  break;
305  case 13:
306  coerceValue(value, myColgrouponbnd);
307  break;
308 
309  }
310  }
311 
312  bool isParmColorRamp(exint idx) const override
313  {
314  switch (idx)
315  {
316 
317  }
318  return false;
319  }
320 
321  void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
322  { doGetParmValue(idx, instance, value); }
323  void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
324  { doGetParmValue(idx, instance, value); }
325  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
326  { doGetParmValue(idx, instance, value); }
327  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
328  { doGetParmValue(idx, instance, value); }
329  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
330  { doGetParmValue(idx, instance, value); }
331  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
332  { doGetParmValue(idx, instance, value); }
333  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
334  { doGetParmValue(idx, instance, value); }
335  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
336  { doGetParmValue(idx, instance, value); }
337  void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
338  { doGetParmValue(idx, instance, value); }
339  void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr<UT_Ramp> &value) const override
340  { doGetParmValue(idx, instance, value); }
341  void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
342  { doGetParmValue(idx, instance, value); }
343 
344  template <typename T>
345  void
346  doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
347  {
348  if (idx.size() < 1)
349  return;
350  UT_ASSERT(idx.size() == instance.size()+1);
351  if (idx.size() != instance.size()+1)
352  return;
353  switch (idx[0])
354  {
355  case 0:
356  coerceValue(myOutgroup, ( ( value ) ));
357  break;
358  case 1:
359  coerceValue(myGroup, ( ( value ) ));
360  break;
361  case 2:
362  coerceValue(myGrouptype, clampMinValue(0, clampMaxValue(4, value ) ));
363  break;
364  case 3:
365  coerceValue(myPathcontroltype, clampMinValue(0, clampMaxValue(2, value ) ));
366  break;
367  case 4:
368  coerceValue(myOperation, clampMinValue(0, clampMaxValue(2, value ) ));
369  break;
370  case 5:
371  coerceValue(myAvoidprevious, ( ( value ) ));
372  break;
373  case 6:
374  coerceValue(myEdgestyle, clampMinValue(0, clampMaxValue(2, value ) ));
375  break;
376  case 7:
377  coerceValue(myUseuvattrib, ( ( value ) ));
378  break;
379  case 8:
380  coerceValue(myUvattrib, ( ( value ) ));
381  break;
382  case 9:
383  coerceValue(myUsecolgroup, ( ( value ) ));
384  break;
385  case 10:
386  coerceValue(myColgroup, ( ( value ) ));
387  break;
388  case 11:
389  coerceValue(myColgrouptype, clampMinValue(0, clampMaxValue(4, value ) ));
390  break;
391  case 12:
392  coerceValue(myColgroupinvert, ( ( value ) ));
393  break;
394  case 13:
395  coerceValue(myColgrouponbnd, ( ( value ) ));
396  break;
397 
398  }
399  }
400 
401  void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
402  { doSetParmValue(idx, instance, value); }
403  void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
404  { doSetParmValue(idx, instance, value); }
405  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
406  { doSetParmValue(idx, instance, value); }
407  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
408  { doSetParmValue(idx, instance, value); }
409  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
410  { doSetParmValue(idx, instance, value); }
411  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
412  { doSetParmValue(idx, instance, value); }
413  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
414  { doSetParmValue(idx, instance, value); }
415  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
416  { doSetParmValue(idx, instance, value); }
417  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
418  { doSetParmValue(idx, instance, value); }
419  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr<UT_Ramp> &value) override
420  { doSetParmValue(idx, instance, value); }
421  void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
422  { doSetParmValue(idx, instance, value); }
423 
424  exint getNestNumParms(TempIndex idx) const override
425  {
426  if (idx.size() == 0)
427  return 14;
428  switch (idx[0])
429  {
430 
431  }
432  // Invalid
433  return 0;
434  }
435 
436  const char *getNestParmName(TempIndex fieldnum) const override
437  {
438  if (fieldnum.size() < 1)
439  return 0;
440  switch (fieldnum[0])
441  {
442  case 0:
443  return "outgroup";
444  case 1:
445  return "group";
446  case 2:
447  return "grouptype";
448  case 3:
449  return "pathcontroltype";
450  case 4:
451  return "operation";
452  case 5:
453  return "avoidprevious";
454  case 6:
455  return "edgestyle";
456  case 7:
457  return "useuvattrib";
458  case 8:
459  return "uvattrib";
460  case 9:
461  return "usecolgroup";
462  case 10:
463  return "colgroup";
464  case 11:
465  return "colgrouptype";
466  case 12:
467  return "colgroupinvert";
468  case 13:
469  return "colgrouponbnd";
470 
471  }
472  return 0;
473  }
474 
475  ParmType getNestParmType(TempIndex fieldnum) const override
476  {
477  if (fieldnum.size() < 1)
478  return PARM_UNSUPPORTED;
479  switch (fieldnum[0])
480  {
481  case 0:
482  return PARM_STRING;
483  case 1:
484  return PARM_STRING;
485  case 2:
486  return PARM_INTEGER;
487  case 3:
488  return PARM_INTEGER;
489  case 4:
490  return PARM_INTEGER;
491  case 5:
492  return PARM_INTEGER;
493  case 6:
494  return PARM_INTEGER;
495  case 7:
496  return PARM_INTEGER;
497  case 8:
498  return PARM_STRING;
499  case 9:
500  return PARM_INTEGER;
501  case 10:
502  return PARM_STRING;
503  case 11:
504  return PARM_INTEGER;
505  case 12:
506  return PARM_INTEGER;
507  case 13:
508  return PARM_INTEGER;
509 
510  }
511  return PARM_UNSUPPORTED;
512  }
513 
514  // Boiler plate to load individual types.
515  static void loadData(UT_IStream &is, int64 &v)
516  { is.bread(&v, 1); }
517  static void loadData(UT_IStream &is, bool &v)
518  { int64 iv; is.bread(&iv, 1); v = iv; }
519  static void loadData(UT_IStream &is, fpreal64 &v)
520  { is.bread<fpreal64>(&v, 1); }
521  static void loadData(UT_IStream &is, UT_Vector2D &v)
522  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1); }
523  static void loadData(UT_IStream &is, UT_Vector3D &v)
524  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
525  is.bread<fpreal64>(&v.z(), 1); }
526  static void loadData(UT_IStream &is, UT_Vector4D &v)
527  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
528  is.bread<fpreal64>(&v.z(), 1); is.bread<fpreal64>(&v.w(), 1); }
529  static void loadData(UT_IStream &is, UT_Matrix2D &v)
530  { for (int r = 0; r < 2; r++) for (int c = 0; c < 2; c++) is.bread<fpreal64>(&v(r, c), 1); }
531  static void loadData(UT_IStream &is, UT_Matrix3D &v)
532  { for (int r = 0; r < 3; r++) for (int c = 0; c < 3; c++) is.bread<fpreal64>(&v(r, c), 1); }
533  static void loadData(UT_IStream &is, UT_Matrix4D &v)
534  { for (int r = 0; r < 4; r++) for (int c = 0; c < 4; c++) is.bread<fpreal64>(&v(r, c), 1); }
535  static void loadData(UT_IStream &is, UT_Vector2I &v)
536  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1); }
537  static void loadData(UT_IStream &is, UT_Vector3I &v)
538  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
539  is.bread<int64>(&v.z(), 1); }
540  static void loadData(UT_IStream &is, UT_Vector4I &v)
541  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
542  is.bread<int64>(&v.z(), 1); is.bread<int64>(&v.w(), 1); }
544  { is.bread(v); }
546  { UT_StringHolder rampdata;
547  loadData(is, rampdata);
548  if (rampdata.isstring())
549  {
550  v.reset(new UT_Ramp());
551  UT_IStream istr((const char *) rampdata, rampdata.length(), UT_ISTREAM_ASCII);
552  v->load(istr);
553  }
554  else v.reset();
555  }
558  loadData(is, data);
559  if (data.isstring())
560  {
561  // Find the data type.
562  const char *colon = UT_StringWrap(data).findChar(':');
563  if (colon)
564  {
565  int typelen = colon - data.buffer();
567  type.strncpy(data.buffer(), typelen);
568  UT_IStream istr(((const char *) data) + typelen + 1, data.length() - (typelen + 1), UT_ISTREAM_BINARY);
569 
570  v = PRM_DataFactory::parseBinary(type.buffer(), istr);
571  }
572  }
573  else v.reset();
574  }
575 
576  static void saveData(std::ostream &os, int64 v)
577  { UTwrite(os, &v); }
578  static void saveData(std::ostream &os, bool v)
579  { int64 iv = v; UTwrite(os, &iv); }
580  static void saveData(std::ostream &os, fpreal64 v)
581  { UTwrite<fpreal64>(os, &v); }
582  static void saveData(std::ostream &os, UT_Vector2D v)
583  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y()); }
584  static void saveData(std::ostream &os, UT_Vector3D v)
585  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
586  UTwrite<fpreal64>(os, &v.z()); }
587  static void saveData(std::ostream &os, UT_Vector4D v)
588  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
589  UTwrite<fpreal64>(os, &v.z()); UTwrite<fpreal64>(os, &v.w()); }
590  static void saveData(std::ostream &os, UT_Matrix2D v)
592  static void saveData(std::ostream &os, UT_Matrix3D v)
594  static void saveData(std::ostream &os, UT_Matrix4D v)
596  static void saveData(std::ostream &os, UT_StringHolder s)
597  { UT_StringWrap(s).saveBinary(os); }
598  static void saveData(std::ostream &os, UT_SharedPtr<UT_Ramp> s)
600  UT_OStringStream ostr;
601  if (s) s->save(ostr);
602  result = ostr.str();
603  saveData(os, result);
604  }
605  static void saveData(std::ostream &os, PRM_DataItemHandle s)
607  UT_OStringStream ostr;
608  if (s)
609  {
610  ostr << s->getDataTypeToken();
611  ostr << ":";
612  s->saveBinary(ostr);
613  }
614  result = ostr.str();
615  saveData(os, result);
616  }
617 
618 
619  void save(std::ostream &os) const
620  {
621  int32 v = version();
622  UTwrite(os, &v);
623  saveData(os, myOutgroup);
624  saveData(os, myGroup);
625  saveData(os, myGrouptype);
626  saveData(os, myPathcontroltype);
627  saveData(os, myOperation);
628  saveData(os, myAvoidprevious);
629  saveData(os, myEdgestyle);
630  saveData(os, myUseuvattrib);
631  saveData(os, myUvattrib);
632  saveData(os, myUsecolgroup);
633  saveData(os, myColgroup);
634  saveData(os, myColgrouptype);
635  saveData(os, myColgroupinvert);
636  saveData(os, myColgrouponbnd);
637 
638  }
639 
640  bool load(UT_IStream &is)
641  {
642  int32 v;
643  is.bread(&v, 1);
644  if (version() != v)
645  {
646  // Fail incompatible versions
647  return false;
648  }
649  loadData(is, myOutgroup);
650  loadData(is, myGroup);
651  loadData(is, myGrouptype);
652  loadData(is, myPathcontroltype);
653  loadData(is, myOperation);
654  loadData(is, myAvoidprevious);
655  loadData(is, myEdgestyle);
656  loadData(is, myUseuvattrib);
657  loadData(is, myUvattrib);
658  loadData(is, myUsecolgroup);
659  loadData(is, myColgroup);
660  loadData(is, myColgrouptype);
661  loadData(is, myColgroupinvert);
662  loadData(is, myColgrouponbnd);
663 
664  return true;
665  }
666 
667  const UT_StringHolder & getOutgroup() const { return myOutgroup; }
668  void setOutgroup(const UT_StringHolder & val) { myOutgroup = val; }
670  {
671  SOP_Node *thissop = cookparms.getNode();
672  if (!thissop) return getOutgroup();
674  OP_Utils::evalOpParm(result, thissop, "outgroup", cookparms.getCookTime(), 0);
675  return result;
676  }
677  const UT_StringHolder & getGroup() const { return myGroup; }
678  void setGroup(const UT_StringHolder & val) { myGroup = val; }
680  {
681  SOP_Node *thissop = cookparms.getNode();
682  if (!thissop) return getGroup();
684  OP_Utils::evalOpParm(result, thissop, "group", cookparms.getCookTime(), 0);
685  return result;
686  }
687  Grouptype getGrouptype() const { return Grouptype(myGrouptype); }
688  void setGrouptype(Grouptype val) { myGrouptype = int64(val); }
690  {
691  SOP_Node *thissop = cookparms.getNode();
692  if (!thissop) return getGrouptype();
693  int64 result;
694  OP_Utils::evalOpParm(result, thissop, "grouptype", cookparms.getCookTime(), 0);
695  return Grouptype(result);
696  }
697  Pathcontroltype getPathcontroltype() const { return Pathcontroltype(myPathcontroltype); }
698  void setPathcontroltype(Pathcontroltype val) { myPathcontroltype = int64(val); }
700  {
701  SOP_Node *thissop = cookparms.getNode();
702  if (!thissop) return getPathcontroltype();
703  int64 result;
704  OP_Utils::evalOpParm(result, thissop, "pathcontroltype", cookparms.getCookTime(), 0);
705  return Pathcontroltype(result);
706  }
707  Operation getOperation() const { return Operation(myOperation); }
708  void setOperation(Operation val) { myOperation = int64(val); }
710  {
711  SOP_Node *thissop = cookparms.getNode();
712  if (!thissop) return getOperation();
713  int64 result;
714  OP_Utils::evalOpParm(result, thissop, "operation", cookparms.getCookTime(), 0);
715  return Operation(result);
716  }
717  bool getAvoidprevious() const { return myAvoidprevious; }
718  void setAvoidprevious(bool val) { myAvoidprevious = val; }
719  bool opAvoidprevious(const SOP_NodeVerb::CookParms &cookparms) const
720  {
721  SOP_Node *thissop = cookparms.getNode();
722  if (!thissop) return getAvoidprevious();
723  bool result;
724  OP_Utils::evalOpParm(result, thissop, "avoidprevious", cookparms.getCookTime(), 0);
725  return result;
726  }
727  Edgestyle getEdgestyle() const { return Edgestyle(myEdgestyle); }
728  void setEdgestyle(Edgestyle val) { myEdgestyle = int64(val); }
730  {
731  SOP_Node *thissop = cookparms.getNode();
732  if (!thissop) return getEdgestyle();
733  int64 result;
734  OP_Utils::evalOpParm(result, thissop, "edgestyle", cookparms.getCookTime(), 0);
735  return Edgestyle(result);
736  }
737  bool getUseuvattrib() const { return myUseuvattrib; }
738  void setUseuvattrib(bool val) { myUseuvattrib = val; }
739  bool opUseuvattrib(const SOP_NodeVerb::CookParms &cookparms) const
740  {
741  SOP_Node *thissop = cookparms.getNode();
742  if (!thissop) return getUseuvattrib();
743  bool result;
744  OP_Utils::evalOpParm(result, thissop, "useuvattrib", cookparms.getCookTime(), 0);
745  return result;
746  }
747  const UT_StringHolder & getUvattrib() const { return myUvattrib; }
748  void setUvattrib(const UT_StringHolder & val) { myUvattrib = val; }
750  {
751  SOP_Node *thissop = cookparms.getNode();
752  if (!thissop) return getUvattrib();
754  OP_Utils::evalOpParm(result, thissop, "uvattrib", cookparms.getCookTime(), 0);
755  return result;
756  }
757  bool getUsecolgroup() const { return myUsecolgroup; }
758  void setUsecolgroup(bool val) { myUsecolgroup = val; }
759  bool opUsecolgroup(const SOP_NodeVerb::CookParms &cookparms) const
760  {
761  SOP_Node *thissop = cookparms.getNode();
762  if (!thissop) return getUsecolgroup();
763  bool result;
764  OP_Utils::evalOpParm(result, thissop, "usecolgroup", cookparms.getCookTime(), 0);
765  return result;
766  }
767  const UT_StringHolder & getColgroup() const { return myColgroup; }
768  void setColgroup(const UT_StringHolder & val) { myColgroup = val; }
770  {
771  SOP_Node *thissop = cookparms.getNode();
772  if (!thissop) return getColgroup();
774  OP_Utils::evalOpParm(result, thissop, "colgroup", cookparms.getCookTime(), 0);
775  return result;
776  }
777  Colgrouptype getColgrouptype() const { return Colgrouptype(myColgrouptype); }
778  void setColgrouptype(Colgrouptype val) { myColgrouptype = int64(val); }
780  {
781  SOP_Node *thissop = cookparms.getNode();
782  if (!thissop) return getColgrouptype();
783  int64 result;
784  OP_Utils::evalOpParm(result, thissop, "colgrouptype", cookparms.getCookTime(), 0);
785  return Colgrouptype(result);
786  }
787  bool getColgroupinvert() const { return myColgroupinvert; }
788  void setColgroupinvert(bool val) { myColgroupinvert = val; }
789  bool opColgroupinvert(const SOP_NodeVerb::CookParms &cookparms) const
790  {
791  SOP_Node *thissop = cookparms.getNode();
792  if (!thissop) return getColgroupinvert();
793  bool result;
794  OP_Utils::evalOpParm(result, thissop, "colgroupinvert", cookparms.getCookTime(), 0);
795  return result;
796  }
797  bool getColgrouponbnd() const { return myColgrouponbnd; }
798  void setColgrouponbnd(bool val) { myColgrouponbnd = val; }
799  bool opColgrouponbnd(const SOP_NodeVerb::CookParms &cookparms) const
800  {
801  SOP_Node *thissop = cookparms.getNode();
802  if (!thissop) return getColgrouponbnd();
803  bool result;
804  OP_Utils::evalOpParm(result, thissop, "colgrouponbnd", cookparms.getCookTime(), 0);
805  return result;
806  }
807 
808 private:
809  UT_StringHolder myOutgroup;
810  UT_StringHolder myGroup;
811  int64 myGrouptype;
812  int64 myPathcontroltype;
813  int64 myOperation;
814  bool myAvoidprevious;
815  int64 myEdgestyle;
816  bool myUseuvattrib;
817  UT_StringHolder myUvattrib;
818  bool myUsecolgroup;
819  UT_StringHolder myColgroup;
820  int64 myColgrouptype;
821  bool myColgroupinvert;
822  bool myColgrouponbnd;
823 
824 };
type
Definition: core.h:556
void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
static void loadData(UT_IStream &is, UT_Vector4D &v)
void copyFrom(const OP_NodeParms *src) override
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
const char * getNestParmName(TempIndex fieldnum) const override
int int32
Definition: SYS_Types.h:39
SOP_Node * getNode() const
Definition: SOP_NodeVerb.h:347
Grouptype opGrouptype(const SOP_NodeVerb::CookParms &cookparms) const
void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
static void loadData(UT_IStream &is, UT_Vector4I &v)
static void saveData(std::ostream &os, UT_Vector2D v)
void doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
Pathcontroltype getPathcontroltype() const
exint bread(int32 *buffer, exint asize=1)
GLboolean * data
Definition: glcorearb.h:131
GT_API const UT_StringHolder time
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector4.h:493
const GLdouble * v
Definition: glcorearb.h:837
fpreal getTime() const
Definition: OP_Context.h:63
GLsizei const GLfloat * value
Definition: glcorearb.h:824
void buildFromOp(const OP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
bool opAvoidprevious(const SOP_NodeVerb::CookParms &cookparms) const
void setColgroup(const UT_StringHolder &val)
const OP_Context & context() const
Definition: OP_NodeParms.h:97
static void loadData(UT_IStream &is, int64 &v)
constexpr SYS_FORCE_INLINE T & z() noexcept
Definition: UT_Vector3.h:667
int64 exint
Definition: SYS_Types.h:125
Operation opOperation(const SOP_NodeVerb::CookParms &cookparms) const
SYS_FORCE_INLINE const char * buffer() const
GLdouble s
Definition: glad.h:3009
static void saveData(std::ostream &os, bool v)
void setPathcontroltype(Pathcontroltype val)
An output stream object that owns its own string buffer storage.
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
void setEdgestyle(Edgestyle val)
void setOperation(Operation val)
**But if you need a result
Definition: thread.h:622
const UT_StringHolder & getUvattrib() const
exint nodeIdx() const
Definition: OP_NodeParms.h:95
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
const UT_WorkBuffer & str()
Returns a read-only reference to the underlying UT_WorkBuffer.
bool opColgrouponbnd(const SOP_NodeVerb::CookParms &cookparms) const
Colgrouptype opColgrouptype(const SOP_NodeVerb::CookParms &cookparms) const
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector4.h:491
void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
static void saveData(std::ostream &os, fpreal64 v)
const UT_StringHolder & getGroup() const
static void saveData(std::ostream &os, UT_Matrix4D v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
static void loadData(UT_IStream &is, UT_Matrix4D &v)
double fpreal64
Definition: SYS_Types.h:201
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
Definition: APEX_Include.h:55
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector2.h:423
bool operator==(const SOP_GroupFindPathParms &src) const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
void setGroup(const UT_StringHolder &val)
void setGrouptype(Grouptype val)
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
Definition: Dimensions.h:137
static void loadData(UT_IStream &is, UT_Vector2I &v)
ParmType getNestParmType(TempIndex fieldnum) const override
bool isParmColorRamp(exint idx) const override
const UT_StringHolder & getColgroup() const
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
exint length() const
UT_StringHolder opOutgroup(const SOP_NodeVerb::CookParms &cookparms) const
SYS_FORCE_INLINE const char * buffer() const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
Definition: UT_SharedPtr.h:36
constexpr SYS_FORCE_INLINE T & z() noexcept
Definition: UT_Vector4.h:495
bool opUsecolgroup(const SOP_NodeVerb::CookParms &cookparms) const
const OP_GraphProxy * graph() const
Definition: OP_NodeParms.h:94
#define SYS_FORCE_INLINE
Definition: SYS_Inline.h:45
static void loadData(UT_IStream &is, UT_Matrix2D &v)
static void saveData(std::ostream &os, UT_StringHolder s)
exint getNestNumParms(TempIndex idx) const override
UT_StringHolder opColgroup(const SOP_NodeVerb::CookParms &cookparms) const
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr< UT_Ramp > &value) override
long long int64
Definition: SYS_Types.h:116
static void saveData(std::ostream &os, UT_Matrix2D v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
bool operator!=(const SOP_GroupFindPathParms &src) const
static void loadData(UT_IStream &is, UT_Vector2D &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr< UT_Ramp > &value) const override
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
static void saveData(std::ostream &os, UT_Vector3D v)
static void saveData(std::ostream &os, int64 v)
UT_StringHolder opUvattrib(const SOP_NodeVerb::CookParms &cookparms) const
SYS_FORCE_INLINE UT_StringHolder getToken(Grouptype enum_value)
void setOutgroup(const UT_StringHolder &val)
virtual void evalOpParm(int64 &v, NodeIdx node, const char *parmname, fpreal time, DEP_MicroNode *depnode) const =0
Colgrouptype getColgrouptype() const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
void saveBinary(std::ostream &os) const
Save string to binary stream.
Definition: UT_String.h:303
void loadFromOpSubclass(const LoadParms &loadparms) override
GT_API const UT_StringHolder version
static void loadData(UT_IStream &is, UT_Vector3I &v)
void doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
static void saveData(std::ostream &os, PRM_DataItemHandle s)
void setUvattrib(const UT_StringHolder &val)
void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
fpreal64 fpreal
Definition: SYS_Types.h:278
DEP_MicroNode * depnode() const
Definition: OP_NodeParms.h:99
LeafData & operator=(const LeafData &)=delete
Utility class for containing a color ramp.
Definition: UT_Ramp.h:96
constexpr SYS_FORCE_INLINE T & w() noexcept
Definition: UT_Vector4.h:497
static void loadData(UT_IStream &is, UT_StringHolder &v)
GLuint GLfloat * val
Definition: glcorearb.h:1608
virtual UT_StringHolder baseGetSignature() const
Definition: OP_NodeParms.h:294
#define SOP_API
Definition: SOP_API.h:10
static void loadData(UT_IStream &is, bool &v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
fpreal getCookTime() const
Definition: SOP_NodeVerb.h:372
static void loadData(UT_IStream &is, fpreal64 &v)
const char * findChar(int c) const
Definition: UT_String.h:1401
#define UT_ASSERT(ZZ)
Definition: UT_Assert.h:156
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
Edgestyle opEdgestyle(const SOP_NodeVerb::CookParms &cookparms) const
bool opUseuvattrib(const SOP_NodeVerb::CookParms &cookparms) const
UT_StringHolder opGroup(const SOP_NodeVerb::CookParms &cookparms) const
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
GLboolean r
Definition: glcorearb.h:1222
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
void save(std::ostream &os) const
static void saveData(std::ostream &os, UT_Vector4D v)
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector3.h:665
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
const UT_StringHolder & getOutgroup() const
virtual bool isDirect() const =0
Direct proxies mirror actual nodes:
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
static void loadData(UT_IStream &is, UT_Vector3D &v)
static void saveData(std::ostream &os, UT_Matrix3D v)
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector2.h:425
SYS_FORCE_INLINE bool isstring() const
void setColgrouptype(Colgrouptype val)
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
static void loadData(UT_IStream &is, UT_Matrix3D &v)
Pathcontroltype opPathcontroltype(const SOP_NodeVerb::CookParms &cookparms) const
GLenum src
Definition: glcorearb.h:1793
bool opColgroupinvert(const SOP_NodeVerb::CookParms &cookparms) const
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector3.h:663