Exemple #1
0
 public PhysicsOutput ObbTest(AABB aabb, long angle, AABB outterAABB)
 {
     output.EndIndex  = 0;
     _toTestAABB      = aabb;
     _toTestAABBAngle = angle;
     PhysicsTree.Query(ObbTestCallback, ref outterAABB);
     return(output);
 }
        private void Query()
        {
            _tree.Query(QueryCallback, ref _queryAABB);

            for (int i = 0; i < ActorCount; ++i)
            {
                if (_actors[i].ProxyId == -1)
                {
                    continue;
                }

                bool overlap = AABB.TestOverlap(ref _queryAABB, ref _actors[i].AABB);
                Debug.Assert(overlap == _actors[i].Overlap);
            }
        }
        private void Query()
        {
            _tree.Query(QueryCallback, ref _queryAABB);

            for (int i = 0; i < _actorCount; ++i)
            {
                if (_actors[i].proxyId == DynamicTree <Actor> .NullNode)
                {
                    continue;
                }

                bool overlap = AABB.TestOverlap(ref _queryAABB, ref _actors[i].aabb);

                //B2_NOT_USED(overlap);
                Debug.Assert(overlap == _actors[i].overlap);
            }
        }
 public void Query <T>(T collector, AABB aabb) where T : IQueryResultCollector <Entity>
 {
     Tree.Query(collector, aabb);
 }