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/osgPlugins/ive/Layer.cpp

    r12292 r13041  
    1 /* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2008 Robert Osfield  
     1/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2008 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*/ 
     
    3838        out_THROW_EXCEPTION("Layer::write(): Could not cast this osgLayer::Layer to an osg::Object."); 
    3939 
    40   
     40 
    4141    if (out->getVersion() >= VERSION_0023) 
    4242    { 
     
    5858        helper.writeLocator(out, getLocator()); 
    5959    } 
    60      
    61      
     60 
     61 
    6262 
    6363    out->writeUInt(getMinLevel()); 
     
    7676    if (id != IVELAYER) 
    7777        in_THROW_EXCEPTION("Layer::read(): Expected Layer identification."); 
    78      
     78 
    7979    // Read Layer's identification. 
    8080    id = in->readInt(); 
     
    118118void LayerHelper::writeLayer(DataOutputStream* out, osgTerrain::Layer* layer) 
    119119{ 
    120     if (layer)  
     120    if (layer) 
    121121    { 
    122122        out->writeBool(true); 
     
    193193        osg::ref_ptr<osg::Object> object = osgDB::readObjectFile(filename+".gdal"); 
    194194        osgTerrain::ProxyLayer* proxyLayer = dynamic_cast<osgTerrain::ProxyLayer*>(object.get()); 
    195          
     195 
    196196        osg::ref_ptr<osgTerrain::Locator> locator = readLocator(in); 
    197197        unsigned int minLevel = in->readUInt(); 
    198198        unsigned int maxLevel = in->readUInt(); 
    199          
     199 
    200200        if (proxyLayer) 
    201201        { 
    202202            if (locator.valid()) proxyLayer->setLocator(locator.get()); 
    203              
     203 
    204204            proxyLayer->setMinLevel(minLevel); 
    205205            proxyLayer->setMaxLevel(maxLevel); 
    206206        } 
    207          
     207 
    208208        return proxyLayer; 
    209209    } 
    210      
     210 
    211211    return new osgTerrain::ImageLayer; 
    212212} 
     
    214214void LayerHelper::writeLocator(DataOutputStream* out, osgTerrain::Locator* locator) 
    215215{ 
    216     if (locator)  
     216    if (locator) 
    217217    { 
    218218        out->writeBool(true); 
    219          
     219 
    220220        ((ive::Locator*)(locator))->write(out); 
    221221    } 
     
    230230    bool locatorExist = in->readBool(); 
    231231    if (!locatorExist) return 0; 
    232      
     232 
    233233    osgTerrain::Locator* locator = new osgTerrain::Locator; 
    234      
     234 
    235235    ((ive::Locator*)(locator))->read(in); 
    236      
     236 
    237237    return locator; 
    238238} 
     
    250250            out->writeFloat(validRange->getMaxValue()); 
    251251        } 
    252         else  
    253         {     
     252        else 
     253        { 
    254254            osgTerrain::NoDataValue* noDataValue  = dynamic_cast<osgTerrain::NoDataValue*>(validDataOperator); 
    255255            if (noDataValue) 
     
    270270    bool hasOperator = in->readBool(); 
    271271    if (!hasOperator) return 0; 
    272      
     272 
    273273    int id = in->peekInt(); 
    274274    if (id==IVEVALIDRANGE) 
     
    277277        float minValue = in->readFloat(); 
    278278        float maxValue = in->readFloat(); 
    279         return new osgTerrain::ValidRange(minValue,maxValue);         
     279        return new osgTerrain::ValidRange(minValue,maxValue); 
    280280    } 
    281281    else if (id==IVENODATAVALUE)