Show
Ignore:
Timestamp:
03/21/12 18:36:20 (2 years ago)
Author:
robert
Message:

Ran script to remove trailing spaces and tabs

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/src/osg/CollectOccludersVisitor.cpp

    r6248 r13041  
    1 /* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield  
     1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield 
    22 * 
    3  * This library is open source and may be redistributed and/or modified under   
    4  * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or  
     3 * This library is open source and may be redistributed and/or modified under 
     4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or 
    55 * (at your option) any later version.  The full license is in LICENSE file 
    66 * included with this distribution, and on the openscenegraph.org website. 
    7  *  
     7 * 
    88 * This library is distributed in the hope that it will be useful, 
    99 * but WITHOUT ANY WARRANTY; without even the implied warranty of 
    10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the  
     10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
    1111 * OpenSceneGraph Public License for more details. 
    1212*/ 
     
    3030                   FAR_PLANE_CULLING| 
    3131                   SMALL_FEATURE_CULLING); 
    32      
     32 
    3333    _minimumShadowOccluderVolume = 0.005f; 
    3434    _maximumNumberOfActiveOccluders = 10; 
    3535    _createDrawables = false; 
    36      
     36 
    3737} 
    3838 
     
    6363    const Matrix& matrix = *_modelviewStack.back(); 
    6464    float dist = -(pos[0]*matrix(0,2)+pos[1]*matrix(1,2)+pos[2]*matrix(2,2)+matrix(3,2)); 
    65      
     65 
    6666    if (withLODScale) return dist*getLODScale(); 
    6767    else return dist*getLODScale(); 
     
    7474    // push the culling mode. 
    7575    pushCurrentMask(); 
    76      
    77     handle_cull_callbacks_and_traverse(node); 
    78      
     76 
     77    handle_cull_callbacks_and_traverse(node); 
     78 
    7979    // pop the culling mode. 
    8080    popCurrentMask(); 
     
    9191    node.computeLocalToWorldMatrix(*matrix,this); 
    9292    pushModelViewMatrix(matrix.get(), node.getReferenceFrame()); 
    93      
     93 
    9494    handle_cull_callbacks_and_traverse(node); 
    9595 
     
    109109    ref_ptr<osg::RefMatrix> matrix = createOrReuseMatrix(node.getMatrix()); 
    110110    pushProjectionMatrix(matrix.get()); 
    111      
     111 
    112112    handle_cull_callbacks_and_traverse(node); 
    113113 
     
    141141    // list, if so disable the appropriate ShadowOccluderVolume 
    142142    disableAndPushOccludersCurrentMask(_nodePath); 
    143      
     143 
    144144 
    145145    if (isCulled(node)) 
     
    165165        if (svo.computeOccluder(_nodePath, *node.getOccluder(), *this,_createDrawables)) 
    166166        { 
    167          
     167 
    168168            if (svo.getVolume()>_minimumShadowOccluderVolume) 
    169169            { 
     
    183183    // pop the culling mode. 
    184184    popCurrentMask(); 
    185      
     185 
    186186    // pop the current mask for the disabled occluder 
    187187    popOccludersCurrentMask(_nodePath); 
     
    191191{ 
    192192    if (_occluderSet.empty()) return; 
    193          
     193 
    194194    ShadowVolumeOccluderSet::iterator occludeeItr=_occluderSet.begin(); 
    195      
     195 
    196196    // skip the first element as this can't be occluded by anything else. 
    197197    occludeeItr++; 
     
    202202        ++occludeeItr) 
    203203    { 
    204          
     204 
    205205        // search for any occluders that occlude the current occluder, 
    206206        // we only need to test any occluder near the front of the set since 
     
    225225                break; 
    226226            } 
    227              
    228             // now check all the holes in the occludee against the occluder,  
     227 
     228            // now check all the holes in the occludee against the occluder, 
    229229            // do so in reverse order so that the iterators remain valid. 
    230230            for(ShadowVolumeOccluder::HoleList::reverse_iterator holeItr=holeList.rbegin(); 
     
    240240                    ++holeItr; 
    241241                } 
    242                  
    243             } 
    244              
     242 
     243            } 
     244 
    245245        } 
    246246    } 
    247      
     247 
    248248 
    249249    if (_occluderSet.size()<=_maximumNumberOfActiveOccluders) return; 
    250      
     250 
    251251    // move the iterator to the _maximumNumberOfActiveOccluders th occluder. 
    252252    occludeeItr = _occluderSet.begin(); 
    253253    for(unsigned int i=0;i<_maximumNumberOfActiveOccluders;++i) 
    254254        ++occludeeItr; 
    255          
     255 
    256256    // discard last occluders. 
    257257    _occluderSet.erase(occludeeItr,_occluderSet.end()); 
    258      
    259 } 
     258 
     259}