fixesForXCode4.3.2.diff

GelluleX, 03/31/2012 03:48 am

Download (13.1 kB)

b/code/CMakeModules/nel.cmake Fri Mar 30 15:23:55 2012 -1000
463 463
    ENDIF(NOT APPLE)
464 464

465 465
    SET(NL_DEBUG_CFLAGS "-DNL_DEBUG -D_DEBUG")
466
    SET(NL_RELEASE_CFLAGS "-DNL_RELEASE -DNDEBUG -O6")
466
    SET(NL_RELEASE_CFLAGS "-DNL_RELEASE -DNDEBUG -O3")
467 467
  ENDIF(MSVC)
468 468
ENDMACRO(NL_SETUP_BUILD)
469 469

b/code/nel/include/nel/3d/computed_string.h Fri Mar 30 15:23:55 2012 -1000
32 32
namespace NL3D {
33 33

34 34
class CTextureFont;
35
class CMatrix;
35
class NLMISC::CMatrix;
36 36
struct CComputedString;
37 37

38 38
// ***************************************************************************
......
286 286
	 * \param matrix transformation matrix
287 287
	 * \param hotspot position of string origine
288 288
	 */
289
	void render3D (IDriver& driver,CMatrix matrix,THotSpot hotspot = MiddleMiddle);
289
	void render3D (IDriver& driver,NLMISC::CMatrix matrix,THotSpot hotspot = MiddleMiddle);
290 290

291 291
};
292 292

b/code/nel/include/nel/3d/cube_grid.h Fri Mar 30 15:23:55 2012 -1000
227 227
		// build the _StaticGrid
228 228
		_StaticGrids[i].build(_Grids[i]);
229 229
		// And reset the grid. contReset is necessary to clean the CBlockMemory.
230
		contReset(_Grids[i]);
230
		NLMISC::contReset(_Grids[i]);
231 231
	}
232 232

233 233
	// done
b/code/nel/include/nel/3d/ps_attrib.h Fri Mar 30 15:23:55 2012 -1000
96 96
		try
97 97
		{
98 98
			newStart = new uint8[sizeof(T) * capacity + (1 << snapPower)];
99
			T *newTab = (T *) ( (uint) (newStart + (1 << snapPower))  & ~((1 << snapPower) - 1)); // snap to a page
99
			T *newTab = (T *) ( (uintptr_t) (newStart + (1 << snapPower))  & ~((1 << snapPower) - 1)); // snap to a page
100 100

101 101

102 102

b/code/nel/include/nel/3d/static_quad_grid.h Fri Mar 30 15:23:55 2012 -1000
172 172
void			CStaticQuadGrid<T>::build(CQuadGrid<T> &quadGrid)
173 173
{
174 174
	clear();
175
	contReset(_Grid);
175
	NLMISC::contReset(_Grid);
176 176

177 177
	// Copy from quadGrid, and init quads
178 178
	_Size= quadGrid.getSize();
b/code/nel/include/nel/3d/track_tcb.h Fri Mar 30 15:23:55 2012 -1000
218 218
			date*= previous->OODeltaTime;
219 219
			NLMISC::clamp(date, 0,1);
220 220

221
			date = ease(previous, date);
221
			date = this->ease(previous, date);
222 222

223 223
			float hb[4];
224 224
			this->computeHermiteBasis(date, hb);
......
242 242
		ITrackKeyFramer<CKeyT>::compile();
243 243

244 244
		// Ease Precompute.
245
		compileTCBEase(this->_MapKey, this->getLoopMode());
245
		this->compileTCBEase(this->_MapKey, this->getLoopMode());
246 246

247 247

248 248
		// Tangents Precompute.
......
256 256

257 257
		if(nKeys==2 && !this->getLoopMode())
258 258
		{
259
			computeTCBKeyLinear( it->second, itNext->second );
259
			this->computeTCBKeyLinear( it->second, itNext->second );
260 260
		}
261 261
		else
262 262
		{
......
273 273
				// NB: we are the last if itNext==_MapKey.begin().
274 274
				if(this->getLoopMode() || (it!=this->_MapKey.begin() && itNext!=this->_MapKey.begin()) )
275 275
				{
276
					computeTCBKey(itPrev->second, it->second, itNext->second,
276
					this->computeTCBKey(itPrev->second, it->second, itNext->second,
277 277
						itPrev->first, it->first, itNext->first, rangeDelta,
278 278
						it==this->_MapKey.begin(), itNext==this->_MapKey.begin(), this->getLoopMode());
279 279
				}
......
314 314
		float	ksm,ksp,kdm,kdp;
315 315

316 316
		// compute tangents factors.
317
		computeTCBFactors(key, timeBefore, time, timeAfter, rangeDelta, firstKey, endKey, isLoop, ksm,ksp,kdm,kdp);
317
		this->computeTCBFactors(key, timeBefore, time, timeAfter, rangeDelta, firstKey, endKey, isLoop, ksm,ksp,kdm,kdp);
318 318

319 319
		// Delta.
320 320
		TKeyValueType	delm, delp;
......
391 391
			NLMISC::clamp(date, 0,1);
392 392

393 393
			// ease.
394
			date = ease(previous, date);
394
			date = this->ease(previous, date);
395 395

396 396
			// quad slerp.
397 397
			resultVal.Value= CQuat::squadrev(next->LocalAngleAxis, previous->Quat, previous->A, next->B, next->Quat, date);
......
413 413
		ITrackKeyFramer<CKeyTCBQuat>::compile();
414 414

415 415
		// Ease Precompute.
416
		compileTCBEase(_MapKey, getLoopMode());
416
		this->compileTCBEase(_MapKey, getLoopMode());
417 417

418 418
		TMapTimeCKey::iterator	it;
419 419
		TMapTimeCKey::iterator	itNext;
......
476 476
		for(;it!=_MapKey.end();)
477 477
		{
478 478
			// NB: we are the last key if itNext==_MapKey.begin().
479
			computeTCBKey(itPrev->second, it->second, itNext->second,
479
			this->computeTCBKey(itPrev->second, it->second, itNext->second,
480 480
				itPrev->first, it->first, itNext->first, rangeDelta, it==_MapKey.begin(), itNext==_MapKey.begin(), getLoopMode());
481 481

482 482
			// Next key!!
b/code/nel/include/nel/misc/diff_tool.h Fri Mar 30 15:23:55 2012 -1000
502 502
//						callback->onSwap(it - context.Reference.begin(), refCount, context);
503 503
						callback->onSwap(index, refCount, context);
504 504
//						swap(*it, context.Reference[refCount]);
505
						swap(context.Reference[index], context.Reference[refCount]);
505
						std::swap(context.Reference[index], context.Reference[refCount]);
506 506
					}
507 507
				}
508 508
				else if (getHashValue(context.Addition, addCount) != getHashValue(context.Reference, refCount))
b/code/nel/src/3d/computed_string.cpp Fri Mar 30 15:23:55 2012 -1000
95 95
	CVector hotspotVector = getHotSpotVector(hotspot);
96 96

97 97
	// transformation matrix initialized to identity
98
	CMatrix matrix;
98
	NL3D::CMatrix matrix;
99 99
	matrix.identity();
100 100

101 101
	// view matrix <-> identity
b/code/ryzom/client/src/cdb.h Fri Mar 30 15:23:55 2012 -1000
186 186

187 187
//-----------------------------------------------------------------------
188 188
// IDBNode interface definition
189

189
protected:
190
	
191
	/// Atomic flag: is the branch an atomic group, or is the leaf a member of an atomic group
192
	bool			_AtomicFlag;
193
		
190 194
public :
191 195

192 196
	/**
......
302 306
	virtual CCDBNodeLeaf	*findLeafAtCount( uint& count ) = 0;
303 307

304 308
	/// Set the atomic branch flag (when all the modified nodes of a branch should be tranmitted at the same time)
305
	void					setAtomic( bool atomicBranch ) { _Atomic = atomicBranch; }
309
	void					setAtomic( bool atomicBranch ) { _AtomicFlag = atomicBranch; }
306 310

307 311
	/// Return true if the branch has the atomic flag
308
	bool					isAtomic() const { return _Atomic; }
312
	bool					isAtomic() const { return _AtomicFlag; }
309 313

310 314
	// test if the node is a leaf
311 315
	virtual bool			isLeaf() const = 0;
......
333 337
protected:
334 338

335 339
	/// Constructor
336
	ICDBNode() : _Atomic(false)
340
	ICDBNode() : _AtomicFlag(false)
337 341
	{
338 342
		if (_DBSM == NULL) _DBSM = NLMISC::CStringMapper::createLocalMapper();
339 343
		_Name = NLMISC::CStringMapper::emptyId();
340 344
	}
341 345

342 346
	/// Constructor
343
	ICDBNode (const std::string &name) : _Atomic(false)
347
	ICDBNode (const std::string &name) : _AtomicFlag(false)
344 348
	{
345 349
		if (_DBSM == NULL) _DBSM = NLMISC::CStringMapper::createLocalMapper();
346 350
		_Name = _DBSM->localMap(name);
......
350 354
	// utility to build full name efficiently (without reallocating the string at each parent level)
351 355
	void _buildFullName(NLMISC::CSString &fullName);
352 356

353
	/// Atomic flag: is the branch an atomic group, or is the leaf a member of an atomic group
354
	bool			_Atomic		: 1;
355

356 357
	/// Name of the node
357 358
	NLMISC::TStringId	_Name;
358 359
	//std::string _NameDbg;
b/code/ryzom/client/src/r2/config_var.h Fri Mar 30 15:23:55 2012 -1000
40 40
	static uint32 &getConfigFileTimeStamp();
41 41
};
42 42

43
//////////////////////
44
// Specialisations  //
45
//////////////////////
46

47
//------------------------------------------------------------------------------------------------
48
// Float
49
inline std::string getConfigVarTypename(const float &/* dummy */) { return "float"; }
50
inline bool getConfigVarValue(CLuaObject &luaValue, float &dest)
51
{
52
	if (luaValue.isNumber())
53
	{
54
		dest = (float) luaValue.toNumber();
55
		return true;
56
	}
57
	return false;
58
}
59

60
//------------------------------------------------------------------------------------------------
61
// Double
62
inline std::string getConfigVarTypename(const double &/* dummy */) { return "float"; }
63
inline bool getConfigVarValue(CLuaObject &luaValue, double &dest)
64
{
65
	if (luaValue.isNumber())
66
	{
67
		dest = luaValue.toNumber();
68
		return true;
69
	}
70
	return false;
71
}
72

73
//------------------------------------------------------------------------------------------------
74
// sint32
75
inline std::string getConfigVarTypename(const sint32 &/* dummy */) { return "sint32"; }
76
inline bool getConfigVarValue(CLuaObject &luaValue, sint32 &dest)
77
{
78
	if (luaValue.isNumber())
79
	{
80
		dest = (sint32) luaValue.toNumber();
81
		return true;
82
	}
83
	return false;
84
}
85

86

87
//------------------------------------------------------------------------------------------------
88
// String
89
inline std::string getConfigVarTypename(const std::string &/* dummy */) { return "string"; }
90
inline bool getConfigVarValue(CLuaObject &luaValue, std::string &dest)
91
{
92
	if (luaValue.isString())
93
	{
94
		dest = luaValue.toString();
95
		return true;
96
	}
97
	return false;
98
}
99

100
//------------------------------------------------------------------------------------------------
101
// RGBA
102
inline std::string getConfigVarTypename(const NLMISC::CRGBA &/* dummy */) { return "rgba"; }
103
inline bool getConfigVarValue(CLuaObject &luaValue, NLMISC::CRGBA &dest)
104
{
105
	if (luaValue.isRGBA())
106
	{
107
		dest = luaValue.toRGBA();
108
		return true;
109
	}
110
	return false;
111
}
43 112

44 113

45 114
/** Quick access to variables defined inside r2_config.lua.
......
91 160
	return _Value;
92 161
};
93 162

94
//////////////////////
95
// Specialisations  //
96
//////////////////////
97

98
//------------------------------------------------------------------------------------------------
99
// Float
100
inline std::string getConfigVarTypename(const float &/* dummy */) { return "float"; }
101
inline bool getConfigVarValue(CLuaObject &luaValue, float &dest)
102
{
103
	if (luaValue.isNumber())
104
	{
105
		dest = (float) luaValue.toNumber();
106
		return true;
107
	}
108
	return false;
109
}
110 163
typedef CConfigVar<float> CConfigVarFloat;
111

112
//------------------------------------------------------------------------------------------------
113
// Double
114
inline std::string getConfigVarTypename(const double &/* dummy */) { return "float"; }
115
inline bool getConfigVarValue(CLuaObject &luaValue, double &dest)
116
{
117
	if (luaValue.isNumber())
118
	{
119
		dest = luaValue.toNumber();
120
		return true;
121
	}
122
	return false;
123
}
124 164
typedef CConfigVar<double> CConfigVarDouble;
125

126
//------------------------------------------------------------------------------------------------
127
// sint32
128
inline std::string getConfigVarTypename(const sint32 &/* dummy */) { return "sint32"; }
129
inline bool getConfigVarValue(CLuaObject &luaValue, sint32 &dest)
130
{
131
	if (luaValue.isNumber())
132
	{
133
		dest = (sint32) luaValue.toNumber();
134
		return true;
135
	}
136
	return false;
137
}
138 165
typedef CConfigVar<sint32> CConfigVarSInt32;
139

140

141
//------------------------------------------------------------------------------------------------
142
// String
143
inline std::string getConfigVarTypename(const std::string &/* dummy */) { return "string"; }
144
inline bool getConfigVarValue(CLuaObject &luaValue, std::string &dest)
145
{
146
	if (luaValue.isString())
147
	{
148
		dest = luaValue.toString();
149
		return true;
150
	}
151
	return false;
152
}
153 166
typedef CConfigVar<std::string> CConfigVarString;
154

155
//------------------------------------------------------------------------------------------------
156
// RGBA
157
inline std::string getConfigVarTypename(const NLMISC::CRGBA &/* dummy */) { return "rgba"; }
158
inline bool getConfigVarValue(CLuaObject &luaValue, NLMISC::CRGBA &dest)
159
{
160
	if (luaValue.isRGBA())
161
	{
162
		dest = luaValue.toRGBA();
163
		return true;
164
	}
165
	return false;
166
}
167 167
typedef CConfigVar<NLMISC::CRGBA> CConfigVarRGBA;
168 168

169 169
} // R2
b/code/ryzom/common/src/game_share/mirror_prop_value_inline.h Fri Mar 30 15:23:55 2012 -1000
1005 1005
	if ( _InMirror )
1006 1006
		return CMirrorPropValue<T,CPropLocationClass>::getWriterServiceId();
1007 1007
	else
1008
		return ~0;
1008
		return NLNET::TServiceId8(~0);
1009 1009
}
1010 1010
#endif
1011 1011