Show
Ignore:
Timestamp:
04/01/15 11:37:53 (16 hours ago)
Author:
robert
Message:

From Lionel Largarde, "fix for the Image::computeNumberOfMipmapLevels method. The method did use the float version of the log function and the / operator.
It works for most of the input sizes, but fails for 8192, 32768...
For 8192, the method returns 13 instead of 14."

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/src/osgShadow/ShadowSettings.cpp

    r13108 r13110  
    1313 
    1414#include <osgShadow/ShadowSettings> 
     15#include <float.h> 
    1516 
    1617using namespace osgShadow; 
     
    2526    _textureSize(2048,2048), 
    2627    _minimumShadowMapNearFarRatio(0.05), 
     28    _maximumShadowMapDistance(DBL_MAX), 
    2729    _shadowMapProjectionHint(PERSPECTIVE_SHADOW_MAP), 
    2830    _perspectiveShadowMapCutOffAngle(2.0), 
     
    4749    _textureSize(ss._textureSize), 
    4850    _minimumShadowMapNearFarRatio(ss._minimumShadowMapNearFarRatio), 
     51    _maximumShadowMapDistance(ss._maximumShadowMapDistance), 
    4952    _shadowMapProjectionHint(ss._shadowMapProjectionHint), 
    5053    _perspectiveShadowMapCutOffAngle(ss._perspectiveShadowMapCutOffAngle),