MeVisLab Resolution Independence API
SoCalculatorWrapper.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2007, MeVis Medical Solutions AG
4**
5** The user may use this file in accordance with the license agreement provided with
6** the Software or, alternatively, in accordance with the terms contained in a
7** written agreement between the user and MeVis Medical Solutions AG.
8**
9** For further information use the contact form at https://www.mevislab.de/contact
10**
11**************************************************************************************/
12
13#ifndef SO_CALCULATOR_WRAPPER_H
14#define SO_CALCULATOR_WRAPPER_H
15
17
18#include "SoUtilsSystem.h"
19#include <ThirdPartyWarningsDisable.h>
20#include <Inventor/engines/SoSubEngine.h>
21#include <Inventor/fields/SoSFFloat.h>
22#include <Inventor/fields/SoSFVec3f.h>
23#include <ThirdPartyWarningsRestore.h>
24class SoCalculator;
25
26//=============================================================
29
37//=============================================================
38class SoCalculatorWrapper : public SoEngine {
39
40 SO_ENGINE_HEADER(SoCalculatorWrapper);
41
42 public:
44
46 SoSFFloat a,b,c,d,e,f,g,h;
47
49 SoSFVec3f va,vb,vc,vd,ve,vf,vg,vh;
50
52 SoSFFloat oa,ob,oc,od;
54 SoSFVec3f ova,ovb,ovc,ovd;
55
57 SoSFString expression;
58
60
62 static void initClass();
63
66
68 void inputChanged(SoField *whichField) override;
69
71 void evaluate() override {};
72
73 protected:
75
76 private:
78 SoRef<SoCalculator> _calc;
79};
80
81#endif
SoCalculatorWrapper wraps the SoCalculator engine to make it usable inside of MeVisLab.
SoCalculatorWrapper()
Constructor.
static void initClass()
inventor runtime type system init
void inputChanged(SoField *whichField) override
handle input field changes and recompute output fields
~SoCalculatorWrapper() override
SoSFVec3f ova
output vector fields
SoSFString expression
expression that is used to calculate the results
void evaluate() override
empty reimplementation of SoEngine method
SoSFVec3f va
input vector fields
SoSFFloat oa
output float fields