Changeset 518

Show
Ignore:
Timestamp:
10/31/09 18:18:25 (3 years ago)
Author:
darkuranium
Message:

Added dsss.conf
Bugfix in bzBroadPhase
Minor change in AUTHORS

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/AUTHORS

    r506 r518  
    11Blaze: http://www.dsource.org/projects/blaze 
    22 
    3 Original author and maintainer: Mason Green (Zzzzrrr)  
     3Original author and maintainer: Mason Green (Zzzzrrr) 
    44 
    55Contributers: 
    66 
    77    Clay Smith (Admin) 
    8     Benjamin Saunders (Testbed framework)  
     8    Benjamin Saunders (Testbed framework) 
    99    Brian Schott (Documentation) 
    10     Tim Cas (Phobos testing) 
     10    Tim Chas (Initial Phobos port + testing) 
    1111 
    12 Blaze is based on the Box2D & Motor2 physics engines, and implements  
     12Blaze is based on the Box2D & Motor2 physics engines, and implements 
    1313code and ideas from these projects. 
    1414 
    15 Box2D Author: Erin Catto  
     15Box2D Author: Erin Catto 
    1616    http://www.box2d.org 
    17      
     17 
    1818Motor2 Author: Michael Baczynski 
    1919    http://lab.polygonal.de/ 
    20      
     20 
    2121Special thanks to Rene Schulte for his C# Smooth Particle Hydrodynamics (SPH) code. 
    2222    http://www.rene-schulte.info/ 
  • trunk/blaze/collision/nbody/bzBroadPhase.d

    r511 r518  
    221221            //memmove(bounds.ptr + upperIndex + 2, bounds.ptr + upperIndex, (boundCount - upperIndex) * bzBound.sizeof); 
    222222            //memmove(bounds.ptr + lowerIndex + 1, bounds.ptr + lowerIndex, (upperIndex - lowerIndex) * bzBound.sizeof); 
    223              
     223 
    224224            bzBound[] tmp; 
    225225            tmp.length = boundCount - upperIndex; 
     
    230230                bounds[upperIndex + 2 + i] = tmp[i]; 
    231231            } 
    232              
     232 
    233233            tmp.length = upperIndex - lowerIndex; 
    234234            for (int i = 0; i < (upperIndex - lowerIndex); i++) { 
     
    302302        bzProxy proxy = m_proxyPool[proxyId]; 
    303303        assert(proxy.isValid()); 
    304          
     304 
    305305        int boundCount = 2 * m_proxyCount; 
    306306 
    307307        for (int axis = 0; axis < 2; ++axis) { 
    308          
     308 
    309309            bzBound[] bounds = m_bounds[axis]; 
    310              
     310 
    311311            int lowerIndex = proxy.lowerBounds[axis]; 
    312312            int upperIndex = proxy.upperBounds[axis]; 
    313313            int lowerValue = bounds[lowerIndex].value; 
    314314            int upperValue = bounds[upperIndex].value; 
    315              
     315 
    316316            if((upperIndex - lowerIndex - 1) < 0) { 
    317317                throw new Exception("this is a known bug"); 
    318318            } 
    319              
     319 
    320320            //memmove(bounds.ptr + lowerIndex, bounds.ptr + lowerIndex + 1, (upperIndex - lowerIndex - 1) * bzBound.sizeof); 
    321321            //memmove(bounds.ptr + upperIndex-1, bounds.ptr + upperIndex + 1, (boundCount - upperIndex - 1) * bzBound.sizeof); 
     
    347347                } 
    348348            } 
    349              
     349 
    350350            // Fix stabbing count. 
    351351            for (int index = lowerIndex; index < upperIndex - 1; ++index) { 
    352352                --bounds[index].stabbingCount; 
    353353            } 
    354              
     354 
    355355            // Query for pairs to be removed. lowerIndex and upperIndex are not 
    356356            // needed. 
     
    360360 
    361361        assert (m_queryResultCount < k_maxProxies); 
    362          
     362 
    363363        for (int i = 0; i < m_queryResultCount; ++i) { 
    364364            assert(m_proxyPool[m_queryResults[i]].isValid()); 
     
    657657        // lower/upper bounds that would have equal values. 
    658658        // TODO_ERIN implement fast float to int conversion. 
    659         lowerValues[0] = abs(cast(int) (m_quantizationFactor.x * (minVertex.x - m_worldAABB.lowerBound.x)) & (int.max - 1)); 
    660         upperValues[0] = abs(cast(int) (m_quantizationFactor.x * (maxVertex.x - m_worldAABB.lowerBound.x)) | 1); 
    661         lowerValues[1] = abs(cast(int) (m_quantizationFactor.y * (minVertex.y - m_worldAABB.lowerBound.y)) & (int.max - 1)); 
    662         upperValues[1] = abs(cast(int) (m_quantizationFactor.y * (maxVertex.y - m_worldAABB.lowerBound.y)) | 1); 
     659        lowerValues[0] = cast(int)abs(cast(int) (m_quantizationFactor.x * (minVertex.x - m_worldAABB.lowerBound.x)) & (int.max - 1)); 
     660        upperValues[0] = cast(int)abs(cast(int) (m_quantizationFactor.x * (maxVertex.x - m_worldAABB.lowerBound.x)) | 1); 
     661        lowerValues[1] = cast(int)abs(cast(int) (m_quantizationFactor.y * (minVertex.y - m_worldAABB.lowerBound.y)) & (int.max - 1)); 
     662        upperValues[1] = cast(int)abs(cast(int) (m_quantizationFactor.y * (maxVertex.y - m_worldAABB.lowerBound.y)) | 1); 
    663663   } 
    664664