HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SOP_InvokeGraph.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 namespace SOP_InvokeGraphEnums
24 {
25  enum class Method
26  {
27  COMPILE = 0,
28  NETWORK
29  };
30  enum class OutputType
31  {
32  LAST = 0,
33  FIRST,
34  GROUP,
35  PATH
36  };
37  enum class Unload
38  {
39  NEVER = 0,
40  FLAG,
41  ALWAYS
42  };
43 }
44 
45 
47 {
48 public:
49  static int version() { return 1; }
50  struct Inputs
51  {
53 
54 
56  {
57  name = ""_UTsh;
58 
59  }
60 
61  bool operator==(const Inputs &src) const
62  {
63  if (name != src.name) return false;
64 
65  return true;
66  }
67  bool operator!=(const Inputs &src) const
68  {
69  return !operator==(src);
70  }
71 
72  };
73 
75  {
77 
78  buf.strcat("[ ");
79  for (int i = 0; i < list.entries(); i++)
80  {
81  if (i)
82  buf.strcat(", ");
83  buf.strcat("( ");
84  buf.append("");
85  { UT_String tmp; tmp = UT_StringWrap(list(i).name).makeQuotedString('"'); buf.strcat(tmp); }
86 
87  buf.strcat(" )");
88  }
89  buf.strcat(" ]");
90 
92  return result;
93  }
94 
96  {
97  myMethod = 0;
98  myOutputType = 0;
99  myOutputGroup = ""_UTsh;
100  myOutput = ""_UTsh;
101  myInputs.setSize(4);
102  myInputGroup = ""_UTsh;
103  myUnload = 2;
104 
105  }
106 
107  explicit SOP_InvokeGraphParms(const SOP_InvokeGraphParms &) = default;
109  SOP_InvokeGraphParms(SOP_InvokeGraphParms &&) noexcept = default;
110  SOP_InvokeGraphParms &operator=(SOP_InvokeGraphParms &&) noexcept = default;
111 
112  ~SOP_InvokeGraphParms() override {}
113 
115  {
116  if (myMethod != src.myMethod) return false;
117  if (myOutputType != src.myOutputType) return false;
118  if (myOutputGroup != src.myOutputGroup) return false;
119  if (myOutput != src.myOutput) return false;
120  if (myInputs != src.myInputs) return false;
121  if (myInputGroup != src.myInputGroup) return false;
122  if (myUnload != src.myUnload) return false;
123 
124  return true;
125  }
127  {
128  return !operator==(src);
129  }
133 
134 
135 
136  void buildFromOp(const OP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
137  {
138  myMethod = 0;
139  if (true)
140  graph->evalOpParm(myMethod, nodeidx, "method", time, 0);
141  myOutputType = 0;
142  if (true)
143  graph->evalOpParm(myOutputType, nodeidx, "outputtype", time, 0);
144  myOutputGroup = ""_UTsh;
145  if (true && ( (true&&!(((int64(getOutputType())!=2)))) ) )
146  graph->evalOpParm(myOutputGroup, nodeidx, "outputgroup", time, 0);
147  myOutput = ""_UTsh;
148  if (true && ( (true&&!(((int64(getOutputType())!=3)))) ) )
149  graph->evalOpParm(myOutput, nodeidx, "output", time, 0);
150  if (true && ( (!(((int64(getMethod())!=0)))) ) )
151  {
152  int64 length = 0;
153  graph->evalOpParm(length, nodeidx, "inputs", time, 0);
154  if (length < 0) length = 0;
155  myInputs.setSize(length);
156  for (exint i = 0; i < length; i++)
157  {
158  int parmidx[1];
159  int offsets[1];
160  parmidx[0] = i+0;
161  offsets[0] = 0;
162  auto && _curentry = myInputs(i);
163  (void) _curentry;
164  _curentry.name = ""_UTsh;
165  if (true && ( (!(((int64(getMethod())!=0)))) ) && ( (true&&!(((int64(getMethod())!=0)))) ) )
166  graph->evalOpParmInst(_curentry.name, nodeidx, "name#", parmidx, offsets, time, 0, 2-1);
167 
168  }
169  }
170  else
171  myInputs.clear();
172  myInputGroup = ""_UTsh;
173  if (true && ( (true&&!(((int64(getMethod())!=1)))) ) )
174  graph->evalOpParm(myInputGroup, nodeidx, "inputgroup", time, 0);
175  myUnload = 2;
176  if (true)
177  graph->evalOpParm(myUnload, nodeidx, "unload", time, 0);
178 
179  }
180 
181 
182  void loadFromOpSubclass(const LoadParms &loadparms) override
183  {
184  buildFromOp(loadparms.graph(), loadparms.nodeIdx(), loadparms.context().getTime(), loadparms.depnode());
185  }
186 
187 
188  void copyFrom(const OP_NodeParms *src) override
189  {
190  *this = *((const SOP_InvokeGraphParms *)src);
191  }
192 
193  template <typename T>
194  void
195  doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
196  {
197  if (idx.size() < 1)
198  return;
199  UT_ASSERT(idx.size() == instance.size()+1);
200  if (idx.size() != instance.size()+1)
201  return;
202  switch (idx[0])
203  {
204  case 0:
205  coerceValue(value, myMethod);
206  break;
207  case 1:
208  coerceValue(value, myOutputType);
209  break;
210  case 2:
211  coerceValue(value, myOutputGroup);
212  break;
213  case 3:
214  coerceValue(value, myOutput);
215  break;
216  case 4:
217  if (idx.size() == 1)
218  coerceValue(value, myInputs.entries());
219  else if (instance[0] < myInputs.entries())
220  {
221  auto && _data = myInputs(instance[0]);
222  switch (idx[1])
223  {
224  case 0:
225  coerceValue(value, _data.name);
226  break;
227 
228  }
229  }
230  break;
231  case 5:
232  coerceValue(value, myInputGroup);
233  break;
234  case 6:
235  coerceValue(value, myUnload);
236  break;
237 
238  }
239  }
240 
241  bool isParmColorRamp(exint idx) const override
242  {
243  switch (idx)
244  {
245 
246  }
247  return false;
248  }
249 
250  void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
251  { doGetParmValue(idx, instance, value); }
252  void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
253  { doGetParmValue(idx, instance, value); }
254  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
255  { doGetParmValue(idx, instance, value); }
256  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
257  { doGetParmValue(idx, instance, value); }
258  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
259  { doGetParmValue(idx, instance, value); }
260  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
261  { doGetParmValue(idx, instance, value); }
262  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
263  { doGetParmValue(idx, instance, value); }
264  void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
265  { doGetParmValue(idx, instance, value); }
266  void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
267  { doGetParmValue(idx, instance, value); }
268  void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr<UT_Ramp> &value) const override
269  { doGetParmValue(idx, instance, value); }
270  void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
271  { doGetParmValue(idx, instance, value); }
272 
273  template <typename T>
274  void
275  doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
276  {
277  if (idx.size() < 1)
278  return;
279  UT_ASSERT(idx.size() == instance.size()+1);
280  if (idx.size() != instance.size()+1)
281  return;
282  switch (idx[0])
283  {
284  case 0:
285  coerceValue(myMethod, clampMinValue(0, clampMaxValue(1, value ) ));
286  break;
287  case 1:
288  coerceValue(myOutputType, clampMinValue(0, clampMaxValue(3, value ) ));
289  break;
290  case 2:
291  coerceValue(myOutputGroup, ( ( value ) ));
292  break;
293  case 3:
294  coerceValue(myOutput, ( ( value ) ));
295  break;
296  case 4:
297  if (idx.size() == 1)
298  {
299  exint newsize;
300  coerceValue(newsize, value);
301  if (newsize < 0) newsize = 0;
302  myInputs.setSize(newsize);
303  }
304  else
305  {
306  if (instance[0] < 0)
307  return;
308  myInputs.setSizeIfNeeded(instance[0]+1);
309  auto && _data = myInputs(instance[0]);
310  switch (idx[1])
311  {
312  case 0:
313  coerceValue(_data.name, value);
314  break;
315 
316  }
317  }
318  break;
319  case 5:
320  coerceValue(myInputGroup, ( ( value ) ));
321  break;
322  case 6:
323  coerceValue(myUnload, clampMinValue(0, clampMaxValue(2, value ) ));
324  break;
325 
326  }
327  }
328 
329  void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
330  { doSetParmValue(idx, instance, value); }
331  void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
332  { doSetParmValue(idx, instance, value); }
333  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
334  { doSetParmValue(idx, instance, value); }
335  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
336  { doSetParmValue(idx, instance, value); }
337  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
338  { doSetParmValue(idx, instance, value); }
339  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
340  { doSetParmValue(idx, instance, value); }
341  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
342  { doSetParmValue(idx, instance, value); }
343  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
344  { doSetParmValue(idx, instance, value); }
345  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
346  { doSetParmValue(idx, instance, value); }
347  void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr<UT_Ramp> &value) override
348  { doSetParmValue(idx, instance, value); }
349  void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
350  { doSetParmValue(idx, instance, value); }
351 
352  exint getNestNumParms(TempIndex idx) const override
353  {
354  if (idx.size() == 0)
355  return 7;
356  switch (idx[0])
357  {
358  case 4:
359  return 1;
360 
361  }
362  // Invalid
363  return 0;
364  }
365 
366  const char *getNestParmName(TempIndex fieldnum) const override
367  {
368  if (fieldnum.size() < 1)
369  return 0;
370  switch (fieldnum[0])
371  {
372  case 0:
373  return "method";
374  case 1:
375  return "outputtype";
376  case 2:
377  return "outputgroup";
378  case 3:
379  return "output";
380  case 4:
381  if (fieldnum.size() == 1)
382  return "inputs";
383  switch (fieldnum[1])
384  {
385  case 0:
386  return "name#";
387 
388  }
389  return 0;
390  case 5:
391  return "inputgroup";
392  case 6:
393  return "unload";
394 
395  }
396  return 0;
397  }
398 
399  ParmType getNestParmType(TempIndex fieldnum) const override
400  {
401  if (fieldnum.size() < 1)
402  return PARM_UNSUPPORTED;
403  switch (fieldnum[0])
404  {
405  case 0:
406  return PARM_INTEGER;
407  case 1:
408  return PARM_INTEGER;
409  case 2:
410  return PARM_STRING;
411  case 3:
412  return PARM_STRING;
413  case 4:
414  if (fieldnum.size() == 1)
415  return PARM_MULTIPARM;
416  switch (fieldnum[1])
417  {
418  case 0:
419  return PARM_STRING;
420 
421  }
422  return PARM_UNSUPPORTED;
423  case 5:
424  return PARM_STRING;
425  case 6:
426  return PARM_INTEGER;
427 
428  }
429  return PARM_UNSUPPORTED;
430  }
431 
432  // Boiler plate to load individual types.
433  static void loadData(UT_IStream &is, int64 &v)
434  { is.bread(&v, 1); }
435  static void loadData(UT_IStream &is, bool &v)
436  { int64 iv; is.bread(&iv, 1); v = iv; }
437  static void loadData(UT_IStream &is, fpreal64 &v)
438  { is.bread<fpreal64>(&v, 1); }
439  static void loadData(UT_IStream &is, UT_Vector2D &v)
440  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1); }
441  static void loadData(UT_IStream &is, UT_Vector3D &v)
442  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
443  is.bread<fpreal64>(&v.z(), 1); }
444  static void loadData(UT_IStream &is, UT_Vector4D &v)
445  { is.bread<fpreal64>(&v.x(), 1); is.bread<fpreal64>(&v.y(), 1);
446  is.bread<fpreal64>(&v.z(), 1); is.bread<fpreal64>(&v.w(), 1); }
447  static void loadData(UT_IStream &is, UT_Matrix2D &v)
448  { for (int r = 0; r < 2; r++) for (int c = 0; c < 2; c++) is.bread<fpreal64>(&v(r, c), 1); }
449  static void loadData(UT_IStream &is, UT_Matrix3D &v)
450  { for (int r = 0; r < 3; r++) for (int c = 0; c < 3; c++) is.bread<fpreal64>(&v(r, c), 1); }
451  static void loadData(UT_IStream &is, UT_Matrix4D &v)
452  { for (int r = 0; r < 4; r++) for (int c = 0; c < 4; c++) is.bread<fpreal64>(&v(r, c), 1); }
453  static void loadData(UT_IStream &is, UT_Vector2I &v)
454  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1); }
455  static void loadData(UT_IStream &is, UT_Vector3I &v)
456  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
457  is.bread<int64>(&v.z(), 1); }
458  static void loadData(UT_IStream &is, UT_Vector4I &v)
459  { is.bread<int64>(&v.x(), 1); is.bread<int64>(&v.y(), 1);
460  is.bread<int64>(&v.z(), 1); is.bread<int64>(&v.w(), 1); }
462  { is.bread(v); }
464  { UT_StringHolder rampdata;
465  loadData(is, rampdata);
466  if (rampdata.isstring())
467  {
468  v.reset(new UT_Ramp());
469  UT_IStream istr((const char *) rampdata, rampdata.length(), UT_ISTREAM_ASCII);
470  v->load(istr);
471  }
472  else v.reset();
473  }
476  loadData(is, data);
477  if (data.isstring())
478  {
479  // Find the data type.
480  const char *colon = UT_StringWrap(data).findChar(':');
481  if (colon)
482  {
483  int typelen = colon - data.buffer();
485  type.strncpy(data.buffer(), typelen);
486  UT_IStream istr(((const char *) data) + typelen + 1, data.length() - (typelen + 1), UT_ISTREAM_BINARY);
487 
488  v = PRM_DataFactory::parseBinary(type.buffer(), istr);
489  }
490  }
491  else v.reset();
492  }
493 
494  static void saveData(std::ostream &os, int64 v)
495  { UTwrite(os, &v); }
496  static void saveData(std::ostream &os, bool v)
497  { int64 iv = v; UTwrite(os, &iv); }
498  static void saveData(std::ostream &os, fpreal64 v)
499  { UTwrite<fpreal64>(os, &v); }
500  static void saveData(std::ostream &os, UT_Vector2D v)
501  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y()); }
502  static void saveData(std::ostream &os, UT_Vector3D v)
503  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
504  UTwrite<fpreal64>(os, &v.z()); }
505  static void saveData(std::ostream &os, UT_Vector4D v)
506  { UTwrite<fpreal64>(os, &v.x()); UTwrite<fpreal64>(os, &v.y());
507  UTwrite<fpreal64>(os, &v.z()); UTwrite<fpreal64>(os, &v.w()); }
508  static void saveData(std::ostream &os, UT_Matrix2D v)
510  static void saveData(std::ostream &os, UT_Matrix3D v)
512  static void saveData(std::ostream &os, UT_Matrix4D v)
514  static void saveData(std::ostream &os, UT_StringHolder s)
515  { UT_StringWrap(s).saveBinary(os); }
516  static void saveData(std::ostream &os, UT_SharedPtr<UT_Ramp> s)
518  UT_OStringStream ostr;
519  if (s) s->save(ostr);
520  result = ostr.str();
521  saveData(os, result);
522  }
523  static void saveData(std::ostream &os, PRM_DataItemHandle s)
525  UT_OStringStream ostr;
526  if (s)
527  {
528  ostr << s->getDataTypeToken();
529  ostr << ":";
530  s->saveBinary(ostr);
531  }
532  result = ostr.str();
533  saveData(os, result);
534  }
535 
536 
537  void save(std::ostream &os) const
538  {
539  int32 v = version();
540  UTwrite(os, &v);
541  saveData(os, myMethod);
542  saveData(os, myOutputType);
543  saveData(os, myOutputGroup);
544  saveData(os, myOutput);
545  {
546  int64 length = myInputs.entries();
547  UTwrite(os, &length);
548  for (exint i = 0; i < length; i++)
549  {
550  auto && _curentry = myInputs(i);
551  (void) _curentry;
552  saveData(os, _curentry.name);
553 
554  }
555  }
556  saveData(os, myInputGroup);
557  saveData(os, myUnload);
558 
559  }
560 
561  bool load(UT_IStream &is)
562  {
563  int32 v;
564  is.bread(&v, 1);
565  if (version() != v)
566  {
567  // Fail incompatible versions
568  return false;
569  }
570  loadData(is, myMethod);
571  loadData(is, myOutputType);
572  loadData(is, myOutputGroup);
573  loadData(is, myOutput);
574  {
575  int64 length;
576  is.read(&length, 1);
577  myInputs.setSize(length);
578  for (exint i = 0; i < length; i++)
579  {
580  auto && _curentry = myInputs(i);
581  (void) _curentry;
582  loadData(is, _curentry.name);
583 
584  }
585  }
586  loadData(is, myInputGroup);
587  loadData(is, myUnload);
588 
589  return true;
590  }
591 
592  Method getMethod() const { return Method(myMethod); }
593  void setMethod(Method val) { myMethod = int64(val); }
594  Method opMethod(const SOP_NodeVerb::CookParms &cookparms) const
595  {
596  SOP_Node *thissop = cookparms.getNode();
597  if (!thissop) return getMethod();
598  int64 result;
599  OP_Utils::evalOpParm(result, thissop, "method", cookparms.getCookTime(), 0);
600  return Method(result);
601  }
602  OutputType getOutputType() const { return OutputType(myOutputType); }
603  void setOutputType(OutputType val) { myOutputType = int64(val); }
605  {
606  SOP_Node *thissop = cookparms.getNode();
607  if (!thissop) return getOutputType();
608  int64 result;
609  OP_Utils::evalOpParm(result, thissop, "outputtype", cookparms.getCookTime(), 0);
610  return OutputType(result);
611  }
612  const UT_StringHolder & getOutputGroup() const { return myOutputGroup; }
613  void setOutputGroup(const UT_StringHolder & val) { myOutputGroup = val; }
615  {
616  SOP_Node *thissop = cookparms.getNode();
617  if (!thissop) return getOutputGroup();
619  OP_Utils::evalOpParm(result, thissop, "outputgroup", cookparms.getCookTime(), 0);
620  return result;
621  }
622  const UT_StringHolder & getOutput() const { return myOutput; }
623  void setOutput(const UT_StringHolder & val) { myOutput = val; }
625  {
626  SOP_Node *thissop = cookparms.getNode();
627  if (!thissop) return getOutput();
629  OP_Utils::evalOpParm(result, thissop, "output", cookparms.getCookTime(), 0);
630  return result;
631  }
632  const UT_Array<Inputs> &getInputs() const { return myInputs; }
633 void setInputs(const UT_Array<Inputs> &val) { myInputs = val; }
634  exint opInputs(const SOP_NodeVerb::CookParms &cookparms) const
635  {
636  SOP_Node *thissop = cookparms.getNode();
637  if (!thissop) return getInputs().entries();
638  exint result;
639  OP_Utils::evalOpParm(result, thissop, "inputs", cookparms.getCookTime(), 0);
640  return result;
641  }
642  UT_StringHolder opInputs_name(const SOP_NodeVerb::CookParms &cookparms, int _idx) const
643  { return opinstInputs_name(cookparms, &_idx); }
644  UT_StringHolder opinstInputs_name(const SOP_NodeVerb::CookParms &cookparms, const int *_idx) const
645  {
646  SOP_Node *thissop = cookparms.getNode();
647  if (!thissop) return (myInputs(_idx[0]).name);
648  int _parmidx[2-1];
649  _parmidx[1-1] = _idx[1-1] + 0;
650 
652  OP_Utils::evalOpParmInst(result, thissop, "name#", _parmidx, cookparms.getCookTime(), 0, 2-1);
653  return (result);
654  }
655 
656  const UT_StringHolder & getInputGroup() const { return myInputGroup; }
657  void setInputGroup(const UT_StringHolder & val) { myInputGroup = val; }
659  {
660  SOP_Node *thissop = cookparms.getNode();
661  if (!thissop) return getInputGroup();
663  OP_Utils::evalOpParm(result, thissop, "inputgroup", cookparms.getCookTime(), 0);
664  return result;
665  }
666  Unload getUnload() const { return Unload(myUnload); }
667  void setUnload(Unload val) { myUnload = int64(val); }
668  Unload opUnload(const SOP_NodeVerb::CookParms &cookparms) const
669  {
670  SOP_Node *thissop = cookparms.getNode();
671  if (!thissop) return getUnload();
672  int64 result;
673  OP_Utils::evalOpParm(result, thissop, "unload", cookparms.getCookTime(), 0);
674  return Unload(result);
675  }
676 
677 private:
678  int64 myMethod;
679  int64 myOutputType;
680  UT_StringHolder myOutputGroup;
681  UT_StringHolder myOutput;
682  UT_Array<Inputs> myInputs;
683  UT_StringHolder myInputGroup;
684  int64 myUnload;
685 
686 };
static void saveData(std::ostream &os, UT_StringHolder s)
void setNestParmValue(TempIndex idx, TempIndex instance, const exint &value) override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_SharedPtr< UT_Ramp > &value) override
static void saveData(std::ostream &os, UT_Matrix2D v)
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition: glcorearb.h:2540
static void loadData(UT_IStream &is, UT_Vector4I &v)
int int32
Definition: SYS_Types.h:39
SOP_Node * getNode() const
Definition: SOP_NodeVerb.h:347
static void saveData(std::ostream &os, UT_SharedPtr< UT_Ramp > s)
UT_StringHolder opOutput(const SOP_NodeVerb::CookParms &cookparms) const
T clampMaxValue(fpreal maxvalue, const T &src) const
Definition: OP_NodeParms.h:315
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix2D &value) override
void getNestParmValue(TempIndex idx, TempIndex instance, fpreal &value) const override
static void saveData(std::ostream &os, UT_Vector4D v)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix3D &value) const override
void
Definition: png.h:1083
exint bread(int32 *buffer, exint asize=1)
GLboolean * data
Definition: glcorearb.h:131
GT_API const UT_StringHolder time
void setOutputGroup(const UT_StringHolder &val)
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector4.h:493
const GLdouble * v
Definition: glcorearb.h:837
void getNestParmValue(TempIndex idx, TempIndex instance, UT_SharedPtr< UT_Ramp > &value) const override
fpreal getTime() const
Definition: OP_Context.h:62
exint getNestNumParms(TempIndex idx) const override
const UT_Array< Inputs > & getInputs() const
UT_String makeQuotedString(char delimiter='\'', bool escape_nonprinting=false) const
const OP_Context & context() const
Definition: OP_NodeParms.h:97
UT_StringHolder opInputs_name(const SOP_NodeVerb::CookParms &cookparms, int _idx) 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
bool operator!=(const Inputs &src) const
GLdouble s
Definition: glad.h:3009
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector2D &value) const override
GLuint GLsizei GLsizei * length
Definition: glcorearb.h:795
const UT_StringHolder & getOutput() const
An output stream object that owns its own string buffer storage.
UT_StringHolder opOutputGroup(const SOP_NodeVerb::CookParms &cookparms) const
bool load(UT_IStream &is)
static void loadData(UT_IStream &is, bool &v)
void getNestParmValue(TempIndex idx, TempIndex instance, PRM_DataItemHandle &value) const override
**But if you need a result
Definition: thread.h:613
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector3D &value) override
T clampMinValue(fpreal minvalue, const T &src) const
Definition: OP_NodeParms.h:308
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.
static void saveData(std::ostream &os, int64 v)
void setInputGroup(const UT_StringHolder &val)
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector4.h:491
OutputType opOutputType(const SOP_NodeVerb::CookParms &cookparms) const
GLuint GLsizei const GLuint const GLintptr * offsets
Definition: glcorearb.h:2621
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector3D &value) const override
double fpreal64
Definition: SYS_Types.h:201
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector2.h:423
void doSetParmValue(TempIndex idx, TempIndex instance, const T &value)
void setNestParmValue(TempIndex idx, TempIndex instance, const PRM_DataItemHandle &value) override
static void saveData(std::ostream &os, bool v)
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector4D &value) override
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
Definition: Dimensions.h:137
static void saveData(std::ostream &os, fpreal64 v)
bool isParmColorRamp(exint idx) const override
static void loadData(UT_IStream &is, UT_Vector4D &v)
static void saveData(std::ostream &os, PRM_DataItemHandle s)
const char * getNestParmName(TempIndex fieldnum) const override
static void saveData(std::ostream &os, UT_Matrix3D v)
void setOutput(const UT_StringHolder &val)
exint length() const
SYS_FORCE_INLINE const char * buffer() const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
Definition: UT_SharedPtr.h:36
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Vector2D &value) override
constexpr SYS_FORCE_INLINE T & z() noexcept
Definition: UT_Vector4.h:495
static void loadData(UT_IStream &is, PRM_DataItemHandle &v)
exint opInputs(const SOP_NodeVerb::CookParms &cookparms) const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix2D &value) const override
exint read(bool *array, exint sz=1)
Definition: UT_IStream.h:276
const OP_GraphProxy * graph() const
Definition: OP_NodeParms.h:94
void doGetParmValue(TempIndex idx, TempIndex instance, T &value) const
virtual void evalOpParmInst(int64 &v, NodeIdx node, const char *parmname, const int *inst, const int *offsets, fpreal time, DEP_MicroNode *depnode, int nestlevel=1) const =0
long long int64
Definition: SYS_Types.h:116
OutputType getOutputType() const
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_StringHolder &value) override
void getNestParmValue(TempIndex idx, TempIndex instance, UT_StringHolder &value) const override
void setOutputType(OutputType val)
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Matrix4D &value) const override
static void loadData(UT_IStream &is, int64 &v)
Unload opUnload(const SOP_NodeVerb::CookParms &cookparms) const
static void loadData(UT_IStream &is, UT_StringHolder &v)
bool operator==(const SOP_InvokeGraphParms &src) const
static void loadData(UT_IStream &is, UT_Matrix4D &v)
GLuint const GLchar * name
Definition: glcorearb.h:786
virtual void evalOpParm(int64 &v, NodeIdx node, const char *parmname, fpreal time, DEP_MicroNode *depnode) const =0
SYS_FORCE_INLINE void strcat(const char *src)
static void loadData(UT_IStream &is, UT_Vector3D &v)
void saveBinary(std::ostream &os) const
Save string to binary stream.
Definition: UT_String.h:296
UT_StringHolder createString(const UT_Array< Inputs > &list) const
GT_API const UT_StringHolder version
void save(std::ostream &os) const
static void loadData(UT_IStream &is, fpreal64 &v)
exint entries() const
Alias of size(). size() is preferred.
Definition: UT_Array.h:648
const UT_StringHolder & getOutputGroup() const
static void saveData(std::ostream &os, UT_Vector3D v)
bool operator!=(const SOP_InvokeGraphParms &src) const
static void loadData(UT_IStream &is, UT_Matrix3D &v)
void setInputs(const UT_Array< Inputs > &val)
void coerceValue(T &result, const S &src) const
Definition: OP_NodeParms.h:301
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix3D &value) override
void setNestParmValue(TempIndex idx, TempIndex instance, const UT_Matrix4D &value) override
static void loadData(UT_IStream &is, UT_SharedPtr< UT_Ramp > &v)
fpreal64 fpreal
Definition: SYS_Types.h:277
DEP_MicroNode * depnode() const
Definition: OP_NodeParms.h:99
void setNestParmValue(TempIndex idx, TempIndex instance, const fpreal &value) override
Utility class for containing a color ramp.
Definition: UT_Ramp.h:88
ParmType getNestParmType(TempIndex fieldnum) const override
constexpr SYS_FORCE_INLINE T & w() noexcept
Definition: UT_Vector4.h:497
SYS_FORCE_INLINE void append(char character)
GLuint GLfloat * val
Definition: glcorearb.h:1608
static void loadData(UT_IStream &is, UT_Matrix2D &v)
UT_StringHolder opInputGroup(const SOP_NodeVerb::CookParms &cookparms) const
#define SOP_API
Definition: SOP_API.h:10
fpreal getCookTime() const
Definition: SOP_NodeVerb.h:361
void loadFromOpSubclass(const LoadParms &loadparms) override
bool operator==(const Inputs &src) const
const char * findChar(int c) const
Definition: UT_String.h:1385
#define UT_ASSERT(ZZ)
Definition: UT_Assert.h:156
Definition: core.h:1131
static void saveData(std::ostream &os, UT_Vector2D v)
GLboolean r
Definition: glcorearb.h:1222
void getNestParmValue(TempIndex idx, TempIndex instance, exint &value) const override
const UT_StringHolder & getInputGroup() const
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector3.h:665
type
Definition: core.h:1059
void buildFromOp(const OP_GraphProxy *graph, exint nodeidx, fpreal time, DEP_MicroNode *depnode)
static void loadData(UT_IStream &is, UT_Vector2I &v)
UT_StringHolder opinstInputs_name(const SOP_NodeVerb::CookParms &cookparms, const int *_idx) const
UT_SharedPtr< const PRM_DataItem > PRM_DataItemHandle
Definition: PRM_Parm.h:89
static void saveData(std::ostream &os, UT_Matrix4D v)
constexpr SYS_FORCE_INLINE T & y() noexcept
Definition: UT_Vector2.h:425
SYS_FORCE_INLINE bool isstring() const
void getNestParmValue(TempIndex idx, TempIndex instance, UT_Vector4D &value) const override
Method opMethod(const SOP_NodeVerb::CookParms &cookparms) const
OP_NodeParms & operator=(const OP_NodeParms &)=default
SYS_FORCE_INLINE void strncpy(const char *src, exint maxlen)
static void loadData(UT_IStream &is, UT_Vector3I &v)
GLenum src
Definition: glcorearb.h:1793
constexpr SYS_FORCE_INLINE T & x() noexcept
Definition: UT_Vector3.h:663
void copyFrom(const OP_NodeParms *src) override
static void loadData(UT_IStream &is, UT_Vector2D &v)