Add benchmark (#67)

Added benchmark from PEEL.
Implement #60
This commit is contained in:
Erin Catto 2026-07-10 23:21:37 -07:00 • committed by GitHub
commit e9f6f1d0aa
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 249 additions and 30 deletions

View file

@ -1449,3 +1449,27 @@ public:
};
static int sampleJunkyard = RegisterSample( "Benchmark", "Junkyard", BenchmarkJunkyard::Create );
class BenchmarkConvexPile : public Sample
{
public:
explicit BenchmarkConvexPile( SampleContext* context )
: Sample( context )
{
if ( context->restart == false )
{
m_camera->SetView( 45.0f, 20.0f, 150.0f, { 0.0f, 15.0f, 0.0f } );
}
CreateConvexPile( m_worldId );
SetGroundShape( GetGroundShapeId() );
}
static Sample* Create( SampleContext* context )
{
return new BenchmarkConvexPile( context );
}
};
static int sampleConvexPile = RegisterSample( "Benchmark", "Convex Pile", BenchmarkConvexPile::Create );