static void IsectAnyRaySphere(benchmark::State& state) { RayIntersection isect; Ray ray(Vector4(0, 0, -10), Vector4(0, 0, 1)); Sphere obj; float hit; for (auto _ : state) { hit = obj.intersectsAny(ray, 0.1f); benchmark::DoNotOptimize(hit); } }