Hi Giuseppe, Thanks for the file, this makes it nice and clear what change was required.
I just tried out osgvolume's write out feature and it fails before applying your change but works once your change has been applied. This bug is clearly a regression that crept in when other parts of the DDS plugin were refactored handle problems in sizes in other types of usages. I have merged your fix with svn/trunk and OSG-3.2 branch. Cheers, Robert. On 10 September 2013 15:52, Giuseppe Donvito <[email protected]>wrote: > Sure, here it is. > thanks, > Giuseppe > > > On Tue, Sep 10, 2013 at 3:15 PM, Robert Osfield > <[email protected]>wrote: > >> Hi Giuseppe, >> >> Could you post the whole modified file? >> >> Cheers, >> Robert. >> >> >> On 10 September 2013 11:13, Giuseppe Donvito >> <[email protected]>wrote: >> >>> Hi, >>> I'm using OSG 320 and I need to flush a DDS 3D texture on disk. >>> I found a bug on DDS ReaderWriter that generates a false positive on a >>> guard for the size check on writing operation. This is due to a wrong >>> imageSize computation that uses img->getImageSizeInBytes() method instead >>> of img->getTotalSizeInBytes(), that actually ignores the r() dimension, >>> contrariwise taken into account by the function ComputeImageSizeInBytes() >>> later. >>> >>> The line 1062 on file ReaderWriterDDS.cpp should be fixed with: >>> [code]unsigned int imageSize = img->getTotalSizeInBytes();[/code] >>> >>> This fix could be also applied as is to the trunk. >>> >>> Cheers, >>> Giuseppe >>> >>> _______________________________________________ >>> osg-submissions mailing list >>> [email protected] >>> >>> http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org >>> >>> >> >> _______________________________________________ >> osg-submissions mailing list >> [email protected] >> >> http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org >> >> > > _______________________________________________ > osg-submissions mailing list > [email protected] > > http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org > >
_______________________________________________ osg-submissions mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
