00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef __GAS_Feedback__
00020 #define __GAS_Feedback__
00021
00022 #include "GAS_API.h"
00023
00024 #include "GAS_SubSolver.h"
00025 #include "GAS_Utils.h"
00026
00027 class SIM_RawField;
00028 class SIM_ScalarField;
00029 class SIM_IndexField;
00030
00031 class GAS_API GAS_Feedback : public GAS_SubSolver
00032 {
00033 public:
00034 GET_DATA_FUNC_S(GAS_NAME_PRESSURE, PressureName);
00035 GET_DATA_FUNC_S(GAS_NAME_COLLISION, CollisionName);
00036 GET_DATA_FUNC_S(GAS_NAME_INDEX, IndexName);
00037
00038 GET_DATA_FUNC_F("feedbackscale", FeedbackScale);
00039
00040 protected:
00041 explicit GAS_Feedback(const SIM_DataFactory *factory);
00042 virtual ~GAS_Feedback();
00043
00044
00045
00046 virtual bool solveGasSubclass(SIM_Engine &engine,
00047 SIM_Object *obj,
00048 SIM_Time time,
00049 SIM_Time timestep);
00050
00051
00052
00053
00054 void addPressureFeedback(SIM_Engine &engine,
00055 SIM_ScalarField *collisionmask,
00056 SIM_Object *fluidobj,
00057 SIM_IndexField *collideindex,
00058 SIM_RawField *pressure,
00059 const SIM_Time &time) const;
00060
00061 private:
00062 static const SIM_DopDescription *getDopDescription();
00063
00064 DECLARE_STANDARD_GETCASTTOTYPE();
00065 DECLARE_DATAFACTORY(GAS_Feedback,
00066 GAS_SubSolver,
00067 "Gas Feedback",
00068 getDopDescription());
00069 };
00070
00071 #endif
00072