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/osgSim/ImpostorSprite

    r12056 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*/ 
     
    4545        virtual osg::Object* cloneType() const { return new ImpostorSprite(); } 
    4646 
    47         /** Clone on ImpostorSprite just returns a clone of type,  
     47        /** Clone on ImpostorSprite just returns a clone of type, 
    4848          * since it is not appropriate to share data of an ImpostorSprite. 
    4949        */ 
     
    5353        virtual const char* className() const { return "ImpostorSprite"; } 
    5454 
    55         /** Set the parent, which must be an Impostor.  
     55        /** Set the parent, which must be an Impostor. 
    5656          * Unlike conventional Drawables, ImpostorSprites can only ever have 
    5757          * one parent. 
     
    7070        /** Get the eye point for when the ImpostorSprite was snapped. */ 
    7171        inline const osg::Vec3& getStoredLocalEyePoint() const { return _storedLocalEyePoint; } 
    72          
     72 
    7373        /** Set the frame number for when the ImpostorSprite was last used in rendering. */ 
    7474        inline void setLastFrameUsed(unsigned int frameNumber) { _lastFrameUsed = frameNumber; } 
    75          
     75 
    7676        /** Get the frame number for when the ImpostorSprite was last used in rendering. */ 
    7777        inline unsigned int getLastFrameUsed() const { return _lastFrameUsed; } 
    78          
     78 
    7979 
    8080        /** Get the coordinates of the corners of the quad. 
     
    8282        */ 
    8383        inline osg::Vec3* getCoords() { return _coords; } 
    84          
     84 
    8585        /** Get the const coordinates of the corners of the quad. */ 
    8686        inline const osg::Vec3* getCoords() const { return _coords; } 
     
    9292        */ 
    9393        inline osg::Vec2* getTexCoords() { return _texcoords; } 
    94          
     94 
    9595        /** Get the const texture coordinates of the corners of the quad. */ 
    9696        inline const osg::Vec2* getTexCoords() const { return _texcoords; } 
     
    109109        */ 
    110110        inline osg::Vec3* getControlCoords() { return _controlcoords; } 
    111          
     111 
    112112        /** Get the const control coordinates of the corners of the quad. */ 
    113113        inline const osg::Vec3* getControlCoords() const { return _controlcoords; } 
     
    122122        osg::Texture2D* getTexture() { return _texture; } 
    123123        const osg::Texture2D* getTexture() const { return _texture; } 
    124      
     124 
    125125        int s() const { return _s; } 
    126126        int t() const { return _t; } 
     
    151151 
    152152        virtual osg::BoundingBox computeBound() const; 
    153          
     153 
    154154        /** Set the camera node to use for pre rendering the impostor sprite's texture.*/ 
    155155        void setCamera(osg::Camera* camera) { _camera = camera; } 
     
    171171 
    172172        friend class osgSim::ImpostorSpriteManager; 
    173          
     173 
    174174        // camera node for doing the pre rendering. 
    175175        osg::ref_ptr<osg::Camera> _camera; 
     
    180180        ImpostorSprite*         _previous; 
    181181        ImpostorSprite*         _next; 
    182          
     182 
    183183        unsigned int _lastFrameUsed; 
    184184 
    185185        osg::Vec3 _storedLocalEyePoint; 
    186          
     186 
    187187        osg::Vec3 _coords[4]; 
    188188        osg::Vec2 _texcoords[4]; 
    189189        osg::Vec3 _controlcoords[4]; 
    190          
     190 
    191191        osg::Texture2D* _texture; 
    192192        int _s; 
    193193        int _t; 
    194          
    195          
     194 
     195 
    196196}; 
    197197 
     
    200200{ 
    201201    public: 
    202      
     202 
    203203        ImpostorSpriteManager(); 
    204          
     204 
    205205        bool empty() const { return _first==0; } 
    206206 
    207207        ImpostorSprite* first() { return _first; } 
    208          
     208 
    209209        ImpostorSprite* last() { return _last; } 
    210          
     210 
    211211        void push_back(ImpostorSprite* is); 
    212          
     212 
    213213        void remove(ImpostorSprite* is); 
    214          
     214 
    215215        ImpostorSprite* createOrReuseImpostorSprite(int s,int t,unsigned int frameNumber); 
    216216 
     
    218218 
    219219        void reset(); 
    220      
     220 
    221221    protected: 
    222222 
     
    229229        ImpostorSprite*                 _first; 
    230230        ImpostorSprite*                 _last; 
    231          
     231 
    232232        typedef std::vector< osg::ref_ptr<osg::StateSet> > StateSetList; 
    233233        StateSetList                    _stateSetList;