/** * Construct a world object. * * @param gravity the world gravity vector. */ public World(Vec2 gravity, IWorldPool pool) { this(gravity, pool, new DynamicTree()); }
/** * Construct a world object. * * @param gravity the world gravity vector. */ public World(Vec2 gravity, IWorldPool pool) { this(gravity, pool, new DynamicTree()); }
/** * Construct a world object. * * @param gravity the world gravity vector. */ public World(Vec2 gravity, IWorldPool pool) { this(gravity, pool, new DynamicTree()); }
/** * Construct a world object. * * @param gravity the world gravity vector. */ public World(Vec2 gravity, IWorldPool pool) { this(gravity, pool, new DynamicTree()); }
/** * Construct a world object. * * @param gravity the world gravity vector. */ public World(Vec2 gravity, IWorldPool pool) { this(gravity, pool, new DynamicTree()); }
@Override public void initTest(boolean argDeserialized) { worldExtent = 15.0f; m_proxyExtent = 0.5f; m_tree = new DynamicTree(); for (int i = 0; i < e_actorCount; ++i) { Actor actor = m_actors[i] = new Actor(); GetRandomAABB(actor.aabb); actor.proxyId = m_tree.createProxy(actor.aabb, actor); } m_stepCount = 0; float h = worldExtent; m_queryAABB = new AABB(); m_queryAABB.lowerBound.set(-3.0f, -4.0f + h); m_queryAABB.upperBound.set(5.0f, 6.0f + h); m_rayCastInput = new RayCastInput(); m_rayCastInput.p1.set(-5.0f, 5.0f + h); m_rayCastInput.p2.set(7.0f, -4.0f + h); // m_rayCastInput.p1.set(0.0f, 2.0f + h); // m_rayCastInput.p2.set(0.0f, -2.0f + h); m_rayCastInput.maxFraction = 1.0f; m_rayCastOutput = new RayCastOutput(); m_automated = false; }
@Override public void initTest(boolean argDeserialized) { worldExtent = 15.0f; m_proxyExtent = 0.5f; m_tree = new DynamicTree(); for (int i = 0; i < e_actorCount; ++i) { Actor actor = m_actors[i] = new Actor(); GetRandomAABB(actor.aabb); actor.proxyId = m_tree.createProxy(actor.aabb, actor); } m_stepCount = 0; float h = worldExtent; m_queryAABB = new AABB(); m_queryAABB.lowerBound.set(-3.0f, -4.0f + h); m_queryAABB.upperBound.set(5.0f, 6.0f + h); m_rayCastInput = new RayCastInput(); m_rayCastInput.p1.set(-5.0f, 5.0f + h); m_rayCastInput.p2.set(7.0f, -4.0f + h); // m_rayCastInput.p1.set(0.0f, 2.0f + h); // m_rayCastInput.p2.set(0.0f, -2.0f + h); m_rayCastInput.maxFraction = 1.0f; m_rayCastOutput = new RayCastOutput(); m_automated = false; }
@Override public void runBenchmarkWorld() { BroadPhaseStrategy strategy = new DynamicTree();