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

Ran script to remove trailing spaces and tabs

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/include/osg/Geometry

    r12064 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*/ 
     
    3333        /** Copy constructor using CopyOp to manage deep vs shallow copy. */ 
    3434        Geometry(const Geometry& geometry,const CopyOp& copyop=CopyOp::SHALLOW_COPY); 
    35              
     35 
    3636        virtual Object* cloneType() const { return new Geometry(); } 
    37         virtual Object* clone(const CopyOp& copyop) const { return new Geometry(*this,copyop); }         
     37        virtual Object* clone(const CopyOp& copyop) const { return new Geometry(*this,copyop); } 
    3838        virtual bool isSameKindAs(const Object* obj) const { return dynamic_cast<const Geometry*>(obj)!=NULL; } 
    3939        virtual const char* libraryName() const { return "osg"; } 
     
    5353            BIND_PER_VERTEX 
    5454        }; 
    55                 
     55 
    5656        struct OSG_EXPORT ArrayData 
    5757        { 
     
    5959                binding(BIND_OFF), 
    6060                normalize(GL_FALSE) {} 
    61                  
     61 
    6262            ArrayData(const ArrayData& data,const CopyOp& copyop=CopyOp::SHALLOW_COPY); 
    6363 
     
    8282                return *this; 
    8383            } 
    84              
    85             inline bool empty() const { return !array.valid(); }  
     84 
     85            inline bool empty() const { return !array.valid(); } 
    8686 
    8787            ref_ptr<Array>          array; 
     
    9090            GLboolean               normalize; 
    9191        }; 
    92          
     92 
    9393        struct OSG_EXPORT Vec3ArrayData 
    9494        { 
     
    9696                binding(BIND_OFF), 
    9797                normalize(GL_FALSE) {} 
    98                  
     98 
    9999            Vec3ArrayData(const Vec3ArrayData& data,const CopyOp& copyop=CopyOp::SHALLOW_COPY); 
    100100 
     
    120120            } 
    121121 
    122             inline bool empty() const { return !array.valid(); }  
     122            inline bool empty() const { return !array.valid(); } 
    123123 
    124124            ref_ptr<Vec3Array>      array; 
     
    128128        }; 
    129129 
    130         /** Static ArrayData which is returned from getTexCoordData(i) const and getVertexAttribData(i) const  
     130        /** Static ArrayData which is returned from getTexCoordData(i) const and getVertexAttribData(i) const 
    131131          * when i is out of range. 
    132132        */ 
    133133        static const ArrayData s_InvalidArrayData; 
    134          
     134 
    135135        typedef std::vector< ArrayData >  ArrayDataList; 
    136                 
     136 
    137137 
    138138        void setVertexArray(Array* array); 
     
    143143        ArrayData& getVertexData() { return _vertexData; } 
    144144        const ArrayData& getVertexData() const { return _vertexData; } 
    145          
     145 
    146146 
    147147        void setNormalBinding(AttributeBinding ab); 
     
    190190        ArrayData& getFogCoordData() { return _fogCoordData; } 
    191191        const ArrayData& getFogCoordData() const { return _fogCoordData; } 
    192          
     192 
    193193 
    194194        void setTexCoordArray(unsigned int unit,Array*); 
     
    229229 
    230230        void setPrimitiveSetList(const PrimitiveSetList& primitives); 
    231          
     231 
    232232        PrimitiveSetList& getPrimitiveSetList() { return _primitives; } 
    233233        const PrimitiveSetList& getPrimitiveSetList() const { return _primitives; } 
     
    236236        PrimitiveSet* getPrimitiveSet(unsigned int pos) { return _primitives[pos].get(); } 
    237237        const PrimitiveSet* getPrimitiveSet(unsigned int pos) const { return _primitives[pos].get(); } 
    238          
     238 
    239239        /** Add a primitive set to the geometry. */ 
    240240        bool addPrimitiveSet(PrimitiveSet* primitiveset); 
    241          
     241 
    242242        /** Set a primitive set to the specified position in geometry's primitive set list. */ 
    243243        bool setPrimitiveSet(unsigned int i,PrimitiveSet* primitiveset); 
    244          
     244 
    245245        /** Insert a primitive set to the specified position in geometry's primitive set list. */ 
    246246        bool insertPrimitiveSet(unsigned int i,PrimitiveSet* primitiveset); 
    247          
     247 
    248248        /** Remove primitive set(s) from the specified position in geometry's primitive set list. */ 
    249249        bool removePrimitiveSet(unsigned int i,unsigned int numElementsToRemove=1); 
     
    261261        IndexArray* getVertexIndices() { return _vertexData.indices.get(); } 
    262262        const IndexArray* getVertexIndices() const  { return _vertexData.indices.get(); } 
    263       
     263 
    264264        /** deprecated - forces OpenGL slow path, just kept for backwards compatibility.*/ 
    265265        void setNormalIndices(IndexArray* array); 
     
    295295 
    296296 
    297         /** When set to true, ignore the setUseDisplayList() settings, and hints to the drawImplementation  
     297        /** When set to true, ignore the setUseDisplayList() settings, and hints to the drawImplementation 
    298298            method to use OpenGL vertex buffer objects for rendering.*/ 
    299299        virtual void setUseVertexBufferObjects(bool flag); 
     
    359359 
    360360        bool containsSharedArrays() const; 
    361          
     361 
    362362        void duplicateSharedArrays(); 
    363          
     363 
    364364 
    365365        void computeInternalOptimizedGeometry(); 
     
    419419 
    420420        virtual ~Geometry(); 
    421         
     421 
    422422        bool verifyBindings(const ArrayData& arrayData) const; 
    423423        bool verifyBindings(const Vec3ArrayData& arrayData) const; 
    424          
     424 
    425425        void computeCorrectBindingsAndArraySizes(ArrayData& arrayData,const char* arrayName); 
    426426        void computeCorrectBindingsAndArraySizes(Vec3ArrayData& arrayData,const char* arrayName); 
    427          
     427 
    428428        void addVertexBufferObjectIfRequired(osg::Array* array); 
    429429        void addElementBufferObjectIfRequired(osg::PrimitiveSet* primitiveSet); 
    430          
     430 
    431431 
    432432        PrimitiveSetList                _primitives;