00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef __GAS_SPHDensity__
00022 #define __GAS_SPHDensity__
00023
00024 #include "GAS_API.h"
00025
00026 #include <GU/GU_Detail.h>
00027
00028 #include <UT/UT_ThreadedAlgorithm.h>
00029
00030 #include "GAS_SubSolver.h"
00031 #include "GAS_Utils.h"
00032
00033 class GU_Detail;
00034
00035 class GAS_API GAS_SPHDensity : public GAS_SubSolver
00036 {
00037 public:
00038 GET_DATA_FUNC_S(GAS_NAME_GEOMETRY, GeometryName);
00039
00040 bool shouldMultiThread() { return true; }
00041
00042 protected:
00043 explicit GAS_SPHDensity(const SIM_DataFactory *factory);
00044 virtual ~GAS_SPHDensity();
00045
00046
00047
00048 virtual bool solveGasSubclass(SIM_Engine &engine,
00049 SIM_Object *obj,
00050 SIM_Time time,
00051 SIM_Time timestep);
00052
00053 protected:
00054 THREADED_METHOD1(GAS_SPHDensity, shouldMultiThread(), calculateDensity,
00055 GU_Detail *, gdp)
00056 void calculateDensityPartial(GU_Detail *gdp,
00057 const UT_JobInfo &info);
00058
00059 private:
00060 static const SIM_DopDescription *getDopDescription();
00061
00062 DECLARE_STANDARD_GETCASTTOTYPE();
00063 DECLARE_DATAFACTORY(GAS_SPHDensity,
00064 GAS_SubSolver,
00065 "Gas SPH Density",
00066 getDopDescription());
00067 };
00068
00069 #endif