More fluid simulation settings
This commit is contained in:
1 parent
b1004d5c80
commit
f2a3f59ab1
5 files changed
+221
-19
No files matched your search
@@ -79,8 +79,21 @@ class SimulationComputePass : public RenderPass {
|
||||
constexpr static UVector threadGroupSize = {32, 8, 1};
|
||||
} applyForces;
|
||||
void applyForcesPass(Gfx::PShaderBuffer velocityX, Gfx::PShaderBuffer velocityY, Gfx::PShaderBuffer velocityZ, Vector gravity, float dt, UVector gridSize);
|
||||
// Diagnostics: sum interior fields and log to console. Not part of the simulation.
|
||||
void massProbePass(Gfx::PShaderBuffer density, Gfx::PShaderBuffer phi, Gfx::PShaderBuffer velocityX, Gfx::PShaderBuffer velocityY,
|
||||
Gfx::PShaderBuffer velocityZ, UVector gridSize);
|
||||
struct MassProbe {
|
||||
Gfx::OPipelineLayout pipelineLayout;
|
||||
Gfx::ODescriptorLayout descriptorLayout;
|
||||
Gfx::OComputeShader shader;
|
||||
Gfx::PComputePipeline pipeline;
|
||||
constexpr static UVector threadGroupSize = {32, 8, 1};
|
||||
} massProbe;
|
||||
Gfx::ODescriptorLayout gridSizeLayout;
|
||||
Gfx::ODescriptorSet gridSizeSet;
|
||||
// Diagnostics: 3 floats (density sum, phi sum, |velocity| sum), zeroed each frame.
|
||||
Gfx::OShaderBuffer probeOutBuffer;
|
||||
uint32 probeFrame = 0;
|
||||
struct BoundaryPlane {
|
||||
Vector normal;
|
||||
float d;
|
||||
|
||||
Reference in new issue
Block a user