MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/SPlisHSPlasH / reset

Method reset

SPlisHSPlasH/Simulation.cpp:511–533  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

509}
510
511void Simulation::reset()
512{
513 // reset fluid models
514 for (unsigned int i = 0; i < numberOfFluidModels(); i++)
515 getFluidModel(i)->reset();
516
517 // reset boundary models
518 for (unsigned int i = 0; i < numberOfBoundaryModels(); i++)
519 getBoundaryModel(i)->reset();
520
521 if (getBoundaryHandlingMethod() == BoundaryHandlingMethods::Akinci2012)
522 updateBoundaryVolume();
523
524 performNeighborhoodSearchSort();
525 if (m_timeStep)
526 m_timeStep->reset();
527
528 m_animationFieldSystem->reset();
529
530 m_counter = 0;
531
532 TimeManager::getCurrent()->setTime(0.0);
533}
534
535void Simulation::setSimulationMethod(const int val)
536{

Callers

nothing calls this directly

Calls 1

setTimeMethod · 0.45

Tested by

no test coverage detected