mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-11-22 14:56:13 +00:00
Changed: #825 Remove all warning when compiling Ryzom
This commit is contained in:
parent
42c3bf3ceb
commit
2fd533f737
10 changed files with 37 additions and 47 deletions
|
@ -45,7 +45,7 @@ struct IKeyboardDevice;
|
|||
struct IInputDeviceManager;
|
||||
class CRect;
|
||||
class CLog;
|
||||
};
|
||||
}
|
||||
|
||||
namespace NL3D
|
||||
{
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
namespace NLMISC
|
||||
{
|
||||
class IStream;
|
||||
};
|
||||
}
|
||||
|
||||
namespace NL3D {
|
||||
|
||||
|
|
|
@ -104,7 +104,7 @@ public:
|
|||
StaticPreferred, // The buffer will not be modified. A block of driver AGP or VRAM memory is allocated for this buffer. The buffer is writeonly.
|
||||
RAMVolatile, // A block of temporary driver RAM memory will be returned by lock(). The buffer must be entirely filled after each swapBuffers(). The buffer is writeonly.
|
||||
AGPVolatile, // A block of temporary driver AGP memory will be returned by lock(). The buffer must be entirely filled after each swapBuffers(). The buffer is writeonly.
|
||||
PreferredCount,
|
||||
PreferredCount
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -116,7 +116,7 @@ public:
|
|||
AGPResident,
|
||||
VRAMResident,
|
||||
NotResident,
|
||||
LocationCount,
|
||||
LocationCount
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -149,7 +149,7 @@ public:
|
|||
enum
|
||||
{
|
||||
FirstTexCoordValue = TexCoord0,
|
||||
LastTexCoordValue = TexCoord7,
|
||||
LastTexCoordValue = TexCoord7
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -172,7 +172,7 @@ public:
|
|||
WeightFlag = 1<<Weight,
|
||||
PaletteSkinFlag = (1<<PaletteSkin)|(1<<Weight),
|
||||
FogFlag = 1<<Fog,
|
||||
EmptyFlag = 1<<Empty,
|
||||
EmptyFlag = 1<<Empty
|
||||
};
|
||||
|
||||
|
||||
|
@ -207,7 +207,7 @@ public:
|
|||
MaxStage = 8,
|
||||
|
||||
// Max count of skinning weight
|
||||
MaxWeight = 4,
|
||||
MaxWeight = 4
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
@ -160,7 +160,7 @@ protected:
|
|||
};
|
||||
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
#endif // NL_DISPLAYER_H
|
||||
|
||||
|
|
|
@ -29,7 +29,6 @@
|
|||
using namespace NLMISC;
|
||||
using namespace std;
|
||||
|
||||
|
||||
namespace NL3D
|
||||
{
|
||||
|
||||
|
|
|
@ -162,20 +162,6 @@ extern "C"
|
|||
|
||||
#endif
|
||||
|
||||
/*
|
||||
static Bool WndProc(Display *d, XEvent *e, char *arg)
|
||||
{
|
||||
nlinfo("3D: glop %d %d", e->type, e->xmap.window);
|
||||
CDriverGL *pDriver = (CDriverGL*)arg;
|
||||
if (pDriver != NULL)
|
||||
{
|
||||
// Process the message by the emitter
|
||||
pDriver->_EventEmitter.processMessage();
|
||||
}
|
||||
// TODO i'don t know what to return exactly
|
||||
return (e->type == MapNotify) && (e->xmap.window == (Window) arg);
|
||||
}
|
||||
*/
|
||||
#endif // NL_OS_UNIX
|
||||
|
||||
GLenum CDriverGL::NLCubeFaceToGLCubeFace[6] =
|
||||
|
@ -866,12 +852,15 @@ bool CDriverGL::swapBuffers()
|
|||
}
|
||||
|
||||
#ifdef NL_OS_WINDOWS
|
||||
|
||||
SwapBuffers(_hDC);
|
||||
|
||||
#elif defined(NL_OS_MAC) && defined(NL_MAC_NATIVE)
|
||||
|
||||
NL3D::MAC::swapBuffers(_win);
|
||||
|
||||
#elif defined (NL_OS_UNIX)
|
||||
|
||||
glXSwapBuffers(_dpy, _win);
|
||||
|
||||
#endif // NL_OS_WINDOWS
|
||||
|
@ -1026,13 +1015,13 @@ void CDriverGL::setupViewport (const class CViewport& viewport)
|
|||
}
|
||||
|
||||
// Setup gl viewport
|
||||
int ix=(int)((float)clientWidth*x+0.5f);
|
||||
sint ix=(sint)((float)clientWidth*x+0.5f);
|
||||
clamp (ix, 0, clientWidth);
|
||||
int iy=(int)((float)clientHeight*y+0.5f);
|
||||
clamp (iy, 0, clientHeight);
|
||||
int iwidth=(int)((float)clientWidth*width+0.5f);
|
||||
sint iwidth=(sint)((float)clientWidth*width+0.5f);
|
||||
clamp (iwidth, 0, clientWidth-ix);
|
||||
int iheight=(int)((float)clientHeight*height+0.5f);
|
||||
sint iheight=(sint)((float)clientHeight*height+0.5f);
|
||||
clamp (iheight, 0, clientHeight-iy);
|
||||
glViewport (ix, iy, iwidth, iheight);
|
||||
}
|
||||
|
@ -1102,25 +1091,23 @@ void CDriverGL::setupScissor (const class CScissor& scissor)
|
|||
if(x==0 && x==0 && width>=1 && height>=1)
|
||||
{
|
||||
glDisable(GL_SCISSOR_TEST);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
// Setup gl scissor
|
||||
int ix0=(int)floor((float)clientWidth * x + 0.5f);
|
||||
sint ix0=(sint)floor((float)clientWidth * x + 0.5f);
|
||||
clamp (ix0, 0, clientWidth);
|
||||
int iy0=(int)floor((float)clientHeight* y + 0.5f);
|
||||
clamp (iy0, 0, clientHeight);
|
||||
|
||||
int ix1=(int)floor((float)clientWidth * (x+width) + 0.5f );
|
||||
sint ix1=(sint)floor((float)clientWidth * (x+width) + 0.5f );
|
||||
clamp (ix1, 0, clientWidth);
|
||||
int iy1=(int)floor((float)clientHeight* (y+height) + 0.5f );
|
||||
sint iy1=(sint)floor((float)clientHeight* (y+height) + 0.5f );
|
||||
clamp (iy1, 0, clientHeight);
|
||||
|
||||
|
||||
int iwidth= ix1 - ix0;
|
||||
sint iwidth= ix1 - ix0;
|
||||
clamp (iwidth, 0, clientWidth);
|
||||
int iheight= iy1 - iy0;
|
||||
sint iheight= iy1 - iy0;
|
||||
clamp (iheight, 0, clientHeight);
|
||||
|
||||
glScissor (ix0, iy0, iwidth, iheight);
|
||||
|
@ -1848,15 +1835,18 @@ uint loadARBFragmentProgramStringNative(const char *prog, bool forceNativeProgra
|
|||
nglBindProgramARB(GL_FRAGMENT_PROGRAM_ARB, 0);
|
||||
glGetIntegerv(GL_PROGRAM_ERROR_POSITION_ARB, &errorPos);
|
||||
nglGetProgramivARB(GL_FRAGMENT_PROGRAM_ARB, GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB, &isNative);
|
||||
if (errorPos == -1) {
|
||||
if (!isNative && forceNativePrograms) {
|
||||
if (errorPos == -1)
|
||||
{
|
||||
if (!isNative && forceNativePrograms)
|
||||
{
|
||||
nlwarning("Fragment program isn't supported natively; purging program");
|
||||
nglDeleteProgramsARB(1, &progID);
|
||||
return 0;
|
||||
}
|
||||
return progID;
|
||||
}
|
||||
else {
|
||||
else
|
||||
{
|
||||
nlwarning("init fragment program failed: errorPos: %d isNative: %d", errorPos, isNative);
|
||||
}
|
||||
return 0;
|
||||
|
|
|
@ -680,6 +680,7 @@ private:
|
|||
HPBUFFERARB _PBuffer;
|
||||
|
||||
#elif defined(NL_OS_MAC) && defined(NL_MAC_NATIVE)
|
||||
|
||||
NLMISC::CCocoaEventEmitter _EventEmitter;
|
||||
|
||||
#elif defined (NL_OS_UNIX)
|
||||
|
@ -809,7 +810,7 @@ private:
|
|||
TexEnvSpecialPPLStage0,
|
||||
TexEnvSpecialPPLStage2,
|
||||
TexEnvSpecialCloudStage0,
|
||||
TexEnvSpecialCloudStage1,
|
||||
TexEnvSpecialCloudStage1
|
||||
};
|
||||
|
||||
// NB: CRefPtr are not used for mem/spped optimisation. setupMaterial() and setupTexture() reset those states.
|
||||
|
|
|
@ -43,7 +43,7 @@ namespace BRICK_TYPE
|
|||
TIMED_ACTION,
|
||||
BRICK_TYPE_COUNT,
|
||||
BONUS,
|
||||
UNKNOWN,
|
||||
UNKNOWN
|
||||
};
|
||||
|
||||
|
||||
|
@ -61,7 +61,7 @@ namespace BRICK_TYPE
|
|||
*/
|
||||
const std::string &toString(EBrickType type);
|
||||
|
||||
}; // BRICK_TYPE
|
||||
} // BRICK_TYPE
|
||||
|
||||
#endif // RY_BRICK_TYPES_H
|
||||
/* End of brick_types.h */
|
||||
|
|
|
@ -799,7 +799,7 @@ namespace NPC_ICON
|
|||
};
|
||||
|
||||
const NLMISC::TGameCycle DefaultClientNPCIconRefreshTimerDelayGC = 60*10; // 1 min
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
#endif // RY_MSG_CLIENT_SERVER_H
|
||||
|
|
|
@ -50,14 +50,14 @@ namespace OUTPOSTENUMS
|
|||
PVE, // can only be attacked if the outpost is held by a tribe and if the attacking guild comes from the same continent as the outpost
|
||||
PVP, // can only be attacked if the attacking guild comes from the same continent as the outpost
|
||||
RVR, // can only be attacked if the attacking guild comes from another continent as the outpost
|
||||
Full, // same as RVR but cant be set by the high council
|
||||
Full // same as RVR but cant be set by the high council
|
||||
};
|
||||
|
||||
enum TPVPSide
|
||||
{
|
||||
OutpostOwner = 0,
|
||||
OutpostAttacker = 1,
|
||||
UnknownPVPSide,
|
||||
UnknownPVPSide
|
||||
};
|
||||
|
||||
// :NOTE: The outpost state machine is defined by a list of possible
|
||||
|
@ -78,7 +78,7 @@ namespace OUTPOSTENUMS
|
|||
AttackAfter,
|
||||
DefenseBefore, // the attack was successful. The attacker must now defend the outpost
|
||||
DefenseRound, // ...
|
||||
DefenseAfter,
|
||||
DefenseAfter
|
||||
};
|
||||
|
||||
/// events that can affect outpost state
|
||||
|
@ -107,7 +107,7 @@ namespace OUTPOSTENUMS
|
|||
UnknownSquadType,
|
||||
Default, // squad recruited automatically when the outpost is taken
|
||||
Recruited, // squad recruited by the guild
|
||||
Mercenary, // a special mercenary squad
|
||||
Mercenary // a special mercenary squad
|
||||
};
|
||||
|
||||
/// current state of a building used for database
|
||||
|
@ -115,7 +115,7 @@ namespace OUTPOSTENUMS
|
|||
{
|
||||
UnknownOutpostBuildingState,
|
||||
BuildingInPlace, // In place (constructed)
|
||||
BuildingConstructing, // Constructing
|
||||
BuildingConstructing // Constructing
|
||||
};
|
||||
|
||||
/// current state of a state
|
||||
|
@ -127,7 +127,7 @@ namespace OUTPOSTENUMS
|
|||
NotSpawned, // squad is ready and waiting to be spawned
|
||||
Spawning, // spawn order has been issued but not yet confirmed
|
||||
Spawned, // squad is spawned
|
||||
Dead, // squad is dead
|
||||
Dead // squad is dead
|
||||
};
|
||||
|
||||
/// events that can affect outpost state
|
||||
|
@ -142,7 +142,7 @@ namespace OUTPOSTENUMS
|
|||
GuildOwnershipEnd, // Owner of the outpost is no more a guild
|
||||
StateChanged, // State of outpost changed
|
||||
OwnerChanged, // Owner of outpost changed
|
||||
AttackerChanged, // Attacker of outpost changed
|
||||
AttackerChanged // Attacker of outpost changed
|
||||
};
|
||||
|
||||
std::string const& toString(TPVPType val);
|
||||
|
|
Loading…
Reference in a new issue