HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
SOP_Delete.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_DeleteEnums
22 {
23  enum class Negate
24  {
25  DELE = 0,
26  KEEP
27  };
28  enum class Entity
29  {
30  PRIMITIVE = 0,
31  POINT,
32  EDGE
33  };
34  enum class Groupop
35  {
36  PATTERN = 0,
37  RANGE,
38  FILTER
39  };
40  enum class Boundtype
41  {
42  USEBBOX = 0,
44  };
45 }
46 
47 
49 {
50 public:
51  static int version() { return 1; }
52 
54  {
55  myGroup = ""_sh;
56  myNegate = 0;
57  myEntity = 0;
58  myAffectnumber = false;
59  myGroupop = 0;
60  myFilter = 1;
61  myPattern = "!*"_sh;
62  myRange = UT_Vector2I(0,0);
63  mySelect = UT_Vector2I(1,2);
64  myAffectvolume = false;
65  myBoundtype = 0;
66  mySize = UT_Vector3D(1,1,1);
67  myT = UT_Vector3D(0,0,0);
68  myAffectnormal = false;
69  myCamerapath = ""_sh;
70  myAffectdegenerate = false;
71  myDegenerate = false;
72  myZaf = false;
73  myDoopen = false;
74  myTol = 0.001;
75  myRemovegrp = false;
76  myKeeppoints = false;
77  myGeotype = 0;
78  myDir = UT_Vector3D(0,0,1);
79  myAngle = 180;
80 
81  }
82 
83  explicit SOP_DeleteParms(const SOP_DeleteParms &) = default;
84 
85  virtual ~SOP_DeleteParms() {}
86 
87  bool operator==(const SOP_DeleteParms &src) const
88  {
89  if (myGroup != src.myGroup) return false;
90  if (myNegate != src.myNegate) return false;
91  if (myEntity != src.myEntity) return false;
92  if (myAffectnumber != src.myAffectnumber) return false;
93  if (myGroupop != src.myGroupop) return false;
94  if (myFilter != src.myFilter) return false;
95  if (myPattern != src.myPattern) return false;
96  if (myRange != src.myRange) return false;
97  if (mySelect != src.mySelect) return false;
98  if (myAffectvolume != src.myAffectvolume) return false;
99  if (myBoundtype != src.myBoundtype) return false;
100  if (mySize != src.mySize) return false;
101  if (myT != src.myT) return false;
102  if (myAffectnormal != src.myAffectnormal) return false;
103  if (myCamerapath != src.myCamerapath) return false;
104  if (myAffectdegenerate != src.myAffectdegenerate) return false;
105  if (myDegenerate != src.myDegenerate) return false;
106  if (myZaf != src.myZaf) return false;
107  if (myDoopen != src.myDoopen) return false;
108  if (myTol != src.myTol) return false;
109  if (myRemovegrp != src.myRemovegrp) return false;
110  if (myKeeppoints != src.myKeeppoints) return false;
111  if (myGeotype != src.myGeotype) return false;
112  if (myDir != src.myDir) return false;
113  if (myAngle != src.myAngle) return false;
114 
115  return true;
116  }
121 
122 
123 
124  void buildFromOp(const OP_Node *node, fpreal time, DEP_MicroNode *depnode)
125  {
126  if (true)
127  OP_Utils::evalOpParm(myGroup, node, "group", time, 0);
128  else myGroup = ""_sh;
129  if (true)
130  OP_Utils::evalOpParm(myNegate, node, "negate", time, 0);
131  else myNegate = 0;
132  if (true)
133  OP_Utils::evalOpParm(myEntity, node, "entity", time, 0);
134  else myEntity = 0;
135  if (true)
136  OP_Utils::evalOpParm(myAffectnumber, node, "affectnumber", time, 0);
137  else myAffectnumber = false;
138  if (true && ( (!(((getAffectnumber()==0)))) ) )
139  OP_Utils::evalOpParm(myGroupop, node, "groupop", time, 0);
140  else myGroupop = 0;
141  if (true && ( (!(((getAffectnumber()==0))||((int64(getGroupop())!=2)))) ) )
142  OP_Utils::evalOpParm(myFilter, node, "filter", time, 0);
143  else myFilter = 1;
144  if (true && ( (!(((getAffectnumber()==0))||((int64(getGroupop())!=0)))) ) )
145  OP_Utils::evalOpParm(myPattern, node, "pattern", time, 0);
146  else myPattern = "!*"_sh;
147  if (true && ( (!(((getAffectnumber()==0))||((int64(getGroupop())!=1)))) ) )
148  OP_Utils::evalOpParm(myRange, node, "range", time, 0);
149  else myRange = UT_Vector2I(0,0);
150  if (true && ( (!(((getAffectnumber()==0))||((int64(getGroupop())!=1)))) ) )
151  OP_Utils::evalOpParm(mySelect, node, "select", time, 0);
152  else mySelect = UT_Vector2I(1,2);
153  if (true)
154  OP_Utils::evalOpParm(myAffectvolume, node, "affectvolume", time, 0);
155  else myAffectvolume = false;
156  if (true && ( (!(((getAffectvolume()==0)))) ) )
157  OP_Utils::evalOpParm(myBoundtype, node, "boundtype", time, 0);
158  else myBoundtype = 0;
159  if (true && ( (!(((getAffectvolume()==0)))) ) )
160  OP_Utils::evalOpParm(mySize, node, "size", time, 0);
161  else mySize = UT_Vector3D(1,1,1);
162  if (true && ( (!(((getAffectvolume()==0)))) ) )
163  OP_Utils::evalOpParm(myT, node, "t", time, 0);
164  else myT = UT_Vector3D(0,0,0);
165  if (true)
166  OP_Utils::evalOpParm(myAffectnormal, node, "affectnormal", time, 0);
167  else myAffectnormal = false;
168  if (true && ( (!(((getAffectnormal()==0)))) ) )
169  OP_Utils::evalOpParm(myCamerapath, node, "camerapath", time, 0);
170  else myCamerapath = ""_sh;
171  if (true)
172  OP_Utils::evalOpParm(myAffectdegenerate, node, "affectdegenerate", time, 0);
173  else myAffectdegenerate = false;
174  if (true && ( (!(((getAffectdegenerate()==0)))) ) )
175  OP_Utils::evalOpParm(myDegenerate, node, "degenerate", time, 0);
176  else myDegenerate = false;
177  if (true && ( (!(((getAffectdegenerate()==0))||((int64(getEntity())!=0)))) ) )
178  OP_Utils::evalOpParm(myZaf, node, "zaf", time, 0);
179  else myZaf = false;
180  if (true && ( (!(((getAffectdegenerate()==0))||((int64(getEntity())!=0))||((getZaf()==0)))) ) )
181  OP_Utils::evalOpParm(myDoopen, node, "doopen", time, 0);
182  else myDoopen = false;
183  if (true && ( (!(((getAffectdegenerate()==0))||((getZaf()==0)&&(getDegenerate()==0)))) ) )
184  OP_Utils::evalOpParm(myTol, node, "tol", time, 0);
185  else myTol = 0.001;
186  if (true)
187  OP_Utils::evalOpParm(myRemovegrp, node, "removegrp", time, 0);
188  else myRemovegrp = false;
189  if (true && ( (!(((int64(getEntity())!=0)))) ) )
190  OP_Utils::evalOpParm(myKeeppoints, node, "keeppoints", time, 0);
191  else myKeeppoints = false;
192  if (true && ( (!(((getAffectnumber()==0)&&(getAffectvolume()==0)&&(getAffectnormal()==0)&&(getAffectdegenerate()==0)))) ) )
193  OP_Utils::evalOpParm(myGeotype, node, "geotype", time, 0);
194  else myGeotype = 0;
195  if (true && ( (!(((getAffectnormal()==0))||((getCamerapath()!="")))) ) )
196  OP_Utils::evalOpParm(myDir, node, "dir", time, 0);
197  else myDir = UT_Vector3D(0,0,1);
198  if (true && ( (!(((getAffectnormal()==0))||((getCamerapath()!="")))) ) )
199  OP_Utils::evalOpParm(myAngle, node, "angle", time, 0);
200  else myAngle = 180;
201 
202  }
203 
204 
205  virtual void loadFromOpSubclass(const LoadParms &loadparms)
206  {
207  buildFromOp(loadparms.node(), loadparms.context().getTime(), loadparms.depnode());
208  }
209 
210 
211  virtual void copyFrom(const SOP_NodeParms *src)
212  {
213  *this = *((const SOP_DeleteParms *)src);
214  }
215 
216  template <typename T>
217  void
218  doGetParmValue(exint idx, T &value) const
219  {
220  switch (idx)
221  {
222  case 0:
223  coerceValue(value, myGroup);
224  break;
225  case 1:
226  coerceValue(value, myNegate);
227  break;
228  case 2:
229  coerceValue(value, myEntity);
230  break;
231  case 3:
232  coerceValue(value, myAffectnumber);
233  break;
234  case 4:
235  coerceValue(value, myGroupop);
236  break;
237  case 5:
238  coerceValue(value, myFilter);
239  break;
240  case 6:
241  coerceValue(value, myPattern);
242  break;
243  case 7:
244  coerceValue(value, myRange);
245  break;
246  case 8:
247  coerceValue(value, mySelect);
248  break;
249  case 9:
250  coerceValue(value, myAffectvolume);
251  break;
252  case 10:
253  coerceValue(value, myBoundtype);
254  break;
255  case 11:
256  coerceValue(value, mySize);
257  break;
258  case 12:
259  coerceValue(value, myT);
260  break;
261  case 13:
262  coerceValue(value, myAffectnormal);
263  break;
264  case 14:
265  coerceValue(value, myCamerapath);
266  break;
267  case 15:
268  coerceValue(value, myAffectdegenerate);
269  break;
270  case 16:
271  coerceValue(value, myDegenerate);
272  break;
273  case 17:
274  coerceValue(value, myZaf);
275  break;
276  case 18:
277  coerceValue(value, myDoopen);
278  break;
279  case 19:
280  coerceValue(value, myTol);
281  break;
282  case 20:
283  coerceValue(value, myRemovegrp);
284  break;
285  case 21:
286  coerceValue(value, myKeeppoints);
287  break;
288  case 22:
289  coerceValue(value, myGeotype);
290  break;
291  case 23:
292  coerceValue(value, myDir);
293  break;
294  case 24:
295  coerceValue(value, myAngle);
296  break;
297 
298  }
299  }
300 
301  void getParmValue(exint idx, exint &value) const
302  { doGetParmValue(idx, value); }
303  void getParmValue(exint idx, fpreal &value) const
304  { doGetParmValue(idx, value); }
306  { doGetParmValue(idx, value); }
308  { doGetParmValue(idx, value); }
310  { doGetParmValue(idx, value); }
312  { doGetParmValue(idx, value); }
314  { doGetParmValue(idx, value); }
316  { doGetParmValue(idx, value); }
318  { doGetParmValue(idx, value); }
320  { doGetParmValue(idx, value); }
322  { doGetParmValue(idx, value); }
323 
324  template <typename T>
325  void
326  doSetParmValue(exint idx, const T &value)
327  {
328  switch (idx)
329  {
330  case 0:
331  coerceValue(myGroup, value);
332  break;
333  case 1:
334  coerceValue(myNegate, value);
335  break;
336  case 2:
337  coerceValue(myEntity, value);
338  break;
339  case 3:
340  coerceValue(myAffectnumber, value);
341  break;
342  case 4:
343  coerceValue(myGroupop, value);
344  break;
345  case 5:
346  coerceValue(myFilter, value);
347  break;
348  case 6:
349  coerceValue(myPattern, value);
350  break;
351  case 7:
352  coerceValue(myRange, value);
353  break;
354  case 8:
355  coerceValue(mySelect, value);
356  break;
357  case 9:
358  coerceValue(myAffectvolume, value);
359  break;
360  case 10:
361  coerceValue(myBoundtype, value);
362  break;
363  case 11:
364  coerceValue(mySize, value);
365  break;
366  case 12:
367  coerceValue(myT, value);
368  break;
369  case 13:
370  coerceValue(myAffectnormal, value);
371  break;
372  case 14:
373  coerceValue(myCamerapath, value);
374  break;
375  case 15:
376  coerceValue(myAffectdegenerate, value);
377  break;
378  case 16:
379  coerceValue(myDegenerate, value);
380  break;
381  case 17:
382  coerceValue(myZaf, value);
383  break;
384  case 18:
385  coerceValue(myDoopen, value);
386  break;
387  case 19:
388  coerceValue(myTol, value);
389  break;
390  case 20:
391  coerceValue(myRemovegrp, value);
392  break;
393  case 21:
394  coerceValue(myKeeppoints, value);
395  break;
396  case 22:
397  coerceValue(myGeotype, value);
398  break;
399  case 23:
400  coerceValue(myDir, value);
401  break;
402  case 24:
403  coerceValue(myAngle, value);
404  break;
405 
406  }
407  }
408 
409  void setParmValue(exint idx, const exint &value)
410  { doSetParmValue(idx, value); }
411  void setParmValue(exint idx, const fpreal &value)
412  { doSetParmValue(idx, value); }
413  void setParmValue(exint idx, const UT_Vector2D &value)
414  { doSetParmValue(idx, value); }
415  void setParmValue(exint idx, const UT_Vector3D &value)
416  { doSetParmValue(idx, value); }
417  void setParmValue(exint idx, const UT_Vector4D &value)
418  { doSetParmValue(idx, value); }
419  void setParmValue(exint idx, const UT_Matrix2D &value)
420  { doSetParmValue(idx, value); }
421  void setParmValue(exint idx, const UT_Matrix3D &value)
422  { doSetParmValue(idx, value); }
423  void setParmValue(exint idx, const UT_Matrix4D &value)
424  { doSetParmValue(idx, value); }
426  { doSetParmValue(idx, value); }
428  { doSetParmValue(idx, value); }
430  { doSetParmValue(idx, value); }
431 
432  virtual exint getNumParms() const
433  {
434  return 25;
435  }
436 
437  virtual const char *getParmName(exint fieldnum) const
438  {
439  switch (fieldnum)
440  {
441  case 0:
442  return "group";
443  case 1:
444  return "negate";
445  case 2:
446  return "entity";
447  case 3:
448  return "affectnumber";
449  case 4:
450  return "groupop";
451  case 5:
452  return "filter";
453  case 6:
454  return "pattern";
455  case 7:
456  return "range";
457  case 8:
458  return "select";
459  case 9:
460  return "affectvolume";
461  case 10:
462  return "boundtype";
463  case 11:
464  return "size";
465  case 12:
466  return "t";
467  case 13:
468  return "affectnormal";
469  case 14:
470  return "camerapath";
471  case 15:
472  return "affectdegenerate";
473  case 16:
474  return "degenerate";
475  case 17:
476  return "zaf";
477  case 18:
478  return "doopen";
479  case 19:
480  return "tol";
481  case 20:
482  return "removegrp";
483  case 21:
484  return "keeppoints";
485  case 22:
486  return "geotype";
487  case 23:
488  return "dir";
489  case 24:
490  return "angle";
491 
492  }
493  return 0;
494  }
495 
496  virtual ParmType getParmType(exint fieldnum) const
497  {
498  switch (fieldnum)
499  {
500  case 0:
501  return PARM_STRING;
502  case 1:
503  return PARM_INTEGER;
504  case 2:
505  return PARM_INTEGER;
506  case 3:
507  return PARM_INTEGER;
508  case 4:
509  return PARM_INTEGER;
510  case 5:
511  return PARM_INTEGER;
512  case 6:
513  return PARM_STRING;
514  case 7:
515  return PARM_VECTOR2;
516  case 8:
517  return PARM_VECTOR2;
518  case 9:
519  return PARM_INTEGER;
520  case 10:
521  return PARM_INTEGER;
522  case 11:
523  return PARM_VECTOR3;
524  case 12:
525  return PARM_VECTOR3;
526  case 13:
527  return PARM_INTEGER;
528  case 14:
529  return PARM_STRING;
530  case 15:
531  return PARM_INTEGER;
532  case 16:
533  return PARM_INTEGER;
534  case 17:
535  return PARM_INTEGER;
536  case 18:
537  return PARM_INTEGER;
538  case 19:
539  return PARM_FLOAT;
540  case 20:
541  return PARM_INTEGER;
542  case 21:
543  return PARM_INTEGER;
544  case 22:
545  return PARM_INTEGER;
546  case 23:
547  return PARM_VECTOR3;
548  case 24:
549  return PARM_FLOAT;
550 
551  }
552  return PARM_UNSUPPORTED;
553  }
554 
555  // Boiler plate to load individual types.
556  static void loadData(UT_IStream &is, int64 &v)
557  { is.bread(&v, 1); }
558  static void loadData(UT_IStream &is, bool &v)
559  { int64 iv; is.bread(&iv, 1); v = iv; }
560  static void loadData(UT_IStream &is, fpreal64 &v)
561  { is.bread<fpreal64>(&v, 1); }
562  static void loadData(UT_IStream &is, UT_Vector2D &v)
563  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1); }
564  static void loadData(UT_IStream &is, UT_Vector3D &v)
565  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
566  is.bread<fpreal64>(&v.z(), 1); }
567  static void loadData(UT_IStream &is, UT_Vector4D &v)
568  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
569  is.bread<fpreal64>(&v.z(), 1); is.bread<fpreal64>(&v.w(), 1); }
570  static void loadData(UT_IStream &is, UT_Matrix2D &v)
571  { for (int r = 0; r < 2; r++) for (int c = 0; c < 2; c++) is.bread<fpreal64>(&v(r, c), 1); }
572  static void loadData(UT_IStream &is, UT_Matrix3D &v)
573  { for (int r = 0; r < 3; r++) for (int c = 0; c < 3; c++) is.bread<fpreal64>(&v(r, c), 1); }
574  static void loadData(UT_IStream &is, UT_Matrix4D &v)
575  { for (int r = 0; r < 4; r++) for (int c = 0; c < 4; c++) is.bread<fpreal64>(&v(r, c), 1); }
576  static void loadData(UT_IStream &is, UT_Vector2I &v)
577  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1); }
578  static void loadData(UT_IStream &is, UT_Vector3I &v)
579  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
580  is.bread<int64>(&v.z(), 1); }
581  static void loadData(UT_IStream &is, UT_Vector4I &v)
582  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
583  is.bread<int64>(&v.z(), 1); is.bread<int64>(&v.w(), 1); }
585  { is.bread(v); }
587  { UT_StringHolder rampdata;
588  loadData(is, rampdata);
589  if (rampdata.isstring())
590  {
591  v.reset(new UT_Ramp());
592  UT_IStream istr((const char *) rampdata, rampdata.length(), UT_ISTREAM_ASCII);
593  v->load(istr);
594  }
595  else v.reset();
596  }
599  loadData(is, data);
600  if (data.isstring())
601  {
602  // Find the data type.
603  char *colon = UT_StringWrap(data).findChar(':');
604  if (colon)
605  {
606  int typelen = colon - data.buffer();
608  type.strncpy(data.buffer(), typelen);
609  UT_IStream istr(((const char *) data) + typelen + 1, data.length() - (typelen + 1), UT_ISTREAM_BINARY);
610 
611  v = PRM_DataFactory::parseBinary(type.buffer(), istr);
612  }
613  }
614  else v.reset();
615  }
616 
617  static void saveData(std::ostream &os, int64 v)
618  { UTwrite(os, &v); }
619  static void saveData(std::ostream &os, bool v)
620  { int64 iv = v; UTwrite(os, &iv); }
621  static void saveData(std::ostream &os, fpreal64 v)
622  { UTwrite<fpreal64>(os, &v); }
623  static void saveData(std::ostream &os, UT_Vector2D v)
624  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y()); }
625  static void saveData(std::ostream &os, UT_Vector3D v)
626  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
627  UTwrite<fpreal64>(os, &v.z()); }
628  static void saveData(std::ostream &os, UT_Vector4D v)
629  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
630  UTwrite<fpreal64>(os, &v.z()); UTwrite<fpreal64>(os, &v.w()); }
631  static void saveData(std::ostream &os, UT_Matrix2D v)
633  static void saveData(std::ostream &os, UT_Matrix3D v)
635  static void saveData(std::ostream &os, UT_Matrix4D v)
637  static void saveData(std::ostream &os, UT_StringHolder s)
638  { UT_StringWrap(s).saveBinary(os); }
639  static void saveData(std::ostream &os, UT_SharedPtr<UT_Ramp> s)
640  { UT_StringHolder result;
641  UT_OStringStream ostr;
642  if (s) s->save(ostr);
643  result = ostr.str();
644  saveData(os, result);
645  }
646  static void saveData(std::ostream &os, PRM_DataItemHandle s)
647  { UT_StringHolder result;
648  UT_OStringStream ostr;
649  if (s)
650  {
651  ostr << s->getDataTypeToken();
652  ostr << ":";
653  s->saveBinary(ostr);
654  }
655  result = ostr.str();
656  saveData(os, result);
657  }
658 
659 
660  void save(std::ostream &os) const
661  {
662  int32 v = version();
663  UTwrite(os, &v);
664  saveData(os, myGroup);
665  saveData(os, myNegate);
666  saveData(os, myEntity);
667  saveData(os, myAffectnumber);
668  saveData(os, myGroupop);
669  saveData(os, myFilter);
670  saveData(os, myPattern);
671  saveData(os, myRange);
672  saveData(os, mySelect);
673  saveData(os, myAffectvolume);
674  saveData(os, myBoundtype);
675  saveData(os, mySize);
676  saveData(os, myT);
677  saveData(os, myAffectnormal);
678  saveData(os, myCamerapath);
679  saveData(os, myAffectdegenerate);
680  saveData(os, myDegenerate);
681  saveData(os, myZaf);
682  saveData(os, myDoopen);
683  saveData(os, myTol);
684  saveData(os, myRemovegrp);
685  saveData(os, myKeeppoints);
686  saveData(os, myGeotype);
687  saveData(os, myDir);
688  saveData(os, myAngle);
689 
690  }
691 
692  bool load(UT_IStream &is)
693  {
694  int32 v;
695  is.bread(&v, 1);
696  if (version() != v)
697  {
698  // Fail incompatible versions
699  return false;
700  }
701  loadData(is, myGroup);
702  loadData(is, myNegate);
703  loadData(is, myEntity);
704  loadData(is, myAffectnumber);
705  loadData(is, myGroupop);
706  loadData(is, myFilter);
707  loadData(is, myPattern);
708  loadData(is, myRange);
709  loadData(is, mySelect);
710  loadData(is, myAffectvolume);
711  loadData(is, myBoundtype);
712  loadData(is, mySize);
713  loadData(is, myT);
714  loadData(is, myAffectnormal);
715  loadData(is, myCamerapath);
716  loadData(is, myAffectdegenerate);
717  loadData(is, myDegenerate);
718  loadData(is, myZaf);
719  loadData(is, myDoopen);
720  loadData(is, myTol);
721  loadData(is, myRemovegrp);
722  loadData(is, myKeeppoints);
723  loadData(is, myGeotype);
724  loadData(is, myDir);
725  loadData(is, myAngle);
726 
727  return true;
728  }
729 
730  const UT_StringHolder & getGroup() const { return myGroup; }
731  void setGroup(const UT_StringHolder & val) { myGroup = val; }
733  {
734  SOP_Node *thissop = cookparms.getNode();
735  if (!thissop) return getGroup();
736  UT_StringHolder result;
737  OP_Utils::evalOpParm(result, thissop, "group", cookparms.getCookTime(), 0);
738  return result;
739  }
740  Negate getNegate() const { return Negate(myNegate); }
741  void setNegate(Negate val) { myNegate = int64(val); }
742  Negate opNegate(const SOP_NodeVerb::CookParms &cookparms) const
743  {
744  SOP_Node *thissop = cookparms.getNode();
745  if (!thissop) return getNegate();
746  int64 result;
747  OP_Utils::evalOpParm(result, thissop, "negate", cookparms.getCookTime(), 0);
748  return Negate(result);
749  }
750  Entity getEntity() const { return Entity(myEntity); }
751  void setEntity(Entity val) { myEntity = int64(val); }
752  Entity opEntity(const SOP_NodeVerb::CookParms &cookparms) const
753  {
754  SOP_Node *thissop = cookparms.getNode();
755  if (!thissop) return getEntity();
756  int64 result;
757  OP_Utils::evalOpParm(result, thissop, "entity", cookparms.getCookTime(), 0);
758  return Entity(result);
759  }
760  bool getAffectnumber() const { return myAffectnumber; }
761  void setAffectnumber(bool val) { myAffectnumber = val; }
762  bool opAffectnumber(const SOP_NodeVerb::CookParms &cookparms) const
763  {
764  SOP_Node *thissop = cookparms.getNode();
765  if (!thissop) return getAffectnumber();
766  bool result;
767  OP_Utils::evalOpParm(result, thissop, "affectnumber", cookparms.getCookTime(), 0);
768  return result;
769  }
770  Groupop getGroupop() const { return Groupop(myGroupop); }
771  void setGroupop(Groupop val) { myGroupop = int64(val); }
772  Groupop opGroupop(const SOP_NodeVerb::CookParms &cookparms) const
773  {
774  SOP_Node *thissop = cookparms.getNode();
775  if (!thissop) return getGroupop();
776  int64 result;
777  OP_Utils::evalOpParm(result, thissop, "groupop", cookparms.getCookTime(), 0);
778  return Groupop(result);
779  }
780  int64 getFilter() const { return myFilter; }
781  void setFilter(int64 val) { myFilter = val; }
782  int64 opFilter(const SOP_NodeVerb::CookParms &cookparms) const
783  {
784  SOP_Node *thissop = cookparms.getNode();
785  if (!thissop) return getFilter();
786  int64 result;
787  OP_Utils::evalOpParm(result, thissop, "filter", cookparms.getCookTime(), 0);
788  return result;
789  }
790  const UT_StringHolder & getPattern() const { return myPattern; }
791  void setPattern(const UT_StringHolder & val) { myPattern = val; }
793  {
794  SOP_Node *thissop = cookparms.getNode();
795  if (!thissop) return getPattern();
796  UT_StringHolder result;
797  OP_Utils::evalOpParm(result, thissop, "pattern", cookparms.getCookTime(), 0);
798  return result;
799  }
800  UT_Vector2I getRange() const { return myRange; }
801  void setRange(UT_Vector2I val) { myRange = val; }
803  {
804  SOP_Node *thissop = cookparms.getNode();
805  if (!thissop) return getRange();
806  UT_Vector2I result;
807  OP_Utils::evalOpParm(result, thissop, "range", cookparms.getCookTime(), 0);
808  return result;
809  }
810  UT_Vector2I getSelect() const { return mySelect; }
811  void setSelect(UT_Vector2I val) { mySelect = val; }
813  {
814  SOP_Node *thissop = cookparms.getNode();
815  if (!thissop) return getSelect();
816  UT_Vector2I result;
817  OP_Utils::evalOpParm(result, thissop, "select", cookparms.getCookTime(), 0);
818  return result;
819  }
820  bool getAffectvolume() const { return myAffectvolume; }
821  void setAffectvolume(bool val) { myAffectvolume = val; }
822  bool opAffectvolume(const SOP_NodeVerb::CookParms &cookparms) const
823  {
824  SOP_Node *thissop = cookparms.getNode();
825  if (!thissop) return getAffectvolume();
826  bool result;
827  OP_Utils::evalOpParm(result, thissop, "affectvolume", cookparms.getCookTime(), 0);
828  return result;
829  }
830  Boundtype getBoundtype() const { return Boundtype(myBoundtype); }
831  void setBoundtype(Boundtype val) { myBoundtype = int64(val); }
833  {
834  SOP_Node *thissop = cookparms.getNode();
835  if (!thissop) return getBoundtype();
836  int64 result;
837  OP_Utils::evalOpParm(result, thissop, "boundtype", cookparms.getCookTime(), 0);
838  return Boundtype(result);
839  }
840  UT_Vector3D getSize() const { return mySize; }
841  void setSize(UT_Vector3D val) { mySize = val; }
843  {
844  SOP_Node *thissop = cookparms.getNode();
845  if (!thissop) return getSize();
846  UT_Vector3D result;
847  OP_Utils::evalOpParm(result, thissop, "size", cookparms.getCookTime(), 0);
848  return result;
849  }
850  UT_Vector3D getT() const { return myT; }
851  void setT(UT_Vector3D val) { myT = val; }
852  UT_Vector3D opT(const SOP_NodeVerb::CookParms &cookparms) const
853  {
854  SOP_Node *thissop = cookparms.getNode();
855  if (!thissop) return getT();
856  UT_Vector3D result;
857  OP_Utils::evalOpParm(result, thissop, "t", cookparms.getCookTime(), 0);
858  return result;
859  }
860  bool getAffectnormal() const { return myAffectnormal; }
861  void setAffectnormal(bool val) { myAffectnormal = val; }
862  bool opAffectnormal(const SOP_NodeVerb::CookParms &cookparms) const
863  {
864  SOP_Node *thissop = cookparms.getNode();
865  if (!thissop) return getAffectnormal();
866  bool result;
867  OP_Utils::evalOpParm(result, thissop, "affectnormal", cookparms.getCookTime(), 0);
868  return result;
869  }
870  const UT_StringHolder & getCamerapath() const { return myCamerapath; }
871  void setCamerapath(const UT_StringHolder & val) { myCamerapath = val; }
873  {
874  SOP_Node *thissop = cookparms.getNode();
875  if (!thissop) return getCamerapath();
876  UT_StringHolder result;
877  OP_Utils::evalOpParm(result, thissop, "camerapath", cookparms.getCookTime(), 0);
878  return result;
879  }
880  bool getAffectdegenerate() const { return myAffectdegenerate; }
881  void setAffectdegenerate(bool val) { myAffectdegenerate = val; }
882  bool opAffectdegenerate(const SOP_NodeVerb::CookParms &cookparms) const
883  {
884  SOP_Node *thissop = cookparms.getNode();
885  if (!thissop) return getAffectdegenerate();
886  bool result;
887  OP_Utils::evalOpParm(result, thissop, "affectdegenerate", cookparms.getCookTime(), 0);
888  return result;
889  }
890  bool getDegenerate() const { return myDegenerate; }
891  void setDegenerate(bool val) { myDegenerate = val; }
892  bool opDegenerate(const SOP_NodeVerb::CookParms &cookparms) const
893  {
894  SOP_Node *thissop = cookparms.getNode();
895  if (!thissop) return getDegenerate();
896  bool result;
897  OP_Utils::evalOpParm(result, thissop, "degenerate", cookparms.getCookTime(), 0);
898  return result;
899  }
900  bool getZaf() const { return myZaf; }
901  void setZaf(bool val) { myZaf = val; }
902  bool opZaf(const SOP_NodeVerb::CookParms &cookparms) const
903  {
904  SOP_Node *thissop = cookparms.getNode();
905  if (!thissop) return getZaf();
906  bool result;
907  OP_Utils::evalOpParm(result, thissop, "zaf", cookparms.getCookTime(), 0);
908  return result;
909  }
910  bool getDoopen() const { return myDoopen; }
911  void setDoopen(bool val) { myDoopen = val; }
912  bool opDoopen(const SOP_NodeVerb::CookParms &cookparms) const
913  {
914  SOP_Node *thissop = cookparms.getNode();
915  if (!thissop) return getDoopen();
916  bool result;
917  OP_Utils::evalOpParm(result, thissop, "doopen", cookparms.getCookTime(), 0);
918  return result;
919  }
920  fpreal64 getTol() const { return myTol; }
921  void setTol(fpreal64 val) { myTol = val; }
922  fpreal64 opTol(const SOP_NodeVerb::CookParms &cookparms) const
923  {
924  SOP_Node *thissop = cookparms.getNode();
925  if (!thissop) return getTol();
926  fpreal64 result;
927  OP_Utils::evalOpParm(result, thissop, "tol", cookparms.getCookTime(), 0);
928  return result;
929  }
930  bool getRemovegrp() const { return myRemovegrp; }
931  void setRemovegrp(bool val) { myRemovegrp = val; }
932  bool opRemovegrp(const SOP_NodeVerb::CookParms &cookparms) const
933  {
934  SOP_Node *thissop = cookparms.getNode();
935  if (!thissop) return getRemovegrp();
936  bool result;
937  OP_Utils::evalOpParm(result, thissop, "removegrp", cookparms.getCookTime(), 0);
938  return result;
939  }
940  bool getKeeppoints() const { return myKeeppoints; }
941  void setKeeppoints(bool val) { myKeeppoints = val; }
942  bool opKeeppoints(const SOP_NodeVerb::CookParms &cookparms) const
943  {
944  SOP_Node *thissop = cookparms.getNode();
945  if (!thissop) return getKeeppoints();
946  bool result;
947  OP_Utils::evalOpParm(result, thissop, "keeppoints", cookparms.getCookTime(), 0);
948  return result;
949  }
950  int64 getGeotype() const { return myGeotype; }
951  void setGeotype(int64 val) { myGeotype = val; }
952  int64 opGeotype(const SOP_NodeVerb::CookParms &cookparms) const
953  {
954  SOP_Node *thissop = cookparms.getNode();
955  if (!thissop) return getGeotype();
956  int64 result;
957  OP_Utils::evalOpParm(result, thissop, "geotype", cookparms.getCookTime(), 0);
958  return result;
959  }
960  UT_Vector3D getDir() const { return myDir; }
961  void setDir(UT_Vector3D val) { myDir = val; }
962  UT_Vector3D opDir(const SOP_NodeVerb::CookParms &cookparms) const
963  {
964  SOP_Node *thissop = cookparms.getNode();
965  if (!thissop) return getDir();
966  UT_Vector3D result;
967  OP_Utils::evalOpParm(result, thissop, "dir", cookparms.getCookTime(), 0);
968  return result;
969  }
970  fpreal64 getAngle() const { return myAngle; }
971  void setAngle(fpreal64 val) { myAngle = val; }
972  fpreal64 opAngle(const SOP_NodeVerb::CookParms &cookparms) const
973  {
974  SOP_Node *thissop = cookparms.getNode();
975  if (!thissop) return getAngle();
976  fpreal64 result;
977  OP_Utils::evalOpParm(result, thissop, "angle", cookparms.getCookTime(), 0);
978  return result;
979  }
980 
981 private:
982  UT_StringHolder myGroup;
983  int64 myNegate;
984  int64 myEntity;
985  bool myAffectnumber;
986  int64 myGroupop;
987  int64 myFilter;
988  UT_StringHolder myPattern;
989  UT_Vector2I myRange;
990  UT_Vector2I mySelect;
991  bool myAffectvolume;
992  int64 myBoundtype;
993  UT_Vector3D mySize;
994  UT_Vector3D myT;
995  bool myAffectnormal;
996  UT_StringHolder myCamerapath;
997  bool myAffectdegenerate;
998  bool myDegenerate;
999  bool myZaf;
1000  bool myDoopen;
1001  fpreal64 myTol;
1002  bool myRemovegrp;
1003  bool myKeeppoints;
1004  int64 myGeotype;
1005  UT_Vector3D myDir;
1006  fpreal64 myAngle;
1007 
1008 };
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
void setParmValue(exint idx, const exint &value)
UT_Vector2T< int64 > UT_Vector2I
int64 opGeotype(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
void setGroup(const UT_StringHolder &val)
bool opAffectdegenerate(const SOP_NodeVerb::CookParms &cookparms) const
void setZaf(bool val)
void doGetParmValue(exint idx, T &value) const
SOP_Node * getNode() const
Definition: SOP_NodeVerb.h:492
void save(std::ostream &os) const
static void loadData(UT_IStream &is, UT_Matrix2D &v)
T & z(void)
Definition: UT_Vector4.h:372
void setParmValue(exint idx, const fpreal &value)
void getParmValue(exint idx, UT_Vector2D &value) const
void setParmValue(exint idx, const UT_Matrix4D &value)
static void saveData(std::ostream &os, fpreal64 v)
void setParmValue(exint idx, const UT_Vector2D &value)
void setParmValue(exint idx, const PRM_DataItemHandle &value)
static int version()
static void loadData(UT_IStream &is, UT_Matrix3D &v)
void setAffectvolume(bool val)
static void loadData(UT_IStream &is, UT_Vector4I &v)
virtual ParmType getParmType(exint fieldnum) const
exint bread(int32 *buffer, exint asize=1)
static void saveData(std::ostream &os, PRM_DataItemHandle s)
void setKeeppoints(bool val)
static void loadData(UT_IStream &is, UT_Vector3D &v)
fpreal getTime() const
Definition: OP_Context.h:34
const GLdouble * v
Definition: glcorearb.h:836
fpreal64 getTol() const
UT_StringHolder opGroup(const SOP_NodeVerb::CookParms &cookparms) const
void setAffectnumber(bool val)
bool load(UT_IStream &is)
void setCamerapath(const UT_StringHolder &val)
UT_Vector2I getSelect() const
void setDoopen(bool val)
static void loadData(UT_IStream &is, fpreal64 &v)
void setDir(UT_Vector3D val)
UT_Vector2I opRange(const SOP_NodeVerb::CookParms &cookparms) const
void setTol(fpreal64 val)
static void loadData(UT_IStream &is, UT_Vector4D &v)
static void saveData(std::ostream &os, int64 v)
T & x(void)
Definition: UT_Vector2.h:284
void setAffectdegenerate(bool val)
const UT_StringHolder & getCamerapath() const
fpreal64 opAngle(const SOP_NodeVerb::CookParms &cookparms) const
bool getDegenerate() const
void setEntity(Entity val)
An output stream object that owns its own string buffer storage.
bool opDoopen(const SOP_NodeVerb::CookParms &cookparms) const
void doSetParmValue(exint idx, const T &value)
const UT_WorkBuffer & str() const
Returns a read-only reference to the underlying UT_WorkBuffer.
bool opDegenerate(const SOP_NodeVerb::CookParms &cookparms) const
void setPattern(const UT_StringHolder &val)
void getParmValue(exint idx, UT_Vector4D &value) const
SYS_FORCE_INLINE T & x(void)
Definition: UT_Vector3.h:581
void setParmValue(exint idx, const UT_Matrix2D &value)
fpreal64 getAngle() const
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
Entity opEntity(const SOP_NodeVerb::CookParms &cookparms) const
UT_Vector3D opSize(const SOP_NodeVerb::CookParms &cookparms) const
void setNegate(Negate val)
Entity getEntity() const
static void saveData(std::ostream &os, UT_Vector2D v)
UT_Vector2I opSelect(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, bool &v)
void buildFromOp(const OP_Node *node, fpreal time, DEP_MicroNode *depnode)
void setRemovegrp(bool val)
SYS_FORCE_INLINE T & z(void)
Definition: UT_Vector3.h:585
long long int64
Definition: SYS_Types.h:100
void setRange(UT_Vector2I val)
static void loadData(UT_IStream &is, UT_Matrix4D &v)
static void loadData(UT_IStream &is, UT_Vector2D &v)
UT_StringHolder opCamerapath(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, UT_StringHolder s)
bool opKeeppoints(const SOP_NodeVerb::CookParms &cookparms) const
const UT_StringHolder & getGroup() const
bool opAffectnumber(const SOP_NodeVerb::CookParms &cookparms) const
exint length() const
char * findChar(int c) const
Find first occurrance of character. Returns NULL upon failure.
Definition: UT_String.h:550
SYS_FORCE_INLINE const char * buffer() const
int64 exint
Definition: SYS_Types.h:109
static void loadData(UT_IStream &is, UT_Vector2I &v)
bool getKeeppoints() const
const OP_Node * node() const
Definition: SOP_NodeVerb.h:104
UT_Vector3D getSize() const
double fpreal64
Definition: SYS_Types.h:185
void getParmValue(exint idx, UT_Vector3D &value) const
void setBoundtype(Boundtype val)
void getParmValue(exint idx, UT_Matrix2D &value) const
virtual void copyFrom(const SOP_NodeParms *src)
static void saveData(std::ostream &os, UT_Matrix2D v)
virtual void loadFromOpSubclass(const LoadParms &loadparms)
void setParmValue(exint idx, const UT_SharedPtr< UT_Ramp > &value)
UT_Vector3T< fpreal64 > UT_Vector3D
bool opRemovegrp(const SOP_NodeVerb::CookParms &cookparms) const
Groupop opGroupop(const SOP_NodeVerb::CookParms &cookparms) const
GLboolean * data
Definition: glcorearb.h:130
UT_Vector3D getT() const
int int32
Definition: SYS_Types.h:28
bool getRemovegrp() const
T & y(void)
Definition: UT_Vector4.h:370
bool getAffectnormal() const
void saveBinary(std::ostream &os) const
Save string to binary stream.
Definition: UT_String.h:294
void setParmValue(exint idx, const UT_Matrix3D &value)
bool getAffectnumber() const
virtual ~SOP_DeleteParms()
bool getAffectdegenerate() const
DEP_MicroNode * depnode() const
Definition: SOP_NodeVerb.h:111
bool opAffectvolume(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, bool v)
Boundtype opBoundtype(const SOP_NodeVerb::CookParms &cookparms) const
void getParmValue(exint idx, UT_Matrix3D &value) const
SYS_FORCE_INLINE T & y(void)
Definition: UT_Vector3.h:583
GLsizei const GLfloat * value
Definition: glcorearb.h:823
double fpreal
Definition: SYS_Types.h:263
Negate opNegate(const SOP_NodeVerb::CookParms &cookparms) const
void strncpy(const char *src, exint maxlen)
UT_Vector3D opT(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
void setSize(UT_Vector3D val)
void setDegenerate(bool val)
void getParmValue(exint idx, PRM_DataItemHandle &value) const
int64 getGeotype() const
static void loadData(UT_IStream &is, UT_StringHolder &v)
void setParmValue(exint idx, const UT_Vector3D &value)
UT_Vector3D opDir(const SOP_NodeVerb::CookParms &cookparms) const
bool operator==(const SOP_DeleteParms &src) const
void getParmValue(exint idx, exint &value) const
int64 opFilter(const SOP_NodeVerb::CookParms &cookparms) const
Utility class for containing a color ramp.
Definition: UT_Ramp.h:84
GLuint GLfloat * val
Definition: glcorearb.h:1607
void setParmValue(exint idx, const UT_StringHolder &value)
bool opAffectnormal(const SOP_NodeVerb::CookParms &cookparms) const
void setGeotype(int64 val)
#define SOP_API
Definition: SOP_API.h:10
Negate getNegate() const
virtual const char * getParmName(exint fieldnum) const
const char * buffer() const
static void loadData(UT_IStream &is, UT_Vector3I &v)
GLint GLint GLsizei GLint GLenum GLenum type
Definition: glcorearb.h:107
fpreal getCookTime() const
Definition: SOP_NodeVerb.h:499
void setGroupop(Groupop val)
T & x(void)
Definition: UT_Vector4.h:368
T & y(void)
Definition: UT_Vector2.h:286
void setSelect(UT_Vector2I val)
static void saveData(std::ostream &os, UT_Matrix4D v)
void getParmValue(exint idx, fpreal &value) const
GLboolean r
Definition: glcorearb.h:1221
bool getDoopen() const
void setT(UT_Vector3D val)
void setAffectnormal(bool val)
T & w(void)
Definition: UT_Vector4.h:374
void setAngle(fpreal64 val)
int64 getFilter() const
static void saveData(std::ostream &os, UT_Matrix3D v)
void getParmValue(exint idx, UT_StringHolder &value) const
bool opZaf(const SOP_NodeVerb::CookParms &cookparms) const
bool getZaf() const
static void loadData(UT_IStream &is, int64 &v)
UT_Vector3D getDir() const
static void saveData(std::ostream &os, UT_Vector4D v)
const UT_StringHolder & getPattern() const
bool getAffectvolume() const
const OP_Context & context() const
Definition: SOP_NodeVerb.h:109
Groupop getGroupop() const
static void saveData(std::ostream &os, UT_Vector3D v)
void getParmValue(exint idx, UT_Matrix4D &value) const
SYS_FORCE_INLINE bool isstring() const
UT_Vector2I getRange() const
void setParmValue(exint idx, const UT_Vector4D &value)
fpreal64 opTol(const SOP_NodeVerb::CookParms &cookparms) const
void setFilter(int64 val)
Boundtype getBoundtype() const
virtual exint getNumParms() const
GLenum src
Definition: glcorearb.h:1792
void getParmValue(exint idx, UT_SharedPtr< UT_Ramp > &value) const
UT_StringHolder opPattern(const SOP_NodeVerb::CookParms &cookparms) const