HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GAS_ResetInactive.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: GAS_ResetInactive.h ( GAS Library, C++)
7  *
8  * COMMENTS:
9  * This operator resets fields to their background value in areas that are
10  * masked out by the stencil field.
11  */
12 
13 #ifndef __GAS_ResetInactive__
14 #define __GAS_ResetInactive__
15 
16 #include "GAS_SubSolver.h"
17 #include "GAS_Utils.h"
18 
20 {
21 public:
22  GET_DATA_FUNC_S("resetfields", FieldsToReset);
23  GET_DATA_FUNC_S(GAS_NAME_STENCIL, StencilField);
24 
25 protected:
26  explicit GAS_ResetInactive(const SIM_DataFactory* factory);
27  ~GAS_ResetInactive() override;
28 
29  bool solveGasSubclass(SIM_Engine& engine,
30  SIM_Object* obj,
31  SIM_Time time,
32  SIM_Time timestep) override;
33 
34  THREADED_METHOD2(GAS_ResetInactive, field->field()->numTiles() > 64,
35  resetField,
36  SIM_RawField*, field,
37  const SIM_RawField*, stencil);
38  void resetFieldPartial(SIM_RawField* field,
39  const SIM_RawField* stencil,
40  const UT_JobInfo& info);
41 
42  THREADED_METHOD3(GAS_ResetInactive, stencil->numTiles() > 64,
43  resetAlignedFields,
44  const UT_Array<UT_VoxelArrayF*>&, fields,
45  const UT_Array<float>&, bvals,
46  const UT_VoxelArrayF*, stencil);
47  void resetAlignedFieldsPartial(
48  const UT_Array<UT_VoxelArrayF*>& fields,
49  const UT_Array<float>& bvals,
50  const UT_VoxelArrayF* stencil,
51  const UT_JobInfo& info);
52 
53 private:
54  static const SIM_DopDescription* getDopDescription();
55 
59  "Gas Reset Inactive",
60  getDopDescription());
61 };
62 
63 #endif
64 
#define DECLARE_STANDARD_GETCASTTOTYPE()
Definition: SIM_DataUtils.h:50
GT_API const UT_StringHolder time
#define GAS_API
Definition: GAS_API.h:10
virtual bool solveGasSubclass(SIM_Engine &engine, SIM_Object *obj, SIM_Time time, SIM_Time timestep)=0
#define THREADED_METHOD3(CLASSNAME, DOMULTI, METHOD, PARMTYPE1, PARMNAME1, PARMTYPE2, PARMNAME2, PARMTYPE3, PARMNAME3)
#define DECLARE_DATAFACTORY(DataClass, SuperClass, Description, DopParms)
Definition: SIM_DataUtils.h:63
#define THREADED_METHOD2(CLASSNAME, DOMULTI, METHOD, PARMTYPE1, PARMNAME1, PARMTYPE2, PARMNAME2)
GLint GLfloat GLint stencil
Definition: glcorearb.h:1278
#define GET_DATA_FUNC_S(DataName, FuncName)
#define GAS_NAME_STENCIL
Definition: GAS_Utils.h:19