Skip to content

v4.1.0

Choose a tag to compare

@github-actions github-actions released this 14 Apr 23:01
· 94 commits to main since this release

v4.1.0

GroundProvider is gone. Use TerrainInterface instead.

Breaking

  • Deleted: GroundProvider, UniformGroundProvider, TerrainProviderAdapter, docs/ground_providers.md, and the FlightSimulator(launch, atmos, GroundProvider) overload.
  • FlightSimulator now has two constructors: (launch, atmos, GroundSurface) for flat ground and (launch, atmos, TerrainInterface, model) for custom.

Porting

// Before
MyProvider p;
FlightSimulator sim(ball, atmos, p);

// After
FlightSimulator sim(ball, atmos, std::make_shared<MyTerrain>());

Mechanical translation:

  • public GroundProvider → public TerrainInterface
  • getGroundAt(x, y) → getSurfaceProperties(x, y); also implement getHeight and getNormal
  • Remove the clone() override; TerrainInterface is passed by shared_ptr

See docs/terrain.md and examples/multi_ground_simulation.cpp for a working example.