HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SOP_ProximityCapture.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_ProximityCaptureEnums
22 {
23  enum class Captureregionsop
24  {
25  DISPLAY = 0,
26  RENDER,
27  CAPTURE
28  };
29  enum class Cookat
30  {
31  CAPTUREFRAME = 0,
32  EVERYFRAME
33  };
34  enum class Weightmethod
35  {
38  };
39  enum class Weightfrom
40  {
41  CV = 0,
42  SURFACE
43  };
44  enum class Color
45  {
46  COLDEFAULT = 0,
47  COLREGION
48  };
49 }
50 
51 
53 {
54 public:
55  static int version() { return 1; }
56 
58  {
59  myGroup = ""_sh;
60  myRootpath = ""_sh;
61  myExtraregions = ""_sh;
62  myCaptureregionsop = 2;
63  myDosubnets = false;
64  myRelativeskel = false;
65  myUsecaptpose = false;
66  myCookat = 0;
67  myCaptframe = 0;
68  myWeightmethod = 0;
69  myWeightfrom = 0;
70  myDropoff = 1;
71  myMaxinfluences = 2;
72  myNormweights = false;
73  myDestroyweights = false;
74  myBlendfactor = 1;
75  myColor = 0;
76  myZeroweightcolor = UT_Vector3D(1,1,1);
77 
78  }
79 
80  explicit SOP_ProximityCaptureParms(const SOP_ProximityCaptureParms &) = default;
81 
83 
85  {
86  if (myGroup != src.myGroup) return false;
87  if (myRootpath != src.myRootpath) return false;
88  if (myExtraregions != src.myExtraregions) return false;
89  if (myCaptureregionsop != src.myCaptureregionsop) return false;
90  if (myDosubnets != src.myDosubnets) return false;
91  if (myRelativeskel != src.myRelativeskel) return false;
92  if (myUsecaptpose != src.myUsecaptpose) return false;
93  if (myCookat != src.myCookat) return false;
94  if (myCaptframe != src.myCaptframe) return false;
95  if (myWeightmethod != src.myWeightmethod) return false;
96  if (myWeightfrom != src.myWeightfrom) return false;
97  if (myDropoff != src.myDropoff) return false;
98  if (myMaxinfluences != src.myMaxinfluences) return false;
99  if (myNormweights != src.myNormweights) return false;
100  if (myDestroyweights != src.myDestroyweights) return false;
101  if (myBlendfactor != src.myBlendfactor) return false;
102  if (myColor != src.myColor) return false;
103  if (myZeroweightcolor != src.myZeroweightcolor) return false;
104 
105  return true;
106  }
108  {
109  return !operator==(src);
110  }
116 
117 
118 
119  void buildFromOp(const OP_Node *node, fpreal time, DEP_MicroNode *depnode)
120  {
121  if (true)
122  OP_Utils::evalOpParm(myGroup, node, "group", time, 0);
123  else myGroup = ""_sh;
124  if (true)
125  OP_Utils::evalOpParm(myRootpath, node, "rootpath", time, 0);
126  else myRootpath = ""_sh;
127  if (true)
128  OP_Utils::evalOpParm(myExtraregions, node, "extraregions", time, 0);
129  else myExtraregions = ""_sh;
130  if (true)
131  OP_Utils::evalOpParm(myCaptureregionsop, node, "captureregionsop", time, 0);
132  else myCaptureregionsop = 2;
133  if (true)
134  OP_Utils::evalOpParm(myDosubnets, node, "dosubnets", time, 0);
135  else myDosubnets = false;
136  if (true)
137  OP_Utils::evalOpParm(myRelativeskel, node, "relativeskel", time, 0);
138  else myRelativeskel = false;
139  if (true)
140  OP_Utils::evalOpParm(myUsecaptpose, node, "usecaptpose", time, 0);
141  else myUsecaptpose = false;
142  if (true && ( (!(((getUsecaptpose()!=0)))) ) )
143  OP_Utils::evalOpParm(myCookat, node, "cookat", time, 0);
144  else myCookat = 0;
145  if (true && ( (!(((getUsecaptpose()!=0))||((int64(getCookat())==1)))) ) )
146  OP_Utils::evalOpParm(myCaptframe, node, "captframe", time, 0);
147  else myCaptframe = 0;
148  if (true)
149  OP_Utils::evalOpParm(myWeightmethod, node, "weightmethod", time, 0);
150  else myWeightmethod = 0;
151  if (true)
152  OP_Utils::evalOpParm(myWeightfrom, node, "weightFrom", time, 0);
153  else myWeightfrom = 0;
154  if (true)
155  OP_Utils::evalOpParm(myDropoff, node, "dropoff", time, 0);
156  else myDropoff = 1;
157  if (true)
158  OP_Utils::evalOpParm(myMaxinfluences, node, "maxinfluences", time, 0);
159  else myMaxinfluences = 2;
160  if (true)
161  OP_Utils::evalOpParm(myNormweights, node, "normweights", time, 0);
162  else myNormweights = false;
163  if (true)
164  OP_Utils::evalOpParm(myDestroyweights, node, "destroyweights", time, 0);
165  else myDestroyweights = false;
166  if (true && ( (!(((getDestroyweights()!=0)))) ) )
167  OP_Utils::evalOpParm(myBlendfactor, node, "blendfactor", time, 0);
168  else myBlendfactor = 1;
169  if (true)
170  OP_Utils::evalOpParm(myColor, node, "color", time, 0);
171  else myColor = 0;
172  if (true)
173  OP_Utils::evalOpParm(myZeroweightcolor, node, "zeroweightcolor", time, 0);
174  else myZeroweightcolor = UT_Vector3D(1,1,1);
175 
176  }
177 
178 
179  virtual void loadFromOpSubclass(const LoadParms &loadparms)
180  {
181  buildFromOp(loadparms.node(), loadparms.context().getTime(), loadparms.depnode());
182  }
183 
184 
185  virtual void copyFrom(const SOP_NodeParms *src)
186  {
187  *this = *((const SOP_ProximityCaptureParms *)src);
188  }
189 
190  template <typename T>
191  void
192  doGetParmValue(exint idx, T &value) const
193  {
194  switch (idx)
195  {
196  case 0:
197  coerceValue(value, myGroup);
198  break;
199  case 1:
200  coerceValue(value, myRootpath);
201  break;
202  case 2:
203  coerceValue(value, myExtraregions);
204  break;
205  case 3:
206  coerceValue(value, myCaptureregionsop);
207  break;
208  case 4:
209  coerceValue(value, myDosubnets);
210  break;
211  case 5:
212  coerceValue(value, myRelativeskel);
213  break;
214  case 6:
215  coerceValue(value, myUsecaptpose);
216  break;
217  case 7:
218  coerceValue(value, myCookat);
219  break;
220  case 8:
221  coerceValue(value, myCaptframe);
222  break;
223  case 9:
224  coerceValue(value, myWeightmethod);
225  break;
226  case 10:
227  coerceValue(value, myWeightfrom);
228  break;
229  case 11:
230  coerceValue(value, myDropoff);
231  break;
232  case 12:
233  coerceValue(value, myMaxinfluences);
234  break;
235  case 13:
236  coerceValue(value, myNormweights);
237  break;
238  case 14:
239  coerceValue(value, myDestroyweights);
240  break;
241  case 15:
242  coerceValue(value, myBlendfactor);
243  break;
244  case 16:
245  coerceValue(value, myColor);
246  break;
247  case 17:
248  coerceValue(value, myZeroweightcolor);
249  break;
250 
251  }
252  }
253 
254  void getParmValue(exint idx, exint &value) const
255  { doGetParmValue(idx, value); }
256  void getParmValue(exint idx, fpreal &value) const
257  { doGetParmValue(idx, value); }
259  { doGetParmValue(idx, value); }
261  { doGetParmValue(idx, value); }
263  { doGetParmValue(idx, value); }
265  { doGetParmValue(idx, value); }
267  { doGetParmValue(idx, value); }
269  { doGetParmValue(idx, value); }
271  { doGetParmValue(idx, value); }
273  { doGetParmValue(idx, value); }
275  { doGetParmValue(idx, value); }
276 
277  template <typename T>
278  void
279  doSetParmValue(exint idx, const T &value)
280  {
281  switch (idx)
282  {
283  case 0:
284  coerceValue(myGroup, value);
285  break;
286  case 1:
287  coerceValue(myRootpath, value);
288  break;
289  case 2:
290  coerceValue(myExtraregions, value);
291  break;
292  case 3:
293  coerceValue(myCaptureregionsop, value);
294  break;
295  case 4:
296  coerceValue(myDosubnets, value);
297  break;
298  case 5:
299  coerceValue(myRelativeskel, value);
300  break;
301  case 6:
302  coerceValue(myUsecaptpose, value);
303  break;
304  case 7:
305  coerceValue(myCookat, value);
306  break;
307  case 8:
308  coerceValue(myCaptframe, value);
309  break;
310  case 9:
311  coerceValue(myWeightmethod, value);
312  break;
313  case 10:
314  coerceValue(myWeightfrom, value);
315  break;
316  case 11:
317  coerceValue(myDropoff, value);
318  break;
319  case 12:
320  coerceValue(myMaxinfluences, value);
321  break;
322  case 13:
323  coerceValue(myNormweights, value);
324  break;
325  case 14:
326  coerceValue(myDestroyweights, value);
327  break;
328  case 15:
329  coerceValue(myBlendfactor, value);
330  break;
331  case 16:
332  coerceValue(myColor, value);
333  break;
334  case 17:
335  coerceValue(myZeroweightcolor, value);
336  break;
337 
338  }
339  }
340 
341  void setParmValue(exint idx, const exint &value)
342  { doSetParmValue(idx, value); }
343  void setParmValue(exint idx, const fpreal &value)
344  { doSetParmValue(idx, value); }
345  void setParmValue(exint idx, const UT_Vector2D &value)
346  { doSetParmValue(idx, value); }
347  void setParmValue(exint idx, const UT_Vector3D &value)
348  { doSetParmValue(idx, value); }
349  void setParmValue(exint idx, const UT_Vector4D &value)
350  { doSetParmValue(idx, value); }
351  void setParmValue(exint idx, const UT_Matrix2D &value)
352  { doSetParmValue(idx, value); }
353  void setParmValue(exint idx, const UT_Matrix3D &value)
354  { doSetParmValue(idx, value); }
355  void setParmValue(exint idx, const UT_Matrix4D &value)
356  { doSetParmValue(idx, value); }
358  { doSetParmValue(idx, value); }
360  { doSetParmValue(idx, value); }
362  { doSetParmValue(idx, value); }
363 
364  virtual exint getNumParms() const
365  {
366  return 18;
367  }
368 
369  virtual const char *getParmName(exint fieldnum) const
370  {
371  switch (fieldnum)
372  {
373  case 0:
374  return "group";
375  case 1:
376  return "rootpath";
377  case 2:
378  return "extraregions";
379  case 3:
380  return "captureregionsop";
381  case 4:
382  return "dosubnets";
383  case 5:
384  return "relativeskel";
385  case 6:
386  return "usecaptpose";
387  case 7:
388  return "cookat";
389  case 8:
390  return "captframe";
391  case 9:
392  return "weightmethod";
393  case 10:
394  return "weightFrom";
395  case 11:
396  return "dropoff";
397  case 12:
398  return "maxinfluences";
399  case 13:
400  return "normweights";
401  case 14:
402  return "destroyweights";
403  case 15:
404  return "blendfactor";
405  case 16:
406  return "color";
407  case 17:
408  return "zeroweightcolor";
409 
410  }
411  return 0;
412  }
413 
414  virtual ParmType getParmType(exint fieldnum) const
415  {
416  switch (fieldnum)
417  {
418  case 0:
419  return PARM_STRING;
420  case 1:
421  return PARM_STRING;
422  case 2:
423  return PARM_STRING;
424  case 3:
425  return PARM_INTEGER;
426  case 4:
427  return PARM_INTEGER;
428  case 5:
429  return PARM_INTEGER;
430  case 6:
431  return PARM_INTEGER;
432  case 7:
433  return PARM_INTEGER;
434  case 8:
435  return PARM_FLOAT;
436  case 9:
437  return PARM_INTEGER;
438  case 10:
439  return PARM_INTEGER;
440  case 11:
441  return PARM_FLOAT;
442  case 12:
443  return PARM_INTEGER;
444  case 13:
445  return PARM_INTEGER;
446  case 14:
447  return PARM_INTEGER;
448  case 15:
449  return PARM_FLOAT;
450  case 16:
451  return PARM_INTEGER;
452  case 17:
453  return PARM_VECTOR3;
454 
455  }
456  return PARM_UNSUPPORTED;
457  }
458 
459  // Boiler plate to load individual types.
460  static void loadData(UT_IStream &is, int64 &v)
461  { is.bread(&v, 1); }
462  static void loadData(UT_IStream &is, bool &v)
463  { int64 iv; is.bread(&iv, 1); v = iv; }
464  static void loadData(UT_IStream &is, fpreal64 &v)
465  { is.bread<fpreal64>(&v, 1); }
466  static void loadData(UT_IStream &is, UT_Vector2D &v)
467  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1); }
468  static void loadData(UT_IStream &is, UT_Vector3D &v)
469  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
470  is.bread<fpreal64>(&v.z(), 1); }
471  static void loadData(UT_IStream &is, UT_Vector4D &v)
472  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
473  is.bread<fpreal64>(&v.z(), 1); is.bread<fpreal64>(&v.w(), 1); }
474  static void loadData(UT_IStream &is, UT_Matrix2D &v)
475  { for (int r = 0; r < 2; r++) for (int c = 0; c < 2; c++) is.bread<fpreal64>(&v(r, c), 1); }
476  static void loadData(UT_IStream &is, UT_Matrix3D &v)
477  { for (int r = 0; r < 3; r++) for (int c = 0; c < 3; c++) is.bread<fpreal64>(&v(r, c), 1); }
478  static void loadData(UT_IStream &is, UT_Matrix4D &v)
479  { for (int r = 0; r < 4; r++) for (int c = 0; c < 4; c++) is.bread<fpreal64>(&v(r, c), 1); }
480  static void loadData(UT_IStream &is, UT_Vector2I &v)
481  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1); }
482  static void loadData(UT_IStream &is, UT_Vector3I &v)
483  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
484  is.bread<int64>(&v.z(), 1); }
485  static void loadData(UT_IStream &is, UT_Vector4I &v)
486  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
487  is.bread<int64>(&v.z(), 1); is.bread<int64>(&v.w(), 1); }
489  { is.bread(v); }
491  { UT_StringHolder rampdata;
492  loadData(is, rampdata);
493  if (rampdata.isstring())
494  {
495  v.reset(new UT_Ramp());
496  UT_IStream istr((const char *) rampdata, rampdata.length(), UT_ISTREAM_ASCII);
497  v->load(istr);
498  }
499  else v.reset();
500  }
503  loadData(is, data);
504  if (data.isstring())
505  {
506  // Find the data type.
507  char *colon = UT_StringWrap(data).findChar(':');
508  if (colon)
509  {
510  int typelen = colon - data.buffer();
512  type.strncpy(data.buffer(), typelen);
513  UT_IStream istr(((const char *) data) + typelen + 1, data.length() - (typelen + 1), UT_ISTREAM_BINARY);
514 
515  v = PRM_DataFactory::parseBinary(type.buffer(), istr);
516  }
517  }
518  else v.reset();
519  }
520 
521  static void saveData(std::ostream &os, int64 v)
522  { UTwrite(os, &v); }
523  static void saveData(std::ostream &os, bool v)
524  { int64 iv = v; UTwrite(os, &iv); }
525  static void saveData(std::ostream &os, fpreal64 v)
526  { UTwrite<fpreal64>(os, &v); }
527  static void saveData(std::ostream &os, UT_Vector2D v)
528  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y()); }
529  static void saveData(std::ostream &os, UT_Vector3D v)
530  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
531  UTwrite<fpreal64>(os, &v.z()); }
532  static void saveData(std::ostream &os, UT_Vector4D v)
533  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
534  UTwrite<fpreal64>(os, &v.z()); UTwrite<fpreal64>(os, &v.w()); }
535  static void saveData(std::ostream &os, UT_Matrix2D v)
537  static void saveData(std::ostream &os, UT_Matrix3D v)
539  static void saveData(std::ostream &os, UT_Matrix4D v)
541  static void saveData(std::ostream &os, UT_StringHolder s)
542  { UT_StringWrap(s).saveBinary(os); }
543  static void saveData(std::ostream &os, UT_SharedPtr<UT_Ramp> s)
544  { UT_StringHolder result;
545  UT_OStringStream ostr;
546  if (s) s->save(ostr);
547  result = ostr.str();
548  saveData(os, result);
549  }
550  static void saveData(std::ostream &os, PRM_DataItemHandle s)
551  { UT_StringHolder result;
552  UT_OStringStream ostr;
553  if (s)
554  {
555  ostr << s->getDataTypeToken();
556  ostr << ":";
557  s->saveBinary(ostr);
558  }
559  result = ostr.str();
560  saveData(os, result);
561  }
562 
563 
564  void save(std::ostream &os) const
565  {
566  int32 v = version();
567  UTwrite(os, &v);
568  saveData(os, myGroup);
569  saveData(os, myRootpath);
570  saveData(os, myExtraregions);
571  saveData(os, myCaptureregionsop);
572  saveData(os, myDosubnets);
573  saveData(os, myRelativeskel);
574  saveData(os, myUsecaptpose);
575  saveData(os, myCookat);
576  saveData(os, myCaptframe);
577  saveData(os, myWeightmethod);
578  saveData(os, myWeightfrom);
579  saveData(os, myDropoff);
580  saveData(os, myMaxinfluences);
581  saveData(os, myNormweights);
582  saveData(os, myDestroyweights);
583  saveData(os, myBlendfactor);
584  saveData(os, myColor);
585  saveData(os, myZeroweightcolor);
586 
587  }
588 
589  bool load(UT_IStream &is)
590  {
591  int32 v;
592  is.bread(&v, 1);
593  if (version() != v)
594  {
595  // Fail incompatible versions
596  return false;
597  }
598  loadData(is, myGroup);
599  loadData(is, myRootpath);
600  loadData(is, myExtraregions);
601  loadData(is, myCaptureregionsop);
602  loadData(is, myDosubnets);
603  loadData(is, myRelativeskel);
604  loadData(is, myUsecaptpose);
605  loadData(is, myCookat);
606  loadData(is, myCaptframe);
607  loadData(is, myWeightmethod);
608  loadData(is, myWeightfrom);
609  loadData(is, myDropoff);
610  loadData(is, myMaxinfluences);
611  loadData(is, myNormweights);
612  loadData(is, myDestroyweights);
613  loadData(is, myBlendfactor);
614  loadData(is, myColor);
615  loadData(is, myZeroweightcolor);
616 
617  return true;
618  }
619 
620  const UT_StringHolder & getGroup() const { return myGroup; }
621  void setGroup(const UT_StringHolder & val) { myGroup = val; }
623  {
624  SOP_Node *thissop = cookparms.getNode();
625  if (!thissop) return getGroup();
626  UT_StringHolder result;
627  OP_Utils::evalOpParm(result, thissop, "group", cookparms.getCookTime(), 0);
628  return result;
629  }
630  const UT_StringHolder & getRootpath() const { return myRootpath; }
631  void setRootpath(const UT_StringHolder & val) { myRootpath = val; }
633  {
634  SOP_Node *thissop = cookparms.getNode();
635  if (!thissop) return getRootpath();
636  UT_StringHolder result;
637  OP_Utils::evalOpParm(result, thissop, "rootpath", cookparms.getCookTime(), 0);
638  return result;
639  }
640  const UT_StringHolder & getExtraregions() const { return myExtraregions; }
641  void setExtraregions(const UT_StringHolder & val) { myExtraregions = val; }
643  {
644  SOP_Node *thissop = cookparms.getNode();
645  if (!thissop) return getExtraregions();
646  UT_StringHolder result;
647  OP_Utils::evalOpParm(result, thissop, "extraregions", cookparms.getCookTime(), 0);
648  return result;
649  }
650  Captureregionsop getCaptureregionsop() const { return Captureregionsop(myCaptureregionsop); }
651  void setCaptureregionsop(Captureregionsop val) { myCaptureregionsop = int64(val); }
653  {
654  SOP_Node *thissop = cookparms.getNode();
655  if (!thissop) return getCaptureregionsop();
656  int64 result;
657  OP_Utils::evalOpParm(result, thissop, "captureregionsop", cookparms.getCookTime(), 0);
658  return Captureregionsop(result);
659  }
660  bool getDosubnets() const { return myDosubnets; }
661  void setDosubnets(bool val) { myDosubnets = val; }
662  bool opDosubnets(const SOP_NodeVerb::CookParms &cookparms) const
663  {
664  SOP_Node *thissop = cookparms.getNode();
665  if (!thissop) return getDosubnets();
666  bool result;
667  OP_Utils::evalOpParm(result, thissop, "dosubnets", cookparms.getCookTime(), 0);
668  return result;
669  }
670  bool getRelativeskel() const { return myRelativeskel; }
671  void setRelativeskel(bool val) { myRelativeskel = val; }
672  bool opRelativeskel(const SOP_NodeVerb::CookParms &cookparms) const
673  {
674  SOP_Node *thissop = cookparms.getNode();
675  if (!thissop) return getRelativeskel();
676  bool result;
677  OP_Utils::evalOpParm(result, thissop, "relativeskel", cookparms.getCookTime(), 0);
678  return result;
679  }
680  bool getUsecaptpose() const { return myUsecaptpose; }
681  void setUsecaptpose(bool val) { myUsecaptpose = val; }
682  bool opUsecaptpose(const SOP_NodeVerb::CookParms &cookparms) const
683  {
684  SOP_Node *thissop = cookparms.getNode();
685  if (!thissop) return getUsecaptpose();
686  bool result;
687  OP_Utils::evalOpParm(result, thissop, "usecaptpose", cookparms.getCookTime(), 0);
688  return result;
689  }
690  Cookat getCookat() const { return Cookat(myCookat); }
691  void setCookat(Cookat val) { myCookat = int64(val); }
692  Cookat opCookat(const SOP_NodeVerb::CookParms &cookparms) const
693  {
694  SOP_Node *thissop = cookparms.getNode();
695  if (!thissop) return getCookat();
696  int64 result;
697  OP_Utils::evalOpParm(result, thissop, "cookat", cookparms.getCookTime(), 0);
698  return Cookat(result);
699  }
700  fpreal64 getCaptframe() const { return myCaptframe; }
701  void setCaptframe(fpreal64 val) { myCaptframe = val; }
703  {
704  SOP_Node *thissop = cookparms.getNode();
705  if (!thissop) return getCaptframe();
706  fpreal64 result;
707  OP_Utils::evalOpParm(result, thissop, "captframe", cookparms.getCookTime(), 0);
708  return result;
709  }
710  Weightmethod getWeightmethod() const { return Weightmethod(myWeightmethod); }
711  void setWeightmethod(Weightmethod val) { myWeightmethod = int64(val); }
713  {
714  SOP_Node *thissop = cookparms.getNode();
715  if (!thissop) return getWeightmethod();
716  int64 result;
717  OP_Utils::evalOpParm(result, thissop, "weightmethod", cookparms.getCookTime(), 0);
718  return Weightmethod(result);
719  }
720  Weightfrom getWeightfrom() const { return Weightfrom(myWeightfrom); }
721  void setWeightfrom(Weightfrom val) { myWeightfrom = int64(val); }
723  {
724  SOP_Node *thissop = cookparms.getNode();
725  if (!thissop) return getWeightfrom();
726  int64 result;
727  OP_Utils::evalOpParm(result, thissop, "weightFrom", cookparms.getCookTime(), 0);
728  return Weightfrom(result);
729  }
730  fpreal64 getDropoff() const { return myDropoff; }
731  void setDropoff(fpreal64 val) { myDropoff = val; }
733  {
734  SOP_Node *thissop = cookparms.getNode();
735  if (!thissop) return getDropoff();
736  fpreal64 result;
737  OP_Utils::evalOpParm(result, thissop, "dropoff", cookparms.getCookTime(), 0);
738  return result;
739  }
740  int64 getMaxinfluences() const { return myMaxinfluences; }
741  void setMaxinfluences(int64 val) { myMaxinfluences = val; }
743  {
744  SOP_Node *thissop = cookparms.getNode();
745  if (!thissop) return getMaxinfluences();
746  int64 result;
747  OP_Utils::evalOpParm(result, thissop, "maxinfluences", cookparms.getCookTime(), 0);
748  return result;
749  }
750  bool getNormweights() const { return myNormweights; }
751  void setNormweights(bool val) { myNormweights = val; }
752  bool opNormweights(const SOP_NodeVerb::CookParms &cookparms) const
753  {
754  SOP_Node *thissop = cookparms.getNode();
755  if (!thissop) return getNormweights();
756  bool result;
757  OP_Utils::evalOpParm(result, thissop, "normweights", cookparms.getCookTime(), 0);
758  return result;
759  }
760  bool getDestroyweights() const { return myDestroyweights; }
761  void setDestroyweights(bool val) { myDestroyweights = val; }
762  bool opDestroyweights(const SOP_NodeVerb::CookParms &cookparms) const
763  {
764  SOP_Node *thissop = cookparms.getNode();
765  if (!thissop) return getDestroyweights();
766  bool result;
767  OP_Utils::evalOpParm(result, thissop, "destroyweights", cookparms.getCookTime(), 0);
768  return result;
769  }
770  fpreal64 getBlendfactor() const { return myBlendfactor; }
771  void setBlendfactor(fpreal64 val) { myBlendfactor = val; }
773  {
774  SOP_Node *thissop = cookparms.getNode();
775  if (!thissop) return getBlendfactor();
776  fpreal64 result;
777  OP_Utils::evalOpParm(result, thissop, "blendfactor", cookparms.getCookTime(), 0);
778  return result;
779  }
780  Color getColor() const { return Color(myColor); }
781  void setColor(Color val) { myColor = int64(val); }
782  Color opColor(const SOP_NodeVerb::CookParms &cookparms) const
783  {
784  SOP_Node *thissop = cookparms.getNode();
785  if (!thissop) return getColor();
786  int64 result;
787  OP_Utils::evalOpParm(result, thissop, "color", cookparms.getCookTime(), 0);
788  return Color(result);
789  }
790  UT_Vector3D getZeroweightcolor() const { return myZeroweightcolor; }
791  void setZeroweightcolor(UT_Vector3D val) { myZeroweightcolor = val; }
793  {
794  SOP_Node *thissop = cookparms.getNode();
795  if (!thissop) return getZeroweightcolor();
796  UT_Vector3D result;
797  OP_Utils::evalOpParm(result, thissop, "zeroweightcolor", cookparms.getCookTime(), 0);
798  return result;
799  }
800 
801 private:
802  UT_StringHolder myGroup;
803  UT_StringHolder myRootpath;
804  UT_StringHolder myExtraregions;
805  int64 myCaptureregionsop;
806  bool myDosubnets;
807  bool myRelativeskel;
808  bool myUsecaptpose;
809  int64 myCookat;
810  fpreal64 myCaptframe;
811  int64 myWeightmethod;
812  int64 myWeightfrom;
813  fpreal64 myDropoff;
814  int64 myMaxinfluences;
815  bool myNormweights;
816  bool myDestroyweights;
817  fpreal64 myBlendfactor;
818  int64 myColor;
819  UT_Vector3D myZeroweightcolor;
820 
821 };
UT_StringHolder opRootpath(const SOP_NodeVerb::CookParms &cookparms) const
bool opUsecaptpose(const SOP_NodeVerb::CookParms &cookparms) const
void setParmValue(exint idx, const UT_Matrix2D &value)
static void saveData(std::ostream &os, fpreal64 v)
int64 opMaxinfluences(const SOP_NodeVerb::CookParms &cookparms) const
void setExtraregions(const UT_StringHolder &val)
Color opColor(const SOP_NodeVerb::CookParms &cookparms) const
SOP_Node * getNode() const
Definition: SOP_NodeVerb.h:494
void getParmValue(exint idx, UT_Matrix3D &value) const
void setParmValue(exint idx, const UT_Vector2D &value)
T & z(void)
Definition: UT_Vector4.h:379
static void loadData(UT_IStream &is, UT_Vector3D &v)
void setWeightmethod(Weightmethod val)
bool opNormweights(const SOP_NodeVerb::CookParms &cookparms) const
bool operator==(const SOP_ProximityCaptureParms &src) const
exint bread(int32 *buffer, exint asize=1)
GT_API const UT_StringHolder time
static void loadData(UT_IStream &is, UT_Vector4I &v)
fpreal getTime() const
Definition: OP_Context.h:60
const GLdouble * v
Definition: glcorearb.h:836
UT_StringHolder opGroup(const SOP_NodeVerb::CookParms &cookparms) const
fpreal64 opCaptframe(const SOP_NodeVerb::CookParms &cookparms) const
fpreal64 opBlendfactor(const SOP_NodeVerb::CookParms &cookparms) const
void doSetParmValue(exint idx, const T &value)
SYS_FORCE_INLINE const char * buffer() const
T & x(void)
Definition: UT_Vector2.h:285
const UT_StringHolder & getExtraregions() const
void getParmValue(exint idx, UT_Matrix2D &value) const
void setZeroweightcolor(UT_Vector3D val)
An output stream object that owns its own string buffer storage.
virtual void loadFromOpSubclass(const LoadParms &loadparms)
void setGroup(const UT_StringHolder &val)
const UT_WorkBuffer & str() const
Returns a read-only reference to the underlying UT_WorkBuffer.
SYS_FORCE_INLINE T & x(void)
Definition: UT_Vector3.h:498
static void loadData(UT_IStream &is, UT_Matrix3D &v)
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
void setCaptureregionsop(Captureregionsop val)
static void saveData(std::ostream &os, UT_Matrix2D v)
static void loadData(UT_IStream &is, UT_Vector2I &v)
virtual ParmType getParmType(exint fieldnum) const
static void saveData(std::ostream &os, PRM_DataItemHandle s)
static void saveData(std::ostream &os, UT_Matrix4D v)
UT_Vector3D opZeroweightcolor(const SOP_NodeVerb::CookParms &cookparms) const
SYS_FORCE_INLINE T & z(void)
Definition: UT_Vector3.h:502
static void loadData(UT_IStream &is, UT_Vector3I &v)
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
Definition: Dimensions.h:137
long long int64
Definition: SYS_Types.h:107
static void saveData(std::ostream &os, UT_Vector2D v)
void save(std::ostream &os) const
const UT_StringHolder & getRootpath() const
static void saveData(std::ostream &os, UT_Vector3D v)
UT_StringHolder opExtraregions(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
void getParmValue(exint idx, PRM_DataItemHandle &value) const
static void saveData(std::ostream &os, UT_Matrix3D v)
static void loadData(UT_IStream &is, UT_StringHolder &v)
exint length() const
void setParmValue(exint idx, const exint &value)
char * findChar(int c) const
Find first occurrance of character. Returns NULL upon failure.
Definition: UT_String.h:550
Captureregionsop getCaptureregionsop() const
SYS_FORCE_INLINE const char * buffer() const
bool opDosubnets(const SOP_NodeVerb::CookParms &cookparms) const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
Definition: UT_SharedPtr.h:28
int64 exint
Definition: SYS_Types.h:116
void setParmValue(exint idx, const UT_Vector4D &value)
Captureregionsop opCaptureregionsop(const SOP_NodeVerb::CookParms &cookparms) const
const OP_Node * node() const
Definition: SOP_NodeVerb.h:104
void getParmValue(exint idx, UT_Matrix4D &value) const
double fpreal64
Definition: SYS_Types.h:192
static void loadData(UT_IStream &is, bool &v)
void setRootpath(const UT_StringHolder &val)
static void saveData(std::ostream &os, bool v)
void setParmValue(exint idx, const UT_SharedPtr< UT_Ramp > &value)
void getParmValue(exint idx, UT_Vector2D &value) const
static void saveData(std::ostream &os, UT_StringHolder s)
Cookat opCookat(const SOP_NodeVerb::CookParms &cookparms) const
UT_Vector3T< fpreal64 > UT_Vector3D
GLboolean * data
Definition: glcorearb.h:130
int int32
Definition: SYS_Types.h:35
T & y(void)
Definition: UT_Vector4.h:377
void setParmValue(exint idx, const UT_Vector3D &value)
void buildFromOp(const OP_Node *node, fpreal time, DEP_MicroNode *depnode)
void getParmValue(exint idx, UT_SharedPtr< UT_Ramp > &value) const
void saveBinary(std::ostream &os) const
Save string to binary stream.
Definition: UT_String.h:294
void setParmValue(exint idx, const UT_Matrix4D &value)
GT_API const UT_StringHolder version
void getParmValue(exint idx, exint &value) const
DEP_MicroNode * depnode() const
Definition: SOP_NodeVerb.h:111
void setParmValue(exint idx, const PRM_DataItemHandle &value)
static void saveData(std::ostream &os, UT_Vector4D v)
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)
virtual const char * getParmName(exint fieldnum) const
Weightfrom opWeightfrom(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, int64 v)
void setParmValue(exint idx, const UT_Matrix3D &value)
bool opDestroyweights(const SOP_NodeVerb::CookParms &cookparms) const
Utility class for containing a color ramp.
Definition: UT_Ramp.h:84
bool operator!=(const SOP_ProximityCaptureParms &src) const
void getParmValue(exint idx, fpreal &value) const
GLuint GLfloat * val
Definition: glcorearb.h:1607
fpreal64 opDropoff(const SOP_NodeVerb::CookParms &cookparms) const
#define SOP_API
Definition: SOP_API.h:10
static void loadData(UT_IStream &is, UT_Vector2D &v)
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
static void loadData(UT_IStream &is, int64 &v)
GLint GLint GLsizei GLint GLenum GLenum type
Definition: glcorearb.h:107
fpreal getCookTime() const
Definition: SOP_NodeVerb.h:501
T & x(void)
Definition: UT_Vector4.h:375
Weightmethod opWeightmethod(const SOP_NodeVerb::CookParms &cookparms) const
T & y(void)
Definition: UT_Vector2.h:287
virtual void copyFrom(const SOP_NodeParms *src)
GLboolean r
Definition: glcorearb.h:1221
static void loadData(UT_IStream &is, UT_Matrix4D &v)
T & w(void)
Definition: UT_Vector4.h:381
static void loadData(UT_IStream &is, UT_Vector4D &v)
void getParmValue(exint idx, UT_StringHolder &value) const
void setParmValue(exint idx, const UT_StringHolder &value)
static void loadData(UT_IStream &is, fpreal64 &v)
void getParmValue(exint idx, UT_Vector4D &value) const
static void loadData(UT_IStream &is, UT_Matrix2D &v)
const OP_Context & context() const
Definition: SOP_NodeVerb.h:109
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
Definition: PRM_Parm.h:88
SYS_FORCE_INLINE bool isstring() const
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
bool opRelativeskel(const SOP_NodeVerb::CookParms &cookparms) const
const UT_StringHolder & getGroup() const
void setParmValue(exint idx, const fpreal &value)
void doGetParmValue(exint idx, T &value) const
GLenum src
Definition: glcorearb.h:1792
void getParmValue(exint idx, UT_Vector3D &value) const