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