Changeset 9389
- Timestamp:
- 12/18/08 12:54:34 (4 years ago)
- Location:
- OpenSceneGraph/trunk/src
- Files:
-
- 10 modified
-
osgPlugins/dicom/ReaderWriterDICOM.cpp (modified) (5 diffs)
-
osgPlugins/gif/ReaderWriterGIF.cpp (modified) (5 diffs)
-
osgPlugins/osg/ImageSequence.cpp (modified) (1 diff)
-
osgPlugins/osg/StateAttribute.cpp (modified) (2 diffs)
-
osgPlugins/osg/StateSet.cpp (modified) (2 diffs)
-
osgPlugins/osg/Uniform.cpp (modified) (2 diffs)
-
osgPlugins/osgViewer/CompositeViewer.cpp (modified) (2 diffs)
-
osgPlugins/osgViewer/View.cpp (modified) (2 diffs)
-
osgPlugins/osgViewer/Viewer.cpp (modified) (2 diffs)
-
osgVolume/Brick.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
OpenSceneGraph/trunk/src/osgPlugins/dicom/ReaderWriterDICOM.cpp
r9099 r9389 236 236 237 237 void convertPixelTypes(const DiPixel* pixelData, 238 EP_Representation& pixelRep, unsignedint& numPlanes,238 EP_Representation& pixelRep, int& numPlanes, 239 239 GLenum& dataType, GLenum& pixelFormat, unsigned int& pixelSize) const 240 240 { … … 363 363 unsigned int imageNum = 0; 364 364 EP_Representation pixelRep; 365 unsignedint numPlanes = 0;365 int numPlanes = 0; 366 366 GLenum pixelFormat = 0; 367 367 GLenum dataType = 0; 368 368 unsigned int pixelSize = 0; 369 bool invertOrigiantion = false;370 369 371 370 typedef std::list<FileInfo> FileInfoList; … … 577 576 578 577 EP_Representation curr_pixelRep; 579 unsignedint curr_numPlanes;578 int curr_numPlanes; 580 579 GLenum curr_pixelFormat; 581 580 GLenum curr_dataType; … … 620 619 notice()<<"Image dimensions = "<<image->s()<<", "<<image->t()<<", "<<image->r()<<" pixelFormat=0x"<<std::hex<<pixelFormat<<" dataType=0x"<<std::hex<<dataType<<std::endl; 621 620 } 622 else if (pixelData->getPlanes()>numPlanes || pixelData->getRepresentation()>pixelRep) 621 else if (pixelData->getPlanes()>numPlanes || 622 pixelData->getRepresentation()>pixelRep) 623 623 { 624 624 notice()<<"Need to reallocated "<<image->s()<<", "<<image->t()<<", "<<image->r()<<std::endl; … … 697 697 numSlices = rhs.numSlices; 698 698 distance = rhs.distance; 699 700 return *this; 699 701 } 700 702 -
OpenSceneGraph/trunk/src/osgPlugins/gif/ReaderWriterGIF.cpp
r8578 r9389 65 65 { 66 66 public: 67 GifImageStream() 68 : _length(0), _dataNum(0), _frameNum(0), 69 _done(false), _currentLength(0), _multiplier(1.0), 70 osg::ImageStream() 67 GifImageStream() : 68 osg::ImageStream(), 69 _multiplier(1.0), 70 _currentLength(0), 71 _length(0), 72 _frameNum(0), 73 _dataNum(0), 74 _done(false) 71 75 { 72 76 _status=PAUSED; 73 77 } 78 74 79 virtual Object* clone() const { return new GifImageStream; } 75 80 virtual bool isSameKindAs( const Object* obj ) const … … 183 188 } 184 189 185 _s = ss; 186 _t = tt; 187 _r = rr; 188 _internalFormat = numComponents; 189 _dataType = GL_UNSIGNED_BYTE; 190 191 _pixelFormat = 190 GLint internalFormat = numComponents; 191 GLenum dataType = GL_UNSIGNED_BYTE; 192 193 GLenum pixelFormat = 192 194 numComponents == 1 ? GL_LUMINANCE : 193 195 numComponents == 2 ? GL_LUMINANCE_ALPHA : … … 198 200 { 199 201 // Set image texture for the first time 200 setImage( _s,_t,_r,_internalFormat,_pixelFormat,_dataType,202 setImage(ss, tt, rr, internalFormat, pixelFormat, dataType, 201 203 imgData,osg::Image::NO_DELETE,1); 202 204 } … … 223 225 { 224 226 unsigned char* image = (*_dataIter)->data; 225 setImage(_s,_t,_r,_internal Format,_pixelFormat,_dataType,227 setImage(_s,_t,_r,_internalTextureFormat,_pixelFormat,_dataType, 226 228 image,osg::Image::NO_DELETE,1); 227 229 dirty(); … … 242 244 } 243 245 244 double _multiplier;245 unsigned int _currentLength;246 unsigned int _length;247 248 unsigned int _frameNum;249 unsigned int _dataNum;246 double _multiplier; 247 unsigned int _currentLength; 248 unsigned int _length; 249 250 unsigned int _frameNum; 251 unsigned int _dataNum; 250 252 std::vector<FrameData*> _dataList; 251 253 std::vector<FrameData*>::iterator _dataIter; 252 253 int _s;254 int _t;255 int _r;256 int _internalFormat;257 unsigned int _pixelFormat;258 unsigned int _dataType;259 254 260 255 bool _done; -
OpenSceneGraph/trunk/src/osgPlugins/osg/ImageSequence.cpp
r9334 r9389 27 27 28 28 ImageSequence& is = static_cast<ImageSequence&>(obj); 29 30 unsigned int numFilesToPreLoad = 1;31 32 29 33 30 std::string modeStr; -
OpenSceneGraph/trunk/src/osgPlugins/osg/StateAttribute.cpp
r9334 r9389 33 33 while (fr.matchSequence("UpdateCallback {")) 34 34 { 35 int entry = fr[0].getNoNestedBrackets();35 //int entry = fr[0].getNoNestedBrackets(); 36 36 fr += 2; 37 37 StateAttribute::Callback* callback = dynamic_cast<StateAttribute::Callback*>(fr.readObjectOfType(*s_callback)); … … 44 44 while (fr.matchSequence("EventCallback {")) 45 45 { 46 int entry = fr[0].getNoNestedBrackets();46 //int entry = fr[0].getNoNestedBrackets(); 47 47 fr += 2; 48 48 StateAttribute::Callback* callback = dynamic_cast<StateAttribute::Callback*>(fr.readObjectOfType(*s_callback)); -
OpenSceneGraph/trunk/src/osgPlugins/osg/StateSet.cpp
r9343 r9389 338 338 while (fr.matchSequence("UpdateCallback {")) 339 339 { 340 int entry = fr[0].getNoNestedBrackets();340 // int entry = fr[0].getNoNestedBrackets(); 341 341 fr += 2; 342 342 StateSet::Callback* callback = dynamic_cast<StateSet::Callback*>(fr.readObjectOfType(*s_callback)); … … 349 349 while (fr.matchSequence("EventCallback {")) 350 350 { 351 int entry = fr[0].getNoNestedBrackets();351 //int entry = fr[0].getNoNestedBrackets(); 352 352 fr += 2; 353 353 StateSet::Callback* callback = dynamic_cast<StateSet::Callback*>(fr.readObjectOfType(*s_callback)); -
OpenSceneGraph/trunk/src/osgPlugins/osg/Uniform.cpp
r9334 r9389 213 213 while (fr.matchSequence("UpdateCallback {")) 214 214 { 215 int entry = fr[0].getNoNestedBrackets();215 //int entry = fr[0].getNoNestedBrackets(); 216 216 fr += 2; 217 217 Uniform::Callback* callback = dynamic_cast<Uniform::Callback*>(fr.readObjectOfType(*s_callback)); … … 224 224 while (fr.matchSequence("EventCallback {")) 225 225 { 226 int entry = fr[0].getNoNestedBrackets();226 //int entry = fr[0].getNoNestedBrackets(); 227 227 fr += 2; 228 228 Uniform::Callback* callback = dynamic_cast<Uniform::Callback*>(fr.readObjectOfType(*s_callback)); -
OpenSceneGraph/trunk/src/osgPlugins/osgViewer/CompositeViewer.cpp
r7506 r9389 21 21 ); 22 22 23 bool CompositeViewer_readLocalData(osg::Object &obj, osgDB::Input &fr)23 bool CompositeViewer_readLocalData(osg::Object& /*obj*/, osgDB::Input& /*fr*/) 24 24 { 25 osgViewer::CompositeViewer* compositeViewer = dynamic_cast<osgViewer::CompositeViewer*>(&obj);25 // osgViewer::CompositeViewer* compositeViewer = dynamic_cast<osgViewer::CompositeViewer*>(&obj); 26 26 bool iteratorAdvanced = false; 27 27 … … 31 31 } 32 32 33 bool CompositeViewer_writeLocalData(const osg::Object &obj, osgDB::Output &fw)33 bool CompositeViewer_writeLocalData(const osg::Object& /*obj*/, osgDB::Output& /*fw*/) 34 34 { 35 const osgViewer::CompositeViewer* compositeViewer = dynamic_cast<const osgViewer::CompositeViewer*>(&obj);35 // const osgViewer::CompositeViewer* compositeViewer = dynamic_cast<const osgViewer::CompositeViewer*>(&obj); 36 36 37 37 osg::notify(osg::NOTICE)<<"CompositeViewer_writeLocalData"<<std::endl; -
OpenSceneGraph/trunk/src/osgPlugins/osgViewer/View.cpp
r7838 r9389 57 57 } 58 58 59 59 #if 0 60 60 static bool writeMatrix(const osg::Matrix& matrix, osgDB::Output& fw, const char* keyword) 61 61 { … … 70 70 return true; 71 71 } 72 #endif 72 73 73 74 osg::Image* readIntensityImage(osgDB::Input& fr, bool& itrAdvanced) -
OpenSceneGraph/trunk/src/osgPlugins/osgViewer/Viewer.cpp
r7506 r9389 21 21 ); 22 22 23 bool Viewer_readLocalData(osg::Object &obj, osgDB::Input &fr)23 bool Viewer_readLocalData(osg::Object& /*obj*/, osgDB::Input& /*fr*/) 24 24 { 25 osgViewer::Viewer* viewer = dynamic_cast<osgViewer::Viewer*>(&obj);25 // osgViewer::Viewer* viewer = dynamic_cast<osgViewer::Viewer*>(&obj); 26 26 bool iteratorAdvanced = false; 27 27 … … 29 29 } 30 30 31 bool Viewer_writeLocalData(const osg::Object &obj, osgDB::Output &fw)31 bool Viewer_writeLocalData(const osg::Object& /*obj*/, osgDB::Output& /*fw*/) 32 32 { 33 const osgViewer::Viewer* viewer = dynamic_cast<const osgViewer::Viewer*>(&obj);33 // const osgViewer::Viewer* viewer = dynamic_cast<const osgViewer::Viewer*>(&obj); 34 34 return true; 35 35 } -
OpenSceneGraph/trunk/src/osgVolume/Brick.cpp
r8908 r9389 25 25 Brick::Brick(): 26 26 _volume(0), 27 _ hasBeenTraversal(false),28 _ dirty(false)27 _dirty(false), 28 _hasBeenTraversal(false) 29 29 { 30 30 setThreadSafeRefUnref(true); … … 34 34 Group(brick,copyop), 35 35 _volume(0), 36 _dirty(false), 36 37 _hasBeenTraversal(false), 37 _image(brick._image), 38 _dirty(false) 38 _image(brick._image) 39 39 { 40 40 if (brick.getVolumeTechnique())
