HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SOP_PolyFrame.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 <SOP/SOP_GraphProxy.h>
8 
9 #include <OP/OP_Utils.h>
10 #include <PRM/PRM_Parm.h>
11 #include <UT/UT_IStream.h>
12 #include <UT/UT_NTStreamUtil.h>
13 #include <UT/UT_Ramp.h>
14 #include <UT/UT_SharedPtr.h>
15 #include <UT/UT_StringHolder.h>
16 #include <UT/UT_StringStream.h>
17 #include <UT/UT_VectorTypes.h>
18 #include <SYS/SYS_Types.h>
19 
20 using namespace UT::Literal;
21 
22 class DEP_MicroNode;
23 namespace SOP_PolyFrameEnums
24 {
25  enum class Entity
26  {
27  PRIMITIVE = 0,
28  POINT
29  };
30 }
31 
32 
34 {
35 public:
36  static int version() { return 1; }
37 
39  {
40  myGroup = ""_sh;
41  myEntity = 0;
42  myStyle = "edge2"_sh;
43  myAttribname = ""_sh;
44  myNon = true;
45  myN = "N"_sh;
46  myTangentuon = true;
47  myTangentu = "tangentu"_sh;
48  myTangentvon = false;
49  myTangentv = "tangentv"_sh;
50  mySignson = false;
51  mySigns = "signs"_sh;
52  myOrtho = false;
53  myLeftHanded = false;
54 
55  }
56 
57  explicit SOP_PolyFrameParms(const SOP_PolyFrameParms &) = default;
58 
59  ~SOP_PolyFrameParms() override {}
60 
61  bool operator==(const SOP_PolyFrameParms &src) const
62  {
63  if (myGroup != src.myGroup) return false;
64  if (myEntity != src.myEntity) return false;
65  if (myStyle != src.myStyle) return false;
66  if (myAttribname != src.myAttribname) return false;
67  if (myNon != src.myNon) return false;
68  if (myN != src.myN) return false;
69  if (myTangentuon != src.myTangentuon) return false;
70  if (myTangentu != src.myTangentu) return false;
71  if (myTangentvon != src.myTangentvon) return false;
72  if (myTangentv != src.myTangentv) return false;
73  if (mySignson != src.mySignson) return false;
74  if (mySigns != src.mySigns) return false;
75  if (myOrtho != src.myOrtho) return false;
76  if (myLeftHanded != src.myLeftHanded) return false;
77 
78  return true;
79  }
80  bool operator!=(const SOP_PolyFrameParms &src) const
81  {
82  return !operator==(src);
83  }
85 
86 
87 
88  void buildFromOp(const SOP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
89  {
90  myGroup = ""_sh;
91  if (true)
92  graph->evalOpParm(myGroup, nodeidx, "group", time, 0);
93  myEntity = 0;
94  if (true)
95  graph->evalOpParm(myEntity, nodeidx, "entity", time, 0);
96  myStyle = "edge2"_sh;
97  if (true)
98  graph->evalOpParm(myStyle, nodeidx, "style", time, 0);
99  myAttribname = ""_sh;
100  if (true && ( (!(((getStyle()!="attrib")&&(getStyle()!="texuv")&&(getStyle()!="mikkt")))) ) )
101  graph->evalOpParm(myAttribname, nodeidx, "attribname", time, 0);
102  myNon = true;
103  if (true && ( (!(((getStyle()=="mikkt")))) ) )
104  graph->evalOpParm(myNon, nodeidx, "Non", time, 0);
105  myN = "N"_sh;
106  if (true && ( (!(((getNon()==0))||((getStyle()=="mikkt")))) ) )
107  graph->evalOpParm(myN, nodeidx, "N", time, 0);
108  myTangentuon = true;
109  if (true)
110  graph->evalOpParm(myTangentuon, nodeidx, "tangentuon", time, 0);
111  myTangentu = "tangentu"_sh;
112  if (true && ( (!(((getTangentuon()==0)))) ) )
113  graph->evalOpParm(myTangentu, nodeidx, "tangentu", time, 0);
114  myTangentvon = false;
115  if (true)
116  graph->evalOpParm(myTangentvon, nodeidx, "tangentvon", time, 0);
117  myTangentv = "tangentv"_sh;
118  if (true && ( (!(((getTangentvon()==0)))) ) )
119  graph->evalOpParm(myTangentv, nodeidx, "tangentv", time, 0);
120  mySignson = false;
121  if (true && ( (!(((getStyle()!="mikkt")))) ) )
122  graph->evalOpParm(mySignson, nodeidx, "signson", time, 0);
123  mySigns = "signs"_sh;
124  if (true && ( (!(((getSignson()==0))||((getStyle()!="mikkt")))) ) )
125  graph->evalOpParm(mySigns, nodeidx, "signs", time, 0);
126  myOrtho = false;
127  if (true && ( (!(((getStyle()=="mikkt")))) ) )
128  graph->evalOpParm(myOrtho, nodeidx, "ortho", time, 0);
129  myLeftHanded = false;
130  if (true && ( (!(((getOrtho()==0))||((getStyle()=="mikkt")))) ) )
131  graph->evalOpParm(myLeftHanded, nodeidx, "lefthanded", time, 0);
132 
133  }
134 
135 
136  void loadFromOpSubclass(const LoadParms &loadparms) override
137  {
138  buildFromOp(loadparms.graph(), loadparms.nodeIdx(), loadparms.context().getTime(), loadparms.depnode());
139  }
140 
141 
142  void copyFrom(const SOP_NodeParms *src) override
143  {
144  *this = *((const SOP_PolyFrameParms *)src);
145  }
146 
147  template <typename T>
148  void
149  doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
150  {
151  if (idx.size() < 1)
152  return;
153  UT_ASSERT(idx.size() == instance.size()+1);
154  if (idx.size() != instance.size()+1)
155  return;
156  switch (idx[0])
157  {
158  case 0:
159  coerceValue(value, myGroup);
160  break;
161  case 1:
162  coerceValue(value, myEntity);
163  break;
164  case 2:
165  coerceValue(value, myStyle);
166  break;
167  case 3:
168  coerceValue(value, myAttribname);
169  break;
170  case 4:
171  coerceValue(value, myNon);
172  break;
173  case 5:
174  coerceValue(value, myN);
175  break;
176  case 6:
177  coerceValue(value, myTangentuon);
178  break;
179  case 7:
180  coerceValue(value, myTangentu);
181  break;
182  case 8:
183  coerceValue(value, myTangentvon);
184  break;
185  case 9:
186  coerceValue(value, myTangentv);
187  break;
188  case 10:
189  coerceValue(value, mySignson);
190  break;
191  case 11:
192  coerceValue(value, mySigns);
193  break;
194  case 12:
195  coerceValue(value, myOrtho);
196  break;
197  case 13:
198  coerceValue(value, myLeftHanded);
199  break;
200 
201  }
202  }
203 
204  void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
205  { doGetParmValue(idx, instance, value); }
206  void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
207  { doGetParmValue(idx, instance, value); }
208  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
209  { doGetParmValue(idx, instance, value); }
210  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
211  { doGetParmValue(idx, instance, value); }
212  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
213  { doGetParmValue(idx, instance, value); }
214  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
215  { doGetParmValue(idx, instance, value); }
216  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
217  { doGetParmValue(idx, instance, value); }
218  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
219  { doGetParmValue(idx, instance, value); }
220  void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
221  { doGetParmValue(idx, instance, value); }
222  void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr<UT_Ramp> &value) const override
223  { doGetParmValue(idx, instance, value); }
224  void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
225  { doGetParmValue(idx, instance, value); }
226 
227  template <typename T>
228  void
229  doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
230  {
231  if (idx.size() < 1)
232  return;
233  UT_ASSERT(idx.size() == instance.size()+1);
234  if (idx.size() != instance.size()+1)
235  return;
236  switch (idx[0])
237  {
238  case 0:
239  coerceValue(myGroup, value);
240  break;
241  case 1:
242  coerceValue(myEntity, value);
243  break;
244  case 2:
245  coerceValue(myStyle, value);
246  break;
247  case 3:
248  coerceValue(myAttribname, value);
249  break;
250  case 4:
251  coerceValue(myNon, value);
252  break;
253  case 5:
254  coerceValue(myN, value);
255  break;
256  case 6:
257  coerceValue(myTangentuon, value);
258  break;
259  case 7:
260  coerceValue(myTangentu, value);
261  break;
262  case 8:
263  coerceValue(myTangentvon, value);
264  break;
265  case 9:
266  coerceValue(myTangentv, value);
267  break;
268  case 10:
269  coerceValue(mySignson, value);
270  break;
271  case 11:
272  coerceValue(mySigns, value);
273  break;
274  case 12:
275  coerceValue(myOrtho, value);
276  break;
277  case 13:
278  coerceValue(myLeftHanded, value);
279  break;
280 
281  }
282  }
283 
284  void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
285  { doSetParmValue(idx, instance, value); }
286  void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
287  { doSetParmValue(idx, instance, value); }
288  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
289  { doSetParmValue(idx, instance, value); }
290  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
291  { doSetParmValue(idx, instance, value); }
292  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
293  { doSetParmValue(idx, instance, value); }
294  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
295  { doSetParmValue(idx, instance, value); }
296  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
297  { doSetParmValue(idx, instance, value); }
298  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
299  { doSetParmValue(idx, instance, value); }
300  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
301  { doSetParmValue(idx, instance, value); }
302  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr<UT_Ramp> &value) override
303  { doSetParmValue(idx, instance, value); }
304  void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
305  { doSetParmValue(idx, instance, value); }
306 
307  exint getNestNumParms(TempIndex idx) const override
308  {
309  if (idx.size() == 0)
310  return 14;
311  switch (idx[0])
312  {
313 
314  }
315  // Invalid
316  return 0;
317  }
318 
319  const char *getNestParmName(TempIndex fieldnum) const override
320  {
321  if (fieldnum.size() < 1)
322  return 0;
323  switch (fieldnum[0])
324  {
325  case 0:
326  return "group";
327  case 1:
328  return "entity";
329  case 2:
330  return "style";
331  case 3:
332  return "attribname";
333  case 4:
334  return "Non";
335  case 5:
336  return "N";
337  case 6:
338  return "tangentuon";
339  case 7:
340  return "tangentu";
341  case 8:
342  return "tangentvon";
343  case 9:
344  return "tangentv";
345  case 10:
346  return "signson";
347  case 11:
348  return "signs";
349  case 12:
350  return "ortho";
351  case 13:
352  return "lefthanded";
353 
354  }
355  return 0;
356  }
357 
358  ParmType getNestParmType(TempIndex fieldnum) const override
359  {
360  if (fieldnum.size() < 1)
361  return PARM_UNSUPPORTED;
362  switch (fieldnum[0])
363  {
364  case 0:
365  return PARM_STRING;
366  case 1:
367  return PARM_INTEGER;
368  case 2:
369  return PARM_STRING;
370  case 3:
371  return PARM_STRING;
372  case 4:
373  return PARM_INTEGER;
374  case 5:
375  return PARM_STRING;
376  case 6:
377  return PARM_INTEGER;
378  case 7:
379  return PARM_STRING;
380  case 8:
381  return PARM_INTEGER;
382  case 9:
383  return PARM_STRING;
384  case 10:
385  return PARM_INTEGER;
386  case 11:
387  return PARM_STRING;
388  case 12:
389  return PARM_INTEGER;
390  case 13:
391  return PARM_INTEGER;
392 
393  }
394  return PARM_UNSUPPORTED;
395  }
396 
397  // Boiler plate to load individual types.
398  static void loadData(UT_IStream &is, int64 &v)
399  { is.bread(&v, 1); }
400  static void loadData(UT_IStream &is, bool &v)
401  { int64 iv; is.bread(&iv, 1); v = iv; }
402  static void loadData(UT_IStream &is, fpreal64 &v)
403  { is.bread<fpreal64>(&v, 1); }
404  static void loadData(UT_IStream &is, UT_Vector2D &v)
405  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1); }
406  static void loadData(UT_IStream &is, UT_Vector3D &v)
407  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
408  is.bread<fpreal64>(&v.z(), 1); }
409  static void loadData(UT_IStream &is, UT_Vector4D &v)
410  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
411  is.bread<fpreal64>(&v.z(), 1); is.bread<fpreal64>(&v.w(), 1); }
412  static void loadData(UT_IStream &is, UT_Matrix2D &v)
413  { for (int r = 0; r < 2; r++) for (int c = 0; c < 2; c++) is.bread<fpreal64>(&v(r, c), 1); }
414  static void loadData(UT_IStream &is, UT_Matrix3D &v)
415  { for (int r = 0; r < 3; r++) for (int c = 0; c < 3; c++) is.bread<fpreal64>(&v(r, c), 1); }
416  static void loadData(UT_IStream &is, UT_Matrix4D &v)
417  { for (int r = 0; r < 4; r++) for (int c = 0; c < 4; c++) is.bread<fpreal64>(&v(r, c), 1); }
418  static void loadData(UT_IStream &is, UT_Vector2I &v)
419  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1); }
420  static void loadData(UT_IStream &is, UT_Vector3I &v)
421  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
422  is.bread<int64>(&v.z(), 1); }
423  static void loadData(UT_IStream &is, UT_Vector4I &v)
424  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
425  is.bread<int64>(&v.z(), 1); is.bread<int64>(&v.w(), 1); }
427  { is.bread(v); }
429  { UT_StringHolder rampdata;
430  loadData(is, rampdata);
431  if (rampdata.isstring())
432  {
433  v.reset(new UT_Ramp());
434  UT_IStream istr((const char *) rampdata, rampdata.length(), UT_ISTREAM_ASCII);
435  v->load(istr);
436  }
437  else v.reset();
438  }
441  loadData(is, data);
442  if (data.isstring())
443  {
444  // Find the data type.
445  const char *colon = UT_StringWrap(data).findChar(':');
446  if (colon)
447  {
448  int typelen = colon - data.buffer();
450  type.strncpy(data.buffer(), typelen);
451  UT_IStream istr(((const char *) data) + typelen + 1, data.length() - (typelen + 1), UT_ISTREAM_BINARY);
452 
453  v = PRM_DataFactory::parseBinary(type.buffer(), istr);
454  }
455  }
456  else v.reset();
457  }
458 
459  static void saveData(std::ostream &os, int64 v)
460  { UTwrite(os, &v); }
461  static void saveData(std::ostream &os, bool v)
462  { int64 iv = v; UTwrite(os, &iv); }
463  static void saveData(std::ostream &os, fpreal64 v)
464  { UTwrite<fpreal64>(os, &v); }
465  static void saveData(std::ostream &os, UT_Vector2D v)
466  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y()); }
467  static void saveData(std::ostream &os, UT_Vector3D v)
468  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
469  UTwrite<fpreal64>(os, &v.z()); }
470  static void saveData(std::ostream &os, UT_Vector4D v)
471  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
472  UTwrite<fpreal64>(os, &v.z()); UTwrite<fpreal64>(os, &v.w()); }
473  static void saveData(std::ostream &os, UT_Matrix2D v)
475  static void saveData(std::ostream &os, UT_Matrix3D v)
477  static void saveData(std::ostream &os, UT_Matrix4D v)
479  static void saveData(std::ostream &os, UT_StringHolder s)
480  { UT_StringWrap(s).saveBinary(os); }
481  static void saveData(std::ostream &os, UT_SharedPtr<UT_Ramp> s)
483  UT_OStringStream ostr;
484  if (s) s->save(ostr);
485  result = ostr.str();
486  saveData(os, result);
487  }
488  static void saveData(std::ostream &os, PRM_DataItemHandle s)
490  UT_OStringStream ostr;
491  if (s)
492  {
493  ostr << s->getDataTypeToken();
494  ostr << ":";
495  s->saveBinary(ostr);
496  }
497  result = ostr.str();
498  saveData(os, result);
499  }
500 
501 
502  void save(std::ostream &os) const
503  {
504  int32 v = version();
505  UTwrite(os, &v);
506  saveData(os, myGroup);
507  saveData(os, myEntity);
508  saveData(os, myStyle);
509  saveData(os, myAttribname);
510  saveData(os, myNon);
511  saveData(os, myN);
512  saveData(os, myTangentuon);
513  saveData(os, myTangentu);
514  saveData(os, myTangentvon);
515  saveData(os, myTangentv);
516  saveData(os, mySignson);
517  saveData(os, mySigns);
518  saveData(os, myOrtho);
519  saveData(os, myLeftHanded);
520 
521  }
522 
523  bool load(UT_IStream &is)
524  {
525  int32 v;
526  is.bread(&v, 1);
527  if (version() != v)
528  {
529  // Fail incompatible versions
530  return false;
531  }
532  loadData(is, myGroup);
533  loadData(is, myEntity);
534  loadData(is, myStyle);
535  loadData(is, myAttribname);
536  loadData(is, myNon);
537  loadData(is, myN);
538  loadData(is, myTangentuon);
539  loadData(is, myTangentu);
540  loadData(is, myTangentvon);
541  loadData(is, myTangentv);
542  loadData(is, mySignson);
543  loadData(is, mySigns);
544  loadData(is, myOrtho);
545  loadData(is, myLeftHanded);
546 
547  return true;
548  }
549 
550  const UT_StringHolder & getGroup() const { return myGroup; }
551  void setGroup(const UT_StringHolder & val) { myGroup = val; }
553  {
554  SOP_Node *thissop = cookparms.getNode();
555  if (!thissop) return getGroup();
557  OP_Utils::evalOpParm(result, thissop, "group", cookparms.getCookTime(), 0);
558  return result;
559  }
560  Entity getEntity() const { return Entity(myEntity); }
561  void setEntity(Entity val) { myEntity = int64(val); }
562  Entity opEntity(const SOP_NodeVerb::CookParms &cookparms) const
563  {
564  SOP_Node *thissop = cookparms.getNode();
565  if (!thissop) return getEntity();
566  int64 result;
567  OP_Utils::evalOpParm(result, thissop, "entity", cookparms.getCookTime(), 0);
568  return Entity(result);
569  }
570  const UT_StringHolder & getStyle() const { return myStyle; }
571  void setStyle(const UT_StringHolder & val) { myStyle = val; }
573  {
574  SOP_Node *thissop = cookparms.getNode();
575  if (!thissop) return getStyle();
577  OP_Utils::evalOpParm(result, thissop, "style", cookparms.getCookTime(), 0);
578  return result;
579  }
580  const UT_StringHolder & getAttribname() const { return myAttribname; }
581  void setAttribname(const UT_StringHolder & val) { myAttribname = val; }
583  {
584  SOP_Node *thissop = cookparms.getNode();
585  if (!thissop) return getAttribname();
587  OP_Utils::evalOpParm(result, thissop, "attribname", cookparms.getCookTime(), 0);
588  return result;
589  }
590  bool getNon() const { return myNon; }
591  void setNon(bool val) { myNon = val; }
592  bool opNon(const SOP_NodeVerb::CookParms &cookparms) const
593  {
594  SOP_Node *thissop = cookparms.getNode();
595  if (!thissop) return getNon();
596  bool result;
597  OP_Utils::evalOpParm(result, thissop, "Non", cookparms.getCookTime(), 0);
598  return result;
599  }
600  const UT_StringHolder & getN() const { return myN; }
601  void setN(const UT_StringHolder & val) { myN = val; }
603  {
604  SOP_Node *thissop = cookparms.getNode();
605  if (!thissop) return getN();
607  OP_Utils::evalOpParm(result, thissop, "N", cookparms.getCookTime(), 0);
608  return result;
609  }
610  bool getTangentuon() const { return myTangentuon; }
611  void setTangentuon(bool val) { myTangentuon = val; }
612  bool opTangentuon(const SOP_NodeVerb::CookParms &cookparms) const
613  {
614  SOP_Node *thissop = cookparms.getNode();
615  if (!thissop) return getTangentuon();
616  bool result;
617  OP_Utils::evalOpParm(result, thissop, "tangentuon", cookparms.getCookTime(), 0);
618  return result;
619  }
620  const UT_StringHolder & getTangentu() const { return myTangentu; }
621  void setTangentu(const UT_StringHolder & val) { myTangentu = val; }
623  {
624  SOP_Node *thissop = cookparms.getNode();
625  if (!thissop) return getTangentu();
627  OP_Utils::evalOpParm(result, thissop, "tangentu", cookparms.getCookTime(), 0);
628  return result;
629  }
630  bool getTangentvon() const { return myTangentvon; }
631  void setTangentvon(bool val) { myTangentvon = val; }
632  bool opTangentvon(const SOP_NodeVerb::CookParms &cookparms) const
633  {
634  SOP_Node *thissop = cookparms.getNode();
635  if (!thissop) return getTangentvon();
636  bool result;
637  OP_Utils::evalOpParm(result, thissop, "tangentvon", cookparms.getCookTime(), 0);
638  return result;
639  }
640  const UT_StringHolder & getTangentv() const { return myTangentv; }
641  void setTangentv(const UT_StringHolder & val) { myTangentv = val; }
643  {
644  SOP_Node *thissop = cookparms.getNode();
645  if (!thissop) return getTangentv();
647  OP_Utils::evalOpParm(result, thissop, "tangentv", cookparms.getCookTime(), 0);
648  return result;
649  }
650  bool getSignson() const { return mySignson; }
651  void setSignson(bool val) { mySignson = val; }
652  bool opSignson(const SOP_NodeVerb::CookParms &cookparms) const
653  {
654  SOP_Node *thissop = cookparms.getNode();
655  if (!thissop) return getSignson();
656  bool result;
657  OP_Utils::evalOpParm(result, thissop, "signson", cookparms.getCookTime(), 0);
658  return result;
659  }
660  const UT_StringHolder & getSigns() const { return mySigns; }
661  void setSigns(const UT_StringHolder & val) { mySigns = val; }
663  {
664  SOP_Node *thissop = cookparms.getNode();
665  if (!thissop) return getSigns();
667  OP_Utils::evalOpParm(result, thissop, "signs", cookparms.getCookTime(), 0);
668  return result;
669  }
670  bool getOrtho() const { return myOrtho; }
671  void setOrtho(bool val) { myOrtho = val; }
672  bool opOrtho(const SOP_NodeVerb::CookParms &cookparms) const
673  {
674  SOP_Node *thissop = cookparms.getNode();
675  if (!thissop) return getOrtho();
676  bool result;
677  OP_Utils::evalOpParm(result, thissop, "ortho", cookparms.getCookTime(), 0);
678  return result;
679  }
680  bool getLeftHanded() const { return myLeftHanded; }
681  void setLeftHanded(bool val) { myLeftHanded = val; }
682  bool opLeftHanded(const SOP_NodeVerb::CookParms &cookparms) const
683  {
684  SOP_Node *thissop = cookparms.getNode();
685  if (!thissop) return getLeftHanded();
686  bool result;
687  OP_Utils::evalOpParm(result, thissop, "lefthanded", cookparms.getCookTime(), 0);
688  return result;
689  }
690 
691 private:
692  UT_StringHolder myGroup;
693  int64 myEntity;
694  UT_StringHolder myStyle;
695  UT_StringHolder myAttribname;
696  bool myNon;
697  UT_StringHolder myN;
698  bool myTangentuon;
699  UT_StringHolder myTangentu;
700  bool myTangentvon;
701  UT_StringHolder myTangentv;
702  bool mySignson;
703  UT_StringHolder mySigns;
704  bool myOrtho;
705  bool myLeftHanded;
706 
707 };
UT_StringHolder opTangentv(const SOP_NodeVerb::CookParms &cookparms) const
GLdouble s
Definition: glew.h:1390
const UT_StringHolder & getSigns() const
void doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
static void loadData(UT_IStream &is, bool &v)
bool operator==(const SOP_PolyFrameParms &src) const
void copyFrom(const SOP_NodeParms *src) override
exint nodeIdx() const
Definition: SOP_NodeVerb.h:114
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
void setTangentuon(bool val)
GLenum src
Definition: glew.h:2410
int int32
Definition: SYS_Types.h:39
SOP_Node * getNode() const
Definition: SOP_NodeVerb.h:640
static void saveData(std::ostream &os, UT_StringHolder s)
static void saveData(std::ostream &os, int64 v)
static void saveData(std::ostream &os, UT_Matrix4D v)
static void saveData(std::ostream &os, UT_Vector4D v)
bool operator!=(const SOP_PolyFrameParms &src) const
void setN(const UT_StringHolder &val)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
exint bread(int32 *buffer, exint asize=1)
GT_API const UT_StringHolder time
void setSigns(const UT_StringHolder &val)
fpreal getTime() const
Definition: OP_Context.h:60
GLuint const GLfloat * val
Definition: glew.h:2794
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
void setGroup(const UT_StringHolder &val)
void loadFromOpSubclass(const LoadParms &loadparms) override
const UT_StringHolder & getN() const
static void saveData(std::ostream &os, PRM_DataItemHandle s)
void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
int64 exint
Definition: SYS_Types.h:125
SYS_FORCE_INLINE const char * buffer() const
const SOP_GraphProxy * graph() const
Definition: SOP_NodeVerb.h:113
static void loadData(UT_IStream &is, UT_Matrix3D &v)
An output stream object that owns its own string buffer storage.
static void loadData(UT_IStream &is, UT_Vector4I &v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
const GLdouble * v
Definition: glew.h:1391
static void saveData(std::ostream &os, UT_Matrix2D v)
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
void setAttribname(const UT_StringHolder &val)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
void buildFromOp(const SOP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
UT_StringHolder opAttribname(const SOP_NodeVerb::CookParms &cookparms) const
static PRM_DataItemHandle parseBinary(const char *type, UT_IStream &is)
const UT_WorkBuffer & str()
Returns a read-only reference to the underlying UT_WorkBuffer.
const char * getNestParmName(TempIndex fieldnum) const override
UT_StringHolder opTangentu(const SOP_NodeVerb::CookParms &cookparms) const
UT_StringHolder opGroup(const SOP_NodeVerb::CookParms &cookparms) const
bool getLeftHanded() const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
double fpreal64
Definition: SYS_Types.h:201
bool opTangentvon(const SOP_NodeVerb::CookParms &cookparms) const
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
Definition: Dimensions.h:137
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
bool opNon(const SOP_NodeVerb::CookParms &cookparms) const
bool getTangentvon() const
void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
SYS_FORCE_INLINE T & y()
Definition: UT_Vector3.h:513
void setTangentvon(bool val)
void setTangentv(const UT_StringHolder &val)
void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
static void loadData(UT_IStream &is, UT_Vector2I &v)
exint length() const
void setTangentu(const UT_StringHolder &val)
SYS_FORCE_INLINE const char * buffer() const
static void saveData(std::ostream &os, UT_Vector3D v)
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
Definition: UT_SharedPtr.h:28
static void loadData(UT_IStream &is, UT_Vector3D &v)
GLint GLenum GLsizei GLint GLsizei const void * data
Definition: glew.h:1379
void setStyle(const UT_StringHolder &val)
SYS_FORCE_INLINE T & z()
Definition: UT_Vector3.h:515
~SOP_PolyFrameParms() override
const GLfloat * c
Definition: glew.h:16296
static void loadData(UT_IStream &is, int64 &v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
long long int64
Definition: SYS_Types.h:116
static void loadData(UT_IStream &is, fpreal64 &v)
bool opLeftHanded(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, UT_Vector3I &v)
Entity opEntity(const SOP_NodeVerb::CookParms &cookparms) const
void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
bool opOrtho(const SOP_NodeVerb::CookParms &cookparms) const
UT_StringHolder opStyle(const SOP_NodeVerb::CookParms &cookparms) const
const UT_StringHolder & getTangentv() const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr< UT_Ramp > &value) override
static void saveData(std::ostream &os, UT_Vector2D v)
exint getNestNumParms(TempIndex idx) const override
void saveBinary(std::ostream &os) const
Save string to binary stream.
Definition: UT_String.h:294
GT_API const UT_StringHolder version
DEP_MicroNode * depnode() const
Definition: SOP_NodeVerb.h:121
static void loadData(UT_IStream &is, UT_Vector4D &v)
void doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
static void saveData(std::ostream &os, UT_Matrix3D v)
const UT_StringHolder & getGroup() const
UT_StringHolder opN(const SOP_NodeVerb::CookParms &cookparms) const
void save(std::ostream &os) const
const UT_StringHolder & getTangentu() const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr< UT_Ramp > &value) const override
fpreal64 fpreal
Definition: SYS_Types.h:277
void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
static void saveData(std::ostream &os, fpreal64 v)
Utility class for containing a color ramp.
Definition: UT_Ramp.h:84
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
GLdouble GLdouble GLdouble r
Definition: glew.h:1406
static void loadData(UT_IStream &is, UT_StringHolder &v)
#define SOP_API
Definition: SOP_API.h:10
bool getTangentuon() const
bool load(UT_IStream &is)
virtual void evalOpParm(int64 &v, NodeIdx node, const char *parmname, fpreal time, DEP_MicroNode *depnode) const =0
Entity getEntity() const
SYS_FORCE_INLINE T & x()
Definition: UT_Vector3.h:511
fpreal getCookTime() const
Definition: SOP_NodeVerb.h:654
GLuint64EXT * result
Definition: glew.h:14007
static void loadData(UT_IStream &is, UT_Matrix4D &v)
const char * findChar(int c) const
Definition: UT_String.h:1367
#define UT_ASSERT(ZZ)
Definition: UT_Assert.h:135
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
const UT_StringHolder & getAttribname() const
const UT_StringHolder & getStyle() const
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
bool opTangentuon(const SOP_NodeVerb::CookParms &cookparms) const
void setSignson(bool val)
void setEntity(Entity val)
void setLeftHanded(bool val)
UT_StringHolder opSigns(const SOP_NodeVerb::CookParms &cookparms) const
ParmType getNestParmType(TempIndex fieldnum) const override
GLsizei const GLfloat * value
Definition: glew.h:1849
static void loadData(UT_IStream &is, UT_Vector2D &v)
const OP_Context & context() const
Definition: SOP_NodeVerb.h:119
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
Definition: PRM_Parm.h:89
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
static void loadData(UT_IStream &is, UT_Matrix2D &v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
SYS_FORCE_INLINE bool isstring() const
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
type
Definition: core.h:528
bool opSignson(const SOP_NodeVerb::CookParms &cookparms) const
static void saveData(std::ostream &os, bool v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override