You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -13,6 +14,7 @@ using the [Fluidix](http://onezero.ca/documentation/) library (if a nvidia GPU i
13
14
# How the package works
14
15
15
16
The fluid simulation runs as a separate physics engine which interacts with the rigid body physics engine of Gazebo through an interface (`include/FluidEngine.hh`).
17
+
16
18
The interaction includes:
17
19
* collision detection
18
20
* forces / torques application on the rigid objects
@@ -24,60 +26,72 @@ The package contains two plugins, one world plugin for updating the fluid and it
24
26
25
27
## Build instructions
26
28
27
-
* in a terminal go to the downloaded `gz_fluid` folder and run the following commands
28
-
* $ mkdir build
29
-
* $ cd build
30
-
* $ cmake ..
31
-
* $ make
32
-
33
-
## Running the plugin:
34
-
35
-
* set the gazebo plugin paths
36
-
* add the plugin to your world file (e.g worlds/fluid.world), or use one of the world examples from the package
37
-
* run gazebo server with the world plugin:
38
-
* $ gzserver worlds/fluid.world
39
-
* run gazebo client with the system plugin:
40
-
* $ gzclient -g build/libFluidVisPlugin.so
29
+
In a terminal go to the downloaded `gz_fluid` folder and run the following commands:
41
30
31
+
~~~
32
+
mkdir build
33
+
cd build
34
+
cmake ..
35
+
make
36
+
~~~
42
37
43
-
## How to specify fluid parameters
38
+
## Running the plugin:
44
39
45
-
* change fluid plugin parameters from the sdf tags:
46
-
*`<world_position>` and `<world_size>` set the fluid worlds center position and its size
47
-
*`<fluid_position>` and `<fluid_volume>` set the center position of the fluid and its volume to be filled with particles
48
-
*`<particle_nr>` if set to `0`, the given volume will be filled with fluid particles, otherwise the given particle number will be spawned.
* in the constructor the fluid engine is initialized
82
96
* in `FluidWorldPlugin::Load` the sdf parameters are loaded, the fluid world is created, fluid is added, the objects from the environment are recreated in the fluid environment (when possible)
83
97
* in `FluidWorldPlugin::Init` the publishers of the objects and fluids particles positions are initialized
@@ -96,8 +110,8 @@ The package contains two plugins, one world plugin for updating the fluid and it
96
110
# Unfinished parts, TODOs:
97
111
If somebody is interested in further contributing to the package, many features still need work:
98
112
99
-
*implementing a newer SPH: [PCISPH](https://sph-sjtu-f06.googlecode.com/files/a40-solenthaler.pdf) or [IISPH](http://cg.informatik.uni-freiburg.de/publications/2013_TVCG_IISPH.pdf) for faster simulation and no compression of the fluid. This can be done in the `src/FluidEngine.cu` file by changing the algorithm.
113
+
*Implementing a newer SPH: [PCISPH](https://sph-sjtu-f06.googlecode.com/files/a40-solenthaler.pdf) or [IISPH](http://cg.informatik.uni-freiburg.de/publications/2013_TVCG_IISPH.pdf) for faster simulation and no compression of the fluid. This can be done in the `src/FluidEngine.cu` file by changing the algorithm.
100
114
101
-
*currently the simulation only has the box implemented as a standard shape, see `FluidEngine::AddMovableBox` from `src/FluidEngine.cu`, it is implemented similarly to this [example](http://onezero.ca/sample/?id=init_manual). Using the same idea the rest of the collision types can be implemented as well: cylinder, sphere, plane. After implementation these need to be added in the `FluidWorldPlugin::CreateFluidCollision` method, similarly to the `box` type.
115
+
*Currently the simulation only has the box implemented as a standard shape, see `FluidEngine::AddMovableBox` from `src/FluidEngine.cu`, it is implemented similarly to this [example](http://onezero.ca/sample/?id=init_manual). Using the same idea the rest of the collision types can be implemented as well: cylinder, sphere, plane. After implementation these need to be added in the `FluidWorldPlugin::CreateFluidCollision` method, similarly to the `box` type.
102
116
103
-
*the force and torque interaction is done via the particles surface collisions, pressure force from the liquid is not taken into account. A fancier algorithm would greatly increase realism.
117
+
*The force and torque interaction is done via the particles surface collisions, pressure force from the liquid is not taken into account. A fancier algorithm would greatly increase realism.
0 commit comments