Browse Source

Merge neko/mathlib into master

pull/2/head
Alibek Omarov 5 years ago
parent
commit
3c8ce640c4
  1. 2
      engine/client/cl_efrag.c
  2. 2
      engine/client/client.h
  3. 2
      engine/client/mod_dbghulls.c
  4. 2
      engine/client/sound.h
  5. 2
      engine/common/common.c
  6. 2
      engine/common/dedicated.c
  7. 2
      engine/common/filesystem.c
  8. 2
      engine/common/gamma.c
  9. 2
      engine/common/host.c
  10. 2
      engine/common/imagelib/img_bmp.c
  11. 2
      engine/common/imagelib/img_dds.c
  12. 2
      engine/common/imagelib/img_png.c
  13. 2
      engine/common/imagelib/img_tga.c
  14. 2
      engine/common/imagelib/img_utils.c
  15. 2
      engine/common/imagelib/img_wad.c
  16. 2
      engine/common/mod_bmodel.c
  17. 2
      engine/common/model.c
  18. 2
      engine/common/net_buffer.c
  19. 2
      engine/common/net_chan.c
  20. 2
      engine/common/net_encode.c
  21. 2
      engine/common/net_ws.c
  22. 2
      engine/common/pm_debug.c
  23. 2
      engine/common/pm_surface.c
  24. 2
      engine/common/pm_trace.c
  25. 2
      engine/common/system.c
  26. 2
      engine/common/world.c
  27. 2
      engine/server/server.h
  28. 2
      engine/server/sv_move.c
  29. 2
      public/matrixlib.c
  30. 5
      public/xash3d_mathlib.c
  31. 9
      public/xash3d_mathlib.h
  32. 2
      ref_gl/gl_alias.c
  33. 2
      ref_gl/gl_backend.c
  34. 2
      ref_gl/gl_frustum.c
  35. 2
      ref_gl/gl_local.h
  36. 2
      ref_gl/gl_rlight.c
  37. 2
      ref_gl/gl_rmain.c
  38. 2
      ref_gl/gl_rmath.c
  39. 2
      ref_gl/gl_rsurf.c
  40. 2
      ref_gl/gl_studio.c

2
engine/client/cl_efrag.c

@ -18,7 +18,7 @@ GNU General Public License for more details.
#include "studio.h" #include "studio.h"
#include "world.h" // BOX_ON_PLANE_SIDE #include "world.h" // BOX_ON_PLANE_SIDE
#include "client.h" #include "client.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
/* /*
=============================================================================== ===============================================================================

2
engine/client/client.h

@ -17,7 +17,7 @@ GNU General Public License for more details.
#define CLIENT_H #define CLIENT_H
#include "xash3d_types.h" #include "xash3d_types.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "cdll_int.h" #include "cdll_int.h"
#include "menu_int.h" #include "menu_int.h"
#include "cl_entity.h" #include "cl_entity.h"

2
engine/client/mod_dbghulls.c

@ -15,7 +15,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "client.h" #include "client.h"
#include "mod_local.h" #include "mod_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "world.h" #include "world.h"

2
engine/client/sound.h

@ -18,7 +18,7 @@ GNU General Public License for more details.
extern byte *sndpool; extern byte *sndpool;
#include "mathlib.h" #include "xash3d_mathlib.h"
// sound engine rate defines // sound engine rate defines
#define SOUND_DMA_SPEED 44100 // hardware playback rate #define SOUND_DMA_SPEED 44100 // hardware playback rate

2
engine/common/common.c

@ -15,7 +15,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "studio.h" #include "studio.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "const.h" #include "const.h"
#include "client.h" #include "client.h"
#include "library.h" #include "library.h"

2
engine/common/dedicated.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#if XASH_DEDICATED #if XASH_DEDICATED
#include "common.h" #include "common.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "ref_api.h" #include "ref_api.h"
ref_globals_t refState; ref_globals_t refState;

2
engine/common/filesystem.c

@ -32,7 +32,7 @@ GNU General Public License for more details.
#include "wadfile.h" #include "wadfile.h"
#include "filesystem.h" #include "filesystem.h"
#include "library.h" #include "library.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "protocol.h" #include "protocol.h"
#define FILE_COPY_SIZE (1024 * 1024) #define FILE_COPY_SIZE (1024 * 1024)

2
engine/common/gamma.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "common.h" #include "common.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#if HAVE_TGMATH_H #if HAVE_TGMATH_H
#include <tgmath.h> #include <tgmath.h>
#endif #endif

2
engine/common/host.c

@ -36,7 +36,7 @@ GNU General Public License for more details.
#include "netchan.h" #include "netchan.h"
#include "protocol.h" #include "protocol.h"
#include "mod_local.h" #include "mod_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "input.h" #include "input.h"
#include "enginefeatures.h" #include "enginefeatures.h"
#include "render_api.h" // decallist_t #include "render_api.h" // decallist_t

2
engine/common/imagelib/img_bmp.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "imagelib.h" #include "imagelib.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "img_bmp.h" #include "img_bmp.h"
/* /*

2
engine/common/imagelib/img_dds.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "imagelib.h" #include "imagelib.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "img_dds.h" #include "img_dds.h"
qboolean Image_CheckDXT3Alpha( dds_t *hdr, byte *fin ) qboolean Image_CheckDXT3Alpha( dds_t *hdr, byte *fin )

2
engine/common/imagelib/img_png.c

@ -16,7 +16,7 @@ GNU General Public License for more details.
#define MINIZ_HEADER_FILE_ONLY #define MINIZ_HEADER_FILE_ONLY
#include "miniz.h" #include "miniz.h"
#include "imagelib.h" #include "imagelib.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "img_png.h" #include "img_png.h"
#if defined(XASH_NO_NETWORK) #if defined(XASH_NO_NETWORK)

2
engine/common/imagelib/img_tga.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "imagelib.h" #include "imagelib.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "img_tga.h" #include "img_tga.h"
/* /*

2
engine/common/imagelib/img_utils.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "imagelib.h" #include "imagelib.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "mod_local.h" #include "mod_local.h"
#define LERPBYTE( i ) r = resamplerow1[i]; out[i] = (byte)(((( resamplerow2[i] - r ) * lerp)>>16 ) + r ) #define LERPBYTE( i ) r = resamplerow1[i]; out[i] = (byte)(((( resamplerow2[i] - r ) * lerp)>>16 ) + r )

2
engine/common/imagelib/img_wad.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "imagelib.h" #include "imagelib.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "wadfile.h" #include "wadfile.h"
#include "studio.h" #include "studio.h"
#include "sprite.h" #include "sprite.h"

2
engine/common/mod_bmodel.c

@ -15,7 +15,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "mod_local.h" #include "mod_local.h"
#include "sprite.h" #include "sprite.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "alias.h" #include "alias.h"
#include "studio.h" #include "studio.h"
#include "wadfile.h" #include "wadfile.h"

2
engine/common/model.c

@ -15,7 +15,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "mod_local.h" #include "mod_local.h"
#include "sprite.h" #include "sprite.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "alias.h" #include "alias.h"
#include "studio.h" #include "studio.h"
#include "wadfile.h" #include "wadfile.h"

2
engine/common/net_buffer.c

@ -16,7 +16,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "protocol.h" #include "protocol.h"
#include "net_buffer.h" #include "net_buffer.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
//#define DEBUG_NET_MESSAGES_SEND //#define DEBUG_NET_MESSAGES_SEND
//#define DEBUG_NET_MESSAGES_READ //#define DEBUG_NET_MESSAGES_READ

2
engine/common/net_chan.c

@ -15,7 +15,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "netchan.h" #include "netchan.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "net_encode.h" #include "net_encode.h"
#include "protocol.h" #include "protocol.h"

2
engine/common/net_encode.c

@ -15,7 +15,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "netchan.h" #include "netchan.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "net_encode.h" #include "net_encode.h"
#include "event_api.h" #include "event_api.h"
#include "usercmd.h" #include "usercmd.h"

2
engine/common/net_ws.c

@ -16,7 +16,7 @@ GNU General Public License for more details.
#include "common.h" #include "common.h"
#include "client.h" // ConnectionProgress #include "client.h" // ConnectionProgress
#include "netchan.h" #include "netchan.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#if XASH_WIN32 #if XASH_WIN32
// Winsock // Winsock
#include <WS2tcpip.h> #include <WS2tcpip.h>

2
engine/common/pm_debug.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "common.h" #include "common.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "pm_local.h" #include "pm_local.h"
#if !XASH_DEDICATED #if !XASH_DEDICATED
#include "client.h" // CL_Particle #include "client.h" // CL_Particle

2
engine/common/pm_surface.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "common.h" #include "common.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "pm_local.h" #include "pm_local.h"
#include "ref_common.h" #include "ref_common.h"

2
engine/common/pm_trace.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "common.h" #include "common.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "mod_local.h" #include "mod_local.h"
#include "pm_local.h" #include "pm_local.h"
#include "pm_movevars.h" #include "pm_movevars.h"

2
engine/common/system.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "common.h" #include "common.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "platform/platform.h" #include "platform/platform.h"
#include <stdlib.h> #include <stdlib.h>

2
engine/common/world.c

@ -17,7 +17,7 @@ GNU General Public License for more details.
#include "world.h" #include "world.h"
#include "pm_defs.h" #include "pm_defs.h"
#include "mod_local.h" #include "mod_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "studio.h" #include "studio.h"
// just for debug // just for debug

2
engine/server/server.h

@ -16,7 +16,7 @@ GNU General Public License for more details.
#ifndef SERVER_H #ifndef SERVER_H
#define SERVER_H #define SERVER_H
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "edict.h" #include "edict.h"
#include "eiface.h" #include "eiface.h"
#include "physint.h" // physics interface #include "physint.h" // physics interface

2
engine/server/sv_move.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "common.h" #include "common.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "server.h" #include "server.h"
#include "const.h" #include "const.h"
#include "pm_defs.h" #include "pm_defs.h"

2
public/matrixlib.c

@ -17,7 +17,7 @@ GNU General Public License for more details.
#include "xash3d_types.h" #include "xash3d_types.h"
#include "const.h" #include "const.h"
#include "com_model.h" #include "com_model.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
const matrix3x4 matrix3x4_identity = const matrix3x4 matrix3x4_identity =
{ {

5
public/mathlib.c → public/xash3d_mathlib.c

@ -1,5 +1,5 @@
/* /*
mathlib.c - internal mathlib xash3d_mathlib.c - internal mathlib
Copyright (C) 2010 Uncle Mike Copyright (C) 2010 Uncle Mike
This program is free software: you can redistribute it and/or modify This program is free software: you can redistribute it and/or modify
@ -16,7 +16,7 @@ GNU General Public License for more details.
#include "xash3d_types.h" #include "xash3d_types.h"
#include "const.h" #include "const.h"
#include "com_model.h" #include "com_model.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "eiface.h" #include "eiface.h"
#if HAVE_TGMATH_H #if HAVE_TGMATH_H
#include <tgmath.h> #include <tgmath.h>
@ -874,3 +874,4 @@ int BoxOnPlaneSide( const vec3_t emins, const vec3_t emaxs, const mplane_t *p )
return sides; return sides;
} }

9
public/mathlib.h → public/xash3d_mathlib.h

@ -1,5 +1,5 @@
/* /*
mathlib.h - base math functions xash3d_mathlib.h - base math functions
Copyright (C) 2007 Uncle Mike Copyright (C) 2007 Uncle Mike
This program is free software: you can redistribute it and/or modify This program is free software: you can redistribute it and/or modify
@ -13,8 +13,8 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details. GNU General Public License for more details.
*/ */
#ifndef MATHLIB_H #ifndef XASH3D_MATHLIB_H
#define MATHLIB_H #define XASH3D_MATHLIB_H
#include <math.h> #include <math.h>
#if HAVE_TGMATH_H #if HAVE_TGMATH_H
@ -227,4 +227,5 @@ extern const matrix3x4 matrix3x4_identity;
extern const matrix4x4 matrix4x4_identity; extern const matrix4x4 matrix4x4_identity;
extern const float m_bytenormals[NUMVERTEXNORMALS][3]; extern const float m_bytenormals[NUMVERTEXNORMALS][3];
#endif//MATHLIB_H #endif // XASH3D_MATHLIB_H

2
ref_gl/gl_alias.c

@ -13,7 +13,7 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details. GNU General Public License for more details.
*/ */
#include "gl_local.h" #include "gl_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "const.h" #include "const.h"
#include "r_studioint.h" #include "r_studioint.h"
#include "triangleapi.h" #include "triangleapi.h"

2
ref_gl/gl_backend.c

@ -15,7 +15,7 @@ GNU General Public License for more details.
#include "gl_local.h" #include "gl_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
char r_speeds_msg[MAX_SYSPATH]; char r_speeds_msg[MAX_SYSPATH];
ref_speeds_t r_stats; // r_speeds counters ref_speeds_t r_stats; // r_speeds counters

2
ref_gl/gl_frustum.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "gl_local.h" #include "gl_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
void GL_FrustumEnablePlane( gl_frustum_t *out, int side ) void GL_FrustumEnablePlane( gl_frustum_t *out, int side )
{ {

2
ref_gl/gl_local.h

@ -26,7 +26,7 @@ GNU General Public License for more details.
#include "dlight.h" #include "dlight.h"
#include "gl_frustum.h" #include "gl_frustum.h"
#include "ref_api.h" #include "ref_api.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "ref_params.h" #include "ref_params.h"
#include "enginefeatures.h" #include "enginefeatures.h"
#include "com_strings.h" #include "com_strings.h"

2
ref_gl/gl_rlight.c

@ -16,7 +16,7 @@ GNU General Public License for more details.
#include "gl_local.h" #include "gl_local.h"
#include "pm_local.h" #include "pm_local.h"
#include "studio.h" #include "studio.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "ref_params.h" #include "ref_params.h"
/* /*

2
ref_gl/gl_rmain.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "gl_local.h" #include "gl_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "library.h" #include "library.h"
#include "beamdef.h" #include "beamdef.h"
#include "particledef.h" #include "particledef.h"

2
ref_gl/gl_rmath.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "gl_local.h" #include "gl_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
/* /*
======================================================================== ========================================================================

2
ref_gl/gl_rsurf.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "gl_local.h" #include "gl_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "mod_local.h" #include "mod_local.h"
typedef struct typedef struct

2
ref_gl/gl_studio.c

@ -14,7 +14,7 @@ GNU General Public License for more details.
*/ */
#include "gl_local.h" #include "gl_local.h"
#include "mathlib.h" #include "xash3d_mathlib.h"
#include "const.h" #include "const.h"
#include "r_studioint.h" #include "r_studioint.h"
#include "triangleapi.h" #include "triangleapi.h"

Loading…
Cancel
Save