HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SOP_Inflate.proto.h
Go to the documentation of this file.
1 /* Automagically Generated by generate_proto.py
2  * Do not Edit
3  */
4 #pragma once
5 
6 #include <SOP/SOP_API.h>
7 #include <SOP/SOP_NodeVerb.h>
8 #include <SOP/SOP_GraphProxy.h>
9 
10 #include <OP/OP_Utils.h>
11 #include <PRM/PRM_Parm.h>
12 #include <UT/UT_IStream.h>
13 #include <UT/UT_NTStreamUtil.h>
14 #include <UT/UT_Ramp.h>
15 #include <UT/UT_SharedPtr.h>
16 #include <UT/UT_StringHolder.h>
17 #include <UT/UT_StringStream.h>
18 #include <UT/UT_VectorTypes.h>
19 #include <UT/UT_EnvControl.h>
20 #include <SYS/SYS_Types.h>
21 
22 class DEP_MicroNode;
23 
25 {
26 public:
27  static int version() { return 1; }
28 
30  {
31  myGroup = ""_UTsh;
32  myToolgroup = ""_UTsh;
33  myCentergroup = ""_UTsh;
34  myCenterprimgroup = ""_UTsh;
35  myToolidname = "toolid"_UTsh;
36  myCenteroverlap = 0;
37  myBlendexponent = 2;
38  myClampsurfdist = true;
39  myMinsurfdist = 0;
40  myTightness = 3;
41  myInflatetofarthest = false;
42  myMaxinflateenable = false;
43  myMaxinflate = 1;
44 
45  }
46 
47  explicit SOP_InflateParms(const SOP_InflateParms &) = default;
48  SOP_InflateParms &operator=(const SOP_InflateParms &) = default;
49  SOP_InflateParms(SOP_InflateParms &&) noexcept = default;
50  SOP_InflateParms &operator=(SOP_InflateParms &&) noexcept = default;
51 
52  ~SOP_InflateParms() override {}
53 
54  bool operator==(const SOP_InflateParms &src) const
55  {
56  if (myGroup != src.myGroup) return false;
57  if (myToolgroup != src.myToolgroup) return false;
58  if (myCentergroup != src.myCentergroup) return false;
59  if (myCenterprimgroup != src.myCenterprimgroup) return false;
60  if (myToolidname != src.myToolidname) return false;
61  if (myCenteroverlap != src.myCenteroverlap) return false;
62  if (myBlendexponent != src.myBlendexponent) return false;
63  if (myClampsurfdist != src.myClampsurfdist) return false;
64  if (myMinsurfdist != src.myMinsurfdist) return false;
65  if (myTightness != src.myTightness) return false;
66  if (myInflatetofarthest != src.myInflatetofarthest) return false;
67  if (myMaxinflateenable != src.myMaxinflateenable) return false;
68  if (myMaxinflate != src.myMaxinflate) return false;
69 
70  return true;
71  }
72  bool operator!=(const SOP_InflateParms &src) const
73  {
74  return !operator==(src);
75  }
76 
77 
78 
79  void buildFromOp(const OP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
80  {
81  myGroup = ""_UTsh;
82  if (true)
83  graph->evalOpParm(myGroup, nodeidx, "group", time, 0);
84  myToolgroup = ""_UTsh;
85  if (true)
86  graph->evalOpParm(myToolgroup, nodeidx, "toolgroup", time, 0);
87  myCentergroup = ""_UTsh;
88  if (true)
89  graph->evalOpParm(myCentergroup, nodeidx, "centergroup", time, 0);
90  myCenterprimgroup = ""_UTsh;
91  if (true)
92  graph->evalOpParm(myCenterprimgroup, nodeidx, "centerprimgroup", time, 0);
93  myToolidname = "toolid"_UTsh;
94  if (true)
95  graph->evalOpParm(myToolidname, nodeidx, "toolidname", time, 0);
96  myCenteroverlap = 0;
97  if (true)
98  graph->evalOpParm(myCenteroverlap, nodeidx, "centeroverlap", time, 0);
99  myBlendexponent = 2;
100  if (true)
101  graph->evalOpParm(myBlendexponent, nodeidx, "blendexponent", time, 0);
102  myClampsurfdist = true;
103  if (true)
104  graph->evalOpParm(myClampsurfdist, nodeidx, "clampsurfdist", time, 0);
105  myMinsurfdist = 0;
106  if (true && ( (true&&!(((getClampsurfdist()==0)))) ) )
107  graph->evalOpParm(myMinsurfdist, nodeidx, "minsurfdist", time, 0);
108  myTightness = 3;
109  if (true)
110  graph->evalOpParm(myTightness, nodeidx, "tightness", time, 0);
111  myInflatetofarthest = false;
112  if (true)
113  graph->evalOpParm(myInflatetofarthest, nodeidx, "inflatetofarthest", time, 0);
114  myMaxinflateenable = false;
115  if (true)
116  graph->evalOpParm(myMaxinflateenable, nodeidx, "maxinflateenable", time, 0);
117  myMaxinflate = 1;
118  if (true && ( (true&&!(((getMaxinflateenable()==0)))) ) )
119  graph->evalOpParm(myMaxinflate, nodeidx, "maxinflate", time, 0);
120 
121  }
122 
123 
124  void loadFromOpSubclass(const LoadParms &loadparms) override
125  {
126  buildFromOp(loadparms.graph(), loadparms.nodeIdx(), loadparms.context().getTime(), loadparms.depnode());
127  }
128 
129 
130  void copyFrom(const OP_NodeParms *src) override
131  {
132  *this = *((const SOP_InflateParms *)src);
133  }
134 
135  template <typename T>
136  void
137  doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
138  {
139  if (idx.size() < 1)
140  return;
141  UT_ASSERT(idx.size() == instance.size()+1);
142  if (idx.size() != instance.size()+1)
143  return;
144  switch (idx[0])
145  {
146  case 0:
147  coerceValue(value, myGroup);
148  break;
149  case 1:
150  coerceValue(value, myToolgroup);
151  break;
152  case 2:
153  coerceValue(value, myCentergroup);
154  break;
155  case 3:
156  coerceValue(value, myCenterprimgroup);
157  break;
158  case 4:
159  coerceValue(value, myToolidname);
160  break;
161  case 5:
162  coerceValue(value, myCenteroverlap);
163  break;
164  case 6:
165  coerceValue(value, myBlendexponent);
166  break;
167  case 7:
168  coerceValue(value, myClampsurfdist);
169  break;
170  case 8:
171  coerceValue(value, myMinsurfdist);
172  break;
173  case 9:
174  coerceValue(value, myTightness);
175  break;
176  case 10:
177  coerceValue(value, myInflatetofarthest);
178  break;
179  case 11:
180  coerceValue(value, myMaxinflateenable);
181  break;
182  case 12:
183  coerceValue(value, myMaxinflate);
184  break;
185 
186  }
187  }
188 
189  bool isParmColorRamp(exint idx) const override
190  {
191  switch (idx)
192  {
193 
194  }
195  return false;
196  }
197 
198  void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
199  { doGetParmValue(idx, instance, value); }
200  void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
201  { doGetParmValue(idx, instance, value); }
202  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
203  { doGetParmValue(idx, instance, value); }
204  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
205  { doGetParmValue(idx, instance, value); }
206  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
207  { doGetParmValue(idx, instance, value); }
208  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
209  { doGetParmValue(idx, instance, value); }
210  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
211  { doGetParmValue(idx, instance, value); }
212  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
213  { doGetParmValue(idx, instance, value); }
214  void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
215  { doGetParmValue(idx, instance, value); }
216  void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr<UT_Ramp> &value) const override
217  { doGetParmValue(idx, instance, value); }
218  void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
219  { doGetParmValue(idx, instance, value); }
220 
221  template <typename T>
222  void
223  doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
224  {
225  if (idx.size() < 1)
226  return;
227  UT_ASSERT(idx.size() == instance.size()+1);
228  if (idx.size() != instance.size()+1)
229  return;
230  switch (idx[0])
231  {
232  case 0:
233  coerceValue(myGroup, ( ( value ) ));
234  break;
235  case 1:
236  coerceValue(myToolgroup, ( ( value ) ));
237  break;
238  case 2:
239  coerceValue(myCentergroup, ( ( value ) ));
240  break;
241  case 3:
242  coerceValue(myCenterprimgroup, ( ( value ) ));
243  break;
244  case 4:
245  coerceValue(myToolidname, ( ( value ) ));
246  break;
247  case 5:
248  coerceValue(myCenteroverlap, ( ( value ) ));
249  break;
250  case 6:
251  coerceValue(myBlendexponent, ( ( value ) ));
252  break;
253  case 7:
254  coerceValue(myClampsurfdist, ( ( value ) ));
255  break;
256  case 8:
257  coerceValue(myMinsurfdist, ( ( value ) ));
258  break;
259  case 9:
260  coerceValue(myTightness, ( ( value ) ));
261  break;
262  case 10:
263  coerceValue(myInflatetofarthest, ( ( value ) ));
264  break;
265  case 11:
266  coerceValue(myMaxinflateenable, ( ( value ) ));
267  break;
268  case 12:
269  coerceValue(myMaxinflate, ( ( value ) ));
270  break;
271 
272  }
273  }
274 
275  void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
276  { doSetParmValue(idx, instance, value); }
277  void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
278  { doSetParmValue(idx, instance, value); }
279  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
280  { doSetParmValue(idx, instance, value); }
281  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
282  { doSetParmValue(idx, instance, value); }
283  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
284  { doSetParmValue(idx, instance, value); }
285  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
286  { doSetParmValue(idx, instance, value); }
287  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
288  { doSetParmValue(idx, instance, value); }
289  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
290  { doSetParmValue(idx, instance, value); }
291  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
292  { doSetParmValue(idx, instance, value); }
293  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr<UT_Ramp> &value) override
294  { doSetParmValue(idx, instance, value); }
295  void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
296  { doSetParmValue(idx, instance, value); }
297 
298  exint getNestNumParms(TempIndex idx) const override
299  {
300  if (idx.size() == 0)
301  return 13;
302  switch (idx[0])
303  {
304 
305  }
306  // Invalid
307  return 0;
308  }
309 
310  const char *getNestParmName(TempIndex fieldnum) const override
311  {
312  if (fieldnum.size() < 1)
313  return 0;
314  switch (fieldnum[0])
315  {
316  case 0:
317  return "group";
318  case 1:
319  return "toolgroup";
320  case 2:
321  return "centergroup";
322  case 3:
323  return "centerprimgroup";
324  case 4:
325  return "toolidname";
326  case 5:
327  return "centeroverlap";
328  case 6:
329  return "blendexponent";
330  case 7:
331  return "clampsurfdist";
332  case 8:
333  return "minsurfdist";
334  case 9:
335  return "tightness";
336  case 10:
337  return "inflatetofarthest";
338  case 11:
339  return "maxinflateenable";
340  case 12:
341  return "maxinflate";
342 
343  }
344  return 0;
345  }
346 
347  ParmType getNestParmType(TempIndex fieldnum) const override
348  {
349  if (fieldnum.size() < 1)
350  return PARM_UNSUPPORTED;
351  switch (fieldnum[0])
352  {
353  case 0:
354  return PARM_STRING;
355  case 1:
356  return PARM_STRING;
357  case 2:
358  return PARM_STRING;
359  case 3:
360  return PARM_STRING;
361  case 4:
362  return PARM_STRING;
363  case 5:
364  return PARM_FLOAT;
365  case 6:
366  return PARM_FLOAT;
367  case 7:
368  return PARM_INTEGER;
369  case 8:
370  return PARM_FLOAT;
371  case 9:
372  return PARM_FLOAT;
373  case 10:
374  return PARM_INTEGER;
375  case 11:
376  return PARM_INTEGER;
377  case 12:
378  return PARM_FLOAT;
379 
380  }
381  return PARM_UNSUPPORTED;
382  }
383 
384  // Boiler plate to load individual types.
385  static void loadData(UT_IStream &is, int64 &v)
386  { is.bread(&v, 1); }
387  static void loadData(UT_IStream &is, bool &v)
388  { int64 iv; is.bread(&iv, 1); v = iv; }
389  static void loadData(UT_IStream &is, fpreal64 &v)
390  { is.bread<fpreal64>(&v, 1); }
391  static void loadData(UT_IStream &is, UT_Vector2D &v)
392  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1); }
393  static void loadData(UT_IStream &is, UT_Vector3D &v)
394  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
395  is.bread<fpreal64>(&v.z(), 1); }
396  static void loadData(UT_IStream &is, UT_Vector4D &v)
397  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
398  is.bread<fpreal64>(&v.z(), 1); is.bread<fpreal64>(&v.w(), 1); }
399  static void loadData(UT_IStream &is, UT_Matrix2D &v)
400  { for (int r = 0; r < 2; r++) for (int c = 0; c < 2; c++) is.bread<fpreal64>(&v(r, c), 1); }
401  static void loadData(UT_IStream &is, UT_Matrix3D &v)
402  { for (int r = 0; r < 3; r++) for (int c = 0; c < 3; c++) is.bread<fpreal64>(&v(r, c), 1); }
403  static void loadData(UT_IStream &is, UT_Matrix4D &v)
404  { for (int r = 0; r < 4; r++) for (int c = 0; c < 4; c++) is.bread<fpreal64>(&v(r, c), 1); }
405  static void loadData(UT_IStream &is, UT_Vector2I &v)
406  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1); }
407  static void loadData(UT_IStream &is, UT_Vector3I &v)
408  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
409  is.bread<int64>(&v.z(), 1); }
410  static void loadData(UT_IStream &is, UT_Vector4I &v)
411  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
412  is.bread<int64>(&v.z(), 1); is.bread<int64>(&v.w(), 1); }
414  { is.bread(v); }
416  { UT_StringHolder rampdata;
417  loadData(is, rampdata);
418  if (rampdata.isstring())
419  {
420  v.reset(new UT_Ramp());
421  UT_IStream istr((const char *) rampdata, rampdata.length(), UT_ISTREAM_ASCII);
422  v->load(istr);
423  }
424  else v.reset();
425  }
428  loadData(is, data);
429  if (data.isstring())
430  {
431  // Find the data type.
432  const char *colon = UT_StringWrap(data).findChar(':');
433  if (colon)
434  {
435  int typelen = colon - data.buffer();
437  type.strncpy(data.buffer(), typelen);
438  UT_IStream istr(((const char *) data) + typelen + 1, data.length() - (typelen + 1), UT_ISTREAM_BINARY);
439 
440  v = PRM_DataFactory::parseBinary(type.buffer(), istr);
441  }
442  }
443  else v.reset();
444  }
445 
446  static void saveData(std::ostream &os, int64 v)
447  { UTwrite(os, &v); }
448  static void saveData(std::ostream &os, bool v)
449  { int64 iv = v; UTwrite(os, &iv); }
450  static void saveData(std::ostream &os, fpreal64 v)
451  { UTwrite<fpreal64>(os, &v); }
452  static void saveData(std::ostream &os, UT_Vector2D v)
453  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y()); }
454  static void saveData(std::ostream &os, UT_Vector3D v)
455  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
456  UTwrite<fpreal64>(os, &v.z()); }
457  static void saveData(std::ostream &os, UT_Vector4D v)
458  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
459  UTwrite<fpreal64>(os, &v.z()); UTwrite<fpreal64>(os, &v.w()); }
460  static void saveData(std::ostream &os, UT_Matrix2D v)
462  static void saveData(std::ostream &os, UT_Matrix3D v)
464  static void saveData(std::ostream &os, UT_Matrix4D v)
466  static void saveData(std::ostream &os, UT_StringHolder s)
467  { UT_StringWrap(s).saveBinary(os); }
468  static void saveData(std::ostream &os, UT_SharedPtr<UT_Ramp> s)
470  UT_OStringStream ostr;
471  if (s) s->save(ostr);
472  result = ostr.str();
473  saveData(os, result);
474  }
475  static void saveData(std::ostream &os, PRM_DataItemHandle s)
477  UT_OStringStream ostr;
478  if (s)
479  {
480  ostr << s->getDataTypeToken();
481  ostr << ":";
482  s->saveBinary(ostr);
483  }
484  result = ostr.str();
485  saveData(os, result);
486  }
487 
488 
489  void save(std::ostream &os) const
490  {
491  int32 v = version();
492  UTwrite(os, &v);
493  saveData(os, myGroup);
494  saveData(os, myToolgroup);
495  saveData(os, myCentergroup);
496  saveData(os, myCenterprimgroup);
497  saveData(os, myToolidname);
498  saveData(os, myCenteroverlap);
499  saveData(os, myBlendexponent);
500  saveData(os, myClampsurfdist);
501  saveData(os, myMinsurfdist);
502  saveData(os, myTightness);
503  saveData(os, myInflatetofarthest);
504  saveData(os, myMaxinflateenable);
505  saveData(os, myMaxinflate);
506 
507  }
508 
509  bool load(UT_IStream &is)
510  {
511  int32 v;
512  is.bread(&v, 1);
513  if (version() != v)
514  {
515  // Fail incompatible versions
516  return false;
517  }
518  loadData(is, myGroup);
519  loadData(is, myToolgroup);
520  loadData(is, myCentergroup);
521  loadData(is, myCenterprimgroup);
522  loadData(is, myToolidname);
523  loadData(is, myCenteroverlap);
524  loadData(is, myBlendexponent);
525  loadData(is, myClampsurfdist);
526  loadData(is, myMinsurfdist);
527  loadData(is, myTightness);
528  loadData(is, myInflatetofarthest);
529  loadData(is, myMaxinflateenable);
530  loadData(is, myMaxinflate);
531 
532  return true;
533  }
534 
535  const UT_StringHolder & getGroup() const { return myGroup; }
536  void setGroup(const UT_StringHolder & val) { myGroup = val; }
538  {
539  SOP_Node *thissop = cookparms.getNode();
540  if (!thissop) return getGroup();
542  OP_Utils::evalOpParm(result, thissop, "group", cookparms.getCookTime(), 0);
543  return result;
544  }
545  const UT_StringHolder & getToolgroup() const { return myToolgroup; }
546  void setToolgroup(const UT_StringHolder & val) { myToolgroup = val; }
548  {
549  SOP_Node *thissop = cookparms.getNode();
550  if (!thissop) return getToolgroup();
552  OP_Utils::evalOpParm(result, thissop, "toolgroup", cookparms.getCookTime(), 0);
553  return result;
554  }
555  const UT_StringHolder & getCentergroup() const { return myCentergroup; }
556  void setCentergroup(const UT_StringHolder & val) { myCentergroup = val; }
558  {
559  SOP_Node *thissop = cookparms.getNode();
560  if (!thissop) return getCentergroup();
562  OP_Utils::evalOpParm(result, thissop, "centergroup", cookparms.getCookTime(), 0);
563  return result;
564  }
565  const UT_StringHolder & getCenterprimgroup() const { return myCenterprimgroup; }
566  void setCenterprimgroup(const UT_StringHolder & val) { myCenterprimgroup = val; }
568  {
569  SOP_Node *thissop = cookparms.getNode();
570  if (!thissop) return getCenterprimgroup();
572  OP_Utils::evalOpParm(result, thissop, "centerprimgroup", cookparms.getCookTime(), 0);
573  return result;
574  }
575  const UT_StringHolder & getToolidname() const { return myToolidname; }
576  void setToolidname(const UT_StringHolder & val) { myToolidname = val; }
578  {
579  SOP_Node *thissop = cookparms.getNode();
580  if (!thissop) return getToolidname();
582  OP_Utils::evalOpParm(result, thissop, "toolidname", cookparms.getCookTime(), 0);
583  return result;
584  }
585  fpreal64 getCenteroverlap() const { return myCenteroverlap; }
586  void setCenteroverlap(fpreal64 val) { myCenteroverlap = val; }
588  {
589  SOP_Node *thissop = cookparms.getNode();
590  if (!thissop) return getCenteroverlap();
592  OP_Utils::evalOpParm(result, thissop, "centeroverlap", cookparms.getCookTime(), 0);
593  return result;
594  }
595  fpreal64 getBlendexponent() const { return myBlendexponent; }
596  void setBlendexponent(fpreal64 val) { myBlendexponent = val; }
598  {
599  SOP_Node *thissop = cookparms.getNode();
600  if (!thissop) return getBlendexponent();
602  OP_Utils::evalOpParm(result, thissop, "blendexponent", cookparms.getCookTime(), 0);
603  return result;
604  }
605  bool getClampsurfdist() const { return myClampsurfdist; }
606  void setClampsurfdist(bool val) { myClampsurfdist = val; }
607  bool opClampsurfdist(const SOP_NodeVerb::CookParms &cookparms) const
608  {
609  SOP_Node *thissop = cookparms.getNode();
610  if (!thissop) return getClampsurfdist();
611  bool result;
612  OP_Utils::evalOpParm(result, thissop, "clampsurfdist", cookparms.getCookTime(), 0);
613  return result;
614  }
615  fpreal64 getMinsurfdist() const { return myMinsurfdist; }
616  void setMinsurfdist(fpreal64 val) { myMinsurfdist = val; }
618  {
619  SOP_Node *thissop = cookparms.getNode();
620  if (!thissop) return getMinsurfdist();
622  OP_Utils::evalOpParm(result, thissop, "minsurfdist", cookparms.getCookTime(), 0);
623  return result;
624  }
625  fpreal64 getTightness() const { return myTightness; }
626  void setTightness(fpreal64 val) { myTightness = val; }
628  {
629  SOP_Node *thissop = cookparms.getNode();
630  if (!thissop) return getTightness();
632  OP_Utils::evalOpParm(result, thissop, "tightness", cookparms.getCookTime(), 0);
633  return result;
634  }
635  bool getInflatetofarthest() const { return myInflatetofarthest; }
636  void setInflatetofarthest(bool val) { myInflatetofarthest = val; }
637  bool opInflatetofarthest(const SOP_NodeVerb::CookParms &cookparms) const
638  {
639  SOP_Node *thissop = cookparms.getNode();
640  if (!thissop) return getInflatetofarthest();
641  bool result;
642  OP_Utils::evalOpParm(result, thissop, "inflatetofarthest", cookparms.getCookTime(), 0);
643  return result;
644  }
645  bool getMaxinflateenable() const { return myMaxinflateenable; }
646  void setMaxinflateenable(bool val) { myMaxinflateenable = val; }
647  bool opMaxinflateenable(const SOP_NodeVerb::CookParms &cookparms) const
648  {
649  SOP_Node *thissop = cookparms.getNode();
650  if (!thissop) return getMaxinflateenable();
651  bool result;
652  OP_Utils::evalOpParm(result, thissop, "maxinflateenable", cookparms.getCookTime(), 0);
653  return result;
654  }
655  fpreal64 getMaxinflate() const { return myMaxinflate; }
656  void setMaxinflate(fpreal64 val) { myMaxinflate = val; }
658  {
659  SOP_Node *thissop = cookparms.getNode();
660  if (!thissop) return getMaxinflate();
662  OP_Utils::evalOpParm(result, thissop, "maxinflate", cookparms.getCookTime(), 0);
663  return result;
664  }
665 
666 private:
667  UT_StringHolder myGroup;
668  UT_StringHolder myToolgroup;
669  UT_StringHolder myCentergroup;
670  UT_StringHolder myCenterprimgroup;
671  UT_StringHolder myToolidname;
672  fpreal64 myCenteroverlap;
673  fpreal64 myBlendexponent;
674  bool myClampsurfdist;
675  fpreal64 myMinsurfdist;
676  fpreal64 myTightness;
677  bool myInflatetofarthest;
678  bool myMaxinflateenable;
679  fpreal64 myMaxinflate;
680 
681 };
static void loadData(UT_IStream &is, UT_Vector3I &v)
static void loadData(UT_IStream &is, UT_Vector4D &v)
static void saveData(std::ostream &os, UT_Matrix2D v)
ParmType getNestParmType(TempIndex fieldnum) const override
void setMinsurfdist(fpreal64 val)
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
int int32
Definition: SYS_Types.h:39
SOP_Node * getNode() const
Definition: SOP_NodeVerb.h:347
void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
void setMaxinflateenable(bool val)
void copyFrom(const OP_NodeParms *src) override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
void doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
exint bread(int32 *buffer, exint asize=1)
GLboolean * data
Definition: glcorearb.h:131
GT_API const UT_StringHolder time
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector4.h:493
UT_StringHolder opGroup(const SOP_NodeVerb::CookParms &cookparms) const
const GLdouble * v
Definition: glcorearb.h:837
bool operator!=(const SOP_InflateParms &src) const
fpreal getTime() const
Definition: OP_Context.h:62
static void loadData(UT_IStream &is, fpreal64 &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
const OP_Context & context() const
Definition: OP_NodeParms.h:97
const UT_StringHolder & getToolgroup() const
constexpr SYS_FORCE_INLINE T & z() noexcept
Definition: UT_Vector3.h:667
int64 exint
Definition: SYS_Types.h:125
SYS_FORCE_INLINE const char * buffer() const
static void saveData(std::ostream &os, PRM_DataItemHandle s)
GLdouble s
Definition: glad.h:3009
UT_StringHolder opCentergroup(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, int64 v)
An output stream object that owns its own string buffer storage.
static void loadData(UT_IStream &is, UT_Vector4I &v)
**But if you need a result
Definition: thread.h:613
static void saveData(std::ostream &os, UT_Matrix3D v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
fpreal64 opMinsurfdist(const SOP_NodeVerb::CookParms &cookparms) const
exint nodeIdx() const
Definition: OP_NodeParms.h:95
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
const UT_WorkBuffer & str()
Returns a read-only reference to the underlying UT_WorkBuffer.
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
bool load(UT_IStream &is)
static void loadData(UT_IStream &is, UT_Matrix2D &v)
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector4.h:491
bool operator==(const SOP_InflateParms &src) const
fpreal64 getTightness() const
static void loadData(UT_IStream &is, UT_Vector2I &v)
void setCentergroup(const UT_StringHolder &val)
double fpreal64
Definition: SYS_Types.h:201
void setCenterprimgroup(const UT_StringHolder &val)
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector2.h:423
static void loadData(UT_IStream &is, UT_Matrix4D &v)
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
Definition: Dimensions.h:137
void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
fpreal64 getMaxinflate() const
exint length() const
void doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
SYS_FORCE_INLINE const char * buffer() const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
Definition: UT_SharedPtr.h:36
constexpr SYS_FORCE_INLINE T & z() noexcept
Definition: UT_Vector4.h:495
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
void loadFromOpSubclass(const LoadParms &loadparms) override
void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
fpreal64 getCenteroverlap() const
const OP_GraphProxy * graph() const
Definition: OP_NodeParms.h:94
void setClampsurfdist(bool val)
fpreal64 getBlendexponent() const
UT_StringHolder opToolgroup(const SOP_NodeVerb::CookParms &cookparms) const
void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
void setGroup(const UT_StringHolder &val)
fpreal64 getMinsurfdist() const
static void saveData(std::ostream &os, fpreal64 v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
fpreal64 opCenteroverlap(const SOP_NodeVerb::CookParms &cookparms) const
void setInflatetofarthest(bool val)
const UT_StringHolder & getToolidname() const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
long long int64
Definition: SYS_Types.h:116
static void saveData(std::ostream &os, UT_Vector3D v)
static void loadData(UT_IStream &is, int64 &v)
const char * getNestParmName(TempIndex fieldnum) const override
bool getInflatetofarthest() const
bool opMaxinflateenable(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
fpreal64 opTightness(const SOP_NodeVerb::CookParms &cookparms) const
void setToolgroup(const UT_StringHolder &val)
const UT_StringHolder & getCenterprimgroup() const
static void saveData(std::ostream &os, UT_StringHolder s)
virtual void evalOpParm(int64 &v, NodeIdx node, const char *parmname, fpreal time, DEP_MicroNode *depnode) const =0
bool getMaxinflateenable() const
bool getClampsurfdist() const
void saveBinary(std::ostream &os) const
Save string to binary stream.
Definition: UT_String.h:296
bool opInflatetofarthest(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, UT_Matrix3D &v)
GT_API const UT_StringHolder version
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr< UT_Ramp > &value) override
static int version()
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
void coerceValue(T &result, const S &src) const
Definition: OP_NodeParms.h:301
bool opClampsurfdist(const SOP_NodeVerb::CookParms &cookparms) const
const UT_StringHolder & getGroup() const
static void saveData(std::ostream &os, UT_Matrix4D v)
void save(std::ostream &os) const
fpreal64 fpreal
Definition: SYS_Types.h:277
UT_StringHolder opCenterprimgroup(const SOP_NodeVerb::CookParms &cookparms) const
DEP_MicroNode * depnode() const
Definition: OP_NodeParms.h:99
void setMaxinflate(fpreal64 val)
Utility class for containing a color ramp.
Definition: UT_Ramp.h:92
void setCenteroverlap(fpreal64 val)
constexpr SYS_FORCE_INLINE T & w() noexcept
Definition: UT_Vector4.h:497
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
static void loadData(UT_IStream &is, UT_Vector3D &v)
GLuint GLfloat * val
Definition: glcorearb.h:1608
static void saveData(std::ostream &os, UT_Vector4D v)
UT_StringHolder opToolidname(const SOP_NodeVerb::CookParms &cookparms) const
#define SOP_API
Definition: SOP_API.h:10
void setTightness(fpreal64 val)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
fpreal getCookTime() const
Definition: SOP_NodeVerb.h:361
static void loadData(UT_IStream &is, bool &v)
fpreal64 opMaxinflate(const SOP_NodeVerb::CookParms &cookparms) const
const char * findChar(int c) const
Definition: UT_String.h:1395
#define UT_ASSERT(ZZ)
Definition: UT_Assert.h:156
Definition: core.h:1131
void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
bool isParmColorRamp(exint idx) const override
GLboolean r
Definition: glcorearb.h:1222
void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector3.h:665
static void saveData(std::ostream &os, UT_Vector2D v)
const UT_StringHolder & getCentergroup() const
static void loadData(UT_IStream &is, UT_StringHolder &v)
type
Definition: core.h:1059
void setToolidname(const UT_StringHolder &val)
void setBlendexponent(fpreal64 val)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr< UT_Ramp > &value) const override
static void saveData(std::ostream &os, bool v)
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
Definition: PRM_Parm.h:97
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector2.h:425
SYS_FORCE_INLINE bool isstring() const
exint getNestNumParms(TempIndex idx) const override
void buildFromOp(const OP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
OP_NodeParms & operator=(const OP_NodeParms &)=default
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
GLenum src
Definition: glcorearb.h:1793
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector3.h:663
fpreal64 opBlendexponent(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, UT_Vector2D &v)