diff options
| author | Graham Linden <graham@lindenlab.com> | 2018-06-01 15:34:21 +0100 | 
|---|---|---|
| committer | Graham Linden <graham@lindenlab.com> | 2018-06-01 15:34:21 +0100 | 
| commit | 37e8fd20c3823482f3a15b4bfd544f7847070db8 (patch) | |
| tree | b31e3a1ef86431cda7703621f779b38a98c14a3e /indra/llmath | |
| parent | 64302d3000b69b31e72eb6a3bd8a981c80cb88de (diff) | |
| parent | bd84cbfa11fbe2b3aa5ceba5978841310488b8e4 (diff) | |
Merge to 5.1.6
Diffstat (limited to 'indra/llmath')
| -rw-r--r-- | indra/llmath/llvolume.cpp | 7 | ||||
| -rw-r--r-- | indra/llmath/llvolume.h | 2 | 
2 files changed, 5 insertions, 4 deletions
| diff --git a/indra/llmath/llvolume.cpp b/indra/llmath/llvolume.cpp index 14b0f350b9..b1d1b9a3e8 100644 --- a/indra/llmath/llvolume.cpp +++ b/indra/llmath/llvolume.cpp @@ -545,7 +545,7 @@ void LLProfile::genNGon(const LLProfileParams& params, S32 sides, F32 offset, F3  {  	// Generate an n-sided "circular" path.  	// 0 is (1,0), and we go counter-clockwise along a circular path from there. -	const F32 tableScale[] = { 1, 1, 1, 0.5f, 0.707107f, 0.53f, 0.525f, 0.5f }; +	static const F32 tableScale[] = { 1, 1, 1, 0.5f, 0.707107f, 0.53f, 0.525f, 0.5f };  	F32 scale = 0.5f;  	F32 t, t_step, t_first, t_fraction, ang, ang_step;  	LLVector4a pt1,pt2; @@ -1304,7 +1304,7 @@ S32 LLPath::getNumNGonPoints(const LLPathParams& params, S32 sides, F32 startOff  void LLPath::genNGon(const LLPathParams& params, S32 sides, F32 startOff, F32 end_scale, F32 twist_scale)  {  	// Generates a circular path, starting at (1, 0, 0), counterclockwise along the xz plane. -	const F32 tableScale[] = { 1, 1, 1, 0.5f, 0.707107f, 0.53f, 0.525f, 0.5f }; +	static const F32 tableScale[] = { 1, 1, 1, 0.5f, 0.707107f, 0.53f, 0.525f, 0.5f };  	F32 revolutions = params.getRevolutions();  	F32 skew		= params.getSkew(); @@ -1602,7 +1602,8 @@ BOOL LLPath::generate(const LLPathParams& params, F32 detail, S32 split,  			if (is_sculpted)  				sides = llmax(sculpt_size, 1); -			genNGon(params, sides); +			if (0 < sides) +				genNGon(params, sides);  		}  		break; diff --git a/indra/llmath/llvolume.h b/indra/llmath/llvolume.h index 4357b69b90..d3c1ac46fe 100644 --- a/indra/llmath/llvolume.h +++ b/indra/llmath/llvolume.h @@ -1089,7 +1089,7 @@ public:  	F32 mSurfaceArea; //unscaled surface area  	BOOL mIsMeshAssetLoaded; -	LLVolumeParams mParams; +	const LLVolumeParams mParams;  	LLPath *mPathp;  	LLProfile *mProfilep;  	LLAlignedArray<LLVector4a,64> mMesh; | 
