Subversion Repositories eduke32

Compare Revisions

Ignore whitespace Rev 4746 → Rev 4747

/polymer/eduke32/build/include/a.h
3,8 → 3,8
// by Jonathon Fowler (jf@jonof.id.au)
 
 
#ifndef __a_h__
#define __a_h__
#ifndef a_h_
#define a_h_
 
#include "compat.h"
 
140,4 → 140,4
 
#endif // else
 
#endif // __a_h__
#endif // a_h_
/polymer/eduke32/build/include/baselayer.h
2,8 → 2,8
// for the Build Engine
// by Jonathon Fowler (jf@jonof.id.au)
 
#ifndef __baselayer_h__
#define __baselayer_h__
#ifndef baselayer_h_
#define baselayer_h_
 
#include "compat.h"
#include "osd.h"
213,5 → 213,5
}
#endif
 
#endif // __baselayer_h__
#endif // baselayer_h_
 
/polymer/eduke32/build/include/build.h
6,8 → 6,8
// by Jonathon Fowler (jf@jonof.id.au)
 
 
#ifndef __build_h__
#define __build_h__
#ifndef build_h_
#define build_h_
 
#include "compat.h"
#include "pragmas.h"
253,23 → 253,23
static inline void wall_tracker_hook(uintptr_t address);
static inline void sprite_tracker_hook(uintptr_t address);
 
#define __TRACKER_NAME SectorTracker
#define __TRACKER_GLOBAL_HOOK sector_tracker_hook
#define TRACKER_NAME_ SectorTracker
#define TRACKER_GLOBAL_HOOK_ sector_tracker_hook
#include "tracker.hpp"
#undef __TRACKER_NAME
#undef __TRACKER_GLOBAL_HOOK
#undef TRACKER_NAME_
#undef TRACKER_GLOBAL_HOOK_
 
#define __TRACKER_NAME WallTracker
#define __TRACKER_GLOBAL_HOOK wall_tracker_hook
#define TRACKER_NAME_ WallTracker
#define TRACKER_GLOBAL_HOOK_ wall_tracker_hook
#include "tracker.hpp"
#undef __TRACKER_NAME
#undef __TRACKER_GLOBAL_HOOK
#undef TRACKER_NAME_
#undef TRACKER_GLOBAL_HOOK_
 
#define __TRACKER_NAME SpriteTracker
#define __TRACKER_GLOBAL_HOOK sprite_tracker_hook
#define TRACKER_NAME_ SpriteTracker
#define TRACKER_GLOBAL_HOOK_ sprite_tracker_hook
#include "tracker.hpp"
#undef __TRACKER_NAME
#undef __TRACKER_GLOBAL_HOOK
#undef TRACKER_NAME_
#undef TRACKER_GLOBAL_HOOK_
 
#define Tracker(Container, Type) Container##Tracker<Type>
#define TrackerCast(x) x.cast()
1501,4 → 1501,4
}
#endif
 
#endif // __build_h__
#endif // build_h_
/polymer/eduke32/build/include/cache1d.h
1,7 → 1,7
// cache1d.h
 
#ifndef __cache1d_h__
#define __cache1d_h__
#ifndef cache1d_h_
#define cache1d_h_
 
#include "compat.h"
#include "mutex.h"
76,5 → 76,5
}
#endif
 
#endif // __cache1d_h__
#endif // cache1d_h_
 
/polymer/eduke32/build/include/compat.h
2,8 → 2,8
// certain build environments. It also levels the playing field caused
// by different platforms.
 
#ifndef __compat_h__
#define __compat_h__
#ifndef compat_h_
#define compat_h_
 
#include <malloc.h>
 
138,11 → 138,11
// is for platforms which give us a standard sort of C library so we
// link directly. Platforms like PalmOS which don't have a standard C
// library will need to wrap these functions with suitable emulations.
#define __compat_h_macrodef__
#define compat_h_macrodef__
 
#ifdef EXTERNC
# include <cstdarg>
# ifdef __compat_h_macrodef__
# ifdef compat_h_macrodef__
# include <cstdio>
# include <cstring>
# include <cstdlib>
153,7 → 153,7
# include <stddef.h>
#endif
 
#ifdef __compat_h_macrodef__
#ifdef compat_h_macrodef__
# ifndef EXTERNC
# include <stdio.h>
# include <string.h>
449,7 → 449,7
# define FP_OFF(__p) ((uintptr_t)(__p))
#endif
 
#ifdef __compat_h_macrodef__
#ifdef compat_h_macrodef__
 
# ifndef O_BINARY
# define O_BINARY 0
577,7 → 577,7
typedef intptr_t ssize_t;
#endif
 
#ifdef __compat_h_macrodef__
#ifdef compat_h_macrodef__
typedef FILE BFILE;
# define bsize_t size_t
# define bssize_t ssize_t
598,7 → 598,7
#define strtoll _strtoi64
#endif
 
#ifdef __compat_h_macrodef__
#ifdef compat_h_macrodef__
# define Bassert assert
# define Brand rand
# define Balloca alloca
958,4 → 958,4
 
//////////
 
#endif // __compat_h__
#endif // compat_h_
/polymer/eduke32/build/include/crc32.h
1,5 → 1,5
#ifndef __crc32_h__
#define __crc32_h__
#ifndef crc32_h_
#define crc32_h_
 
#include "compat.h"
 
/polymer/eduke32/build/include/dxdidf.h
1,5 → 1,5
#ifndef __dxdidf_h__
#define __dxdidf_h__
#ifndef dxdidf_h_
#define dxdidf_h_
 
// Joystick
 
52,4 → 52,4
 
const DIDATAFORMAT c_dfDIJoystick = { sizeof(DIDATAFORMAT), sizeof(DIOBJECTDATAFORMAT), 0x00000001, 80, 44, c_dfDIJoystick_odf };
 
#endif // __dxdidf_h__
#endif // dxdidf_h_
/polymer/eduke32/build/include/dynamicgtk.h
1,5 → 1,5
#ifndef __dynamicgtk_h__
#define __dynamicgtk_h__
#ifndef dynamicgtk_h_
#define dynamicgtk_h_
 
#include <gdk-pixbuf/gdk-pixdata.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
401,7 → 401,7
int32_t dynamicgtk_init(void);
void dynamicgtk_uninit(void);
 
#ifndef __dynamicgtkfoo__
#ifndef dynamicgtkfoo__
 
// glib.h
#define g_free dynamicgtksyms.g_free
625,5 → 625,5
 
#endif /* LINKED_GTK */
 
#endif /* __dynamicgtk_h__ */
#endif /* dynamicgtk_h_ */
 
/polymer/eduke32/build/include/editor.h
2,8 → 2,8
// Ken Silverman's official web site: "http://www.advsys.net/ken"
// See the included license file "BUILDLIC.TXT" for license info.
 
#ifndef __editor_h__
#define __editor_h__
#ifndef editor_h_
#define editor_h_
 
#include <math.h>
 
/polymer/eduke32/build/include/glext.h
1,5 → 1,5
#ifndef __glext_h_
#define __glext_h_
#ifndef glext_h_
#define glext_h_
 
#ifdef EXTERNC
extern "C" {
/polymer/eduke32/build/include/gtkbits.h
1,5 → 1,5
#ifndef __gtkbits_h__
#define __gtkbits_h__
#ifndef gtkbits_h_
#define gtkbits_h_
 
extern void gtkbuild_init(int32_t *argc, char ***argv);
extern void gtkbuild_exit(int32_t r);
/polymer/eduke32/build/include/kplib.h
2,7 → 2,7
extern "C" {
#endif
 
#ifndef __compat_h__
#ifndef compat_h_
#include "compat.h"
#endif
 
/polymer/eduke32/build/include/libdivide.h
4,8 → 4,8
Modified for EDuke32. zlib license.
*/
 
#ifndef __libdivide_h__
#define __libdivide_h__
#ifndef libdivide_h_
#define libdivide_h_
 
#if defined(_WIN32) || defined(WIN32)
#define LIBDIVIDE_WINDOWS 1
/polymer/eduke32/build/include/mdsprite.h
1,5 → 1,5
#ifndef _mdsprite_h_
# define _mdsprite_h_
#ifndef mdsprite_h_
# define mdsprite_h_
 
#ifdef USE_OPENGL
#include "hightile.h"
228,4 → 228,4
HUDFLAG_NODEPTH = 8,
};
 
#endif // !_mdsprite_h_
#endif // !mdsprite_h_
/polymer/eduke32/build/include/mmulti.h
1,7 → 1,7
// mmulti.h
 
#ifndef __mmulti_h__
#define __mmulti_h__
#ifndef mmulti_h_
#define mmulti_h_
 
#define MAXMULTIPLAYERS 16
 
25,5 → 25,5
void genericmultifunction(int other, unsigned char *bufptr, int messleng, int command);
int isvalidipaddress(const char *st);
 
#endif // __mmulti_h__
#endif // mmulti_h_
 
/polymer/eduke32/build/include/mutex.h
1,5 → 1,5
#ifndef __mutex_h__
#define __mutex_h__
#ifndef mutex_h_
#define mutex_h_
 
/* Mutual exclusion mechanism wrappers for the different platforms */
 
/polymer/eduke32/build/include/osd.h
2,8 → 2,8
// for the Build Engine
// by Jonathon Fowler (jf@jonof.id.au)
 
#ifndef __osd_h__
#define __osd_h__
#ifndef osd_h_
#define osd_h_
 
#ifdef EXTERNC
extern "C" {
306,5 → 306,5
}
#endif
 
#endif // __osd_h__
#endif // osd_h_
 
/polymer/eduke32/build/include/osxbits.h
1,5 → 1,5
#ifndef __osxbits_h__
#define __osxbits_h__
#ifndef osxbits_h_
#define osxbits_h_
#include <sys/types.h>
 
int32_t osx_msgbox(const char *name, const char *msg);
/polymer/eduke32/build/include/polymer.h
1,7 → 1,7
// Here lies the slow as shit renderer!
 
#ifndef _polymer_h_
# define _polymer_h_
#ifndef polymer_h_
# define polymer_h_
 
# include "compat.h"
# include "baselayer.h"
568,4 → 568,4
 
# endif // !POLYMER_C
 
#endif // !_polymer_h_
#endif // !polymer_h_
/polymer/eduke32/build/include/polymost.h
1,5 → 1,5
#ifndef _polymost_h_
# define _polymost_h_
#ifndef polymost_h_
# define polymost_h_
 
#ifdef USE_OPENGL
 
/polymer/eduke32/build/include/pragmas.h
2,8 → 2,8
// by Jonathon Fowler (jf@jonof.id.au)
 
 
#ifndef __pragmas_h__
#define __pragmas_h__
#ifndef pragmas_h_
#define pragmas_h_
 
#ifdef EXTERNC
extern "C" {
263,4 → 263,4
}
#endif
 
#endif // __pragmas_h__
#endif // pragmas_h_
/polymer/eduke32/build/include/pragmas_arm.h
2,8 → 2,8
// GCC Inline Assembler version (ARM)
//
 
#ifndef __pragmas_arm_h__
#define __pragmas_arm_h__
#ifndef pragmas_arm_h_
#define pragmas_arm_h_
 
#define EDUKE32_SCALER_PRAGMA(a) \
static inline int32_t mulscale##a(int32_t eax, int32_t edx) { return dw((qw(eax) * edx) >> by(a)); } \
/polymer/eduke32/build/include/pragmas_ppc.h
1,8 → 1,8
// GCC Inline Assembler version (PowerPC)
 
#ifdef __pragmas_h__
#ifndef __pragmas_ppc_h__
#define __pragmas_ppc_h__
#ifdef pragmas_h_
#ifndef pragmas_ppc_h_
#define pragmas_ppc_h_
 
#define EDUKE32_SCALER_PRAGMA(x) \
static inline int32_t mulscale##x(int32_t a, int32_t d) \
249,5 → 249,5
return((reciptable[(i>>12)&2047]>>(((i-0x3f800000)>>23)&31))^(i>>31));
}
 
#endif // __pragmas_ppc_h__
#endif // __pragmas_h__
#endif // pragmas_ppc_h_
#endif // pragmas_h_
/polymer/eduke32/build/include/pragmas_x86_gcc.h
4,9 → 4,9
 
//{{{
 
#ifdef __pragmas_h__
#ifndef __pragmas_x86_h__
#define __pragmas_x86_h__
#ifdef pragmas_h_
#ifndef pragmas_x86_h_
#define pragmas_x86_h_
 
#ifndef UNDERSCORES
#define _DMVAL "dmval"
564,5 → 564,5
 
//}}}
 
#endif // __pragmas_x86_h__
#endif // __pragmas_h__
#endif // pragmas_x86_h_
#endif // pragmas_h_
/polymer/eduke32/build/include/pragmas_x86_msvc.h
4,9 → 4,9
 
//{{{
 
#ifdef __pragmas_h__
#ifndef __pragmas_x86_h__
#define __pragmas_x86_h__
#ifdef pragmas_h_
#ifndef pragmas_x86_h_
#define pragmas_x86_h_
 
static __inline int32_t mulscale(int32_t a, int32_t d, int32_t c)
{
445,5 → 445,5
 
//}}}
 
#endif // __pragmas_x86_h__
#endif // __pragmas_h__
#endif // pragmas_x86_h_
#endif // pragmas_h_
/polymer/eduke32/build/include/prlights.h
1,6 → 1,6
// LIGHTS
#ifndef _prlight_h_
# define _prlight_h_
#ifndef prlight_h_
# define prlight_h_
 
#define PR_MAXLIGHTS 1024
#define SHADOW_DEPTH_OFFSET 30
/polymer/eduke32/build/include/rawinput.h
1,5 → 1,5
#ifndef rawinput_h__
#define rawinput_h__
#ifndef rawinput_h_
#define rawinput_h_
 
#include "compat.h"
 
20,5 → 20,5
#define VK_MBUTTON 0x04 /* NOT contiguous with L & RBUTTON */
#endif
 
#endif // rawinput_h__
#endif // rawinput_h_
 
/polymer/eduke32/build/include/sdl_inc.h
1,5 → 1,5
#ifndef __SDL_INC_H
#define __SDL_INC_H
#ifndef SDL_INC_H_
#define SDL_INC_H_
 
// Workaround for i686-MinGW-w64.
#if defined __MINGW64_VERSION_MAJOR && !defined __MINGW64__
76,5 → 76,5
#endif /* end of bad version error */
#endif /* end of SDL_mixer checks */
 
#endif /* __SDL_INC_H */
#endif /* SDL_INC_H_ */
 
/polymer/eduke32/build/include/sdlayer.h
2,8 → 2,8
// for the Build Engine
// by Jonathon Fowler (jf@jonof.id.au)
 
#ifndef __build_interface_layer__
#define __build_interface_layer__ SDL
#ifndef build_interface_layer_
#define build_interface_layer_ SDL
 
#include "sdl_inc.h"
#include "compat.h"
40,8 → 40,8
}
 
#else
#if (__build_interface_layer__ != SDL)
#error "Already using the " __build_interface_layer__ ". Can't now use SDL."
#if (build_interface_layer_ != SDL)
#error "Already using the " build_interface_layer_ ". Can't now use SDL."
#endif
#endif // __build_interface_layer__
#endif // build_interface_layer_
 
/polymer/eduke32/build/include/texcache.h
1,5 → 1,5
#ifndef _texcache_h_
# define _texcache_h_
#ifndef texcache_h_
# define texcache_h_
 
#ifdef USE_OPENGL
 
/polymer/eduke32/build/include/tracker.hpp
1,7 → 1,7
 
 
template<typename TrackedType>
class __TRACKER_NAME
class TRACKER_NAME_
{
public:
TrackedType TrackedValue;
8,31 → 8,31
 
inline TrackedType* operator & ()
{
__TRACKER_GLOBAL_HOOK((uintptr_t)&this->TrackedValue);
TRACKER_GLOBAL_HOOK_((uintptr_t)&this->TrackedValue);
return &this->TrackedValue;
}
 
inline TrackedType operator ++ ()
{
__TRACKER_GLOBAL_HOOK((uintptr_t)&this->TrackedValue);
TRACKER_GLOBAL_HOOK_((uintptr_t)&this->TrackedValue);
return ++this->TrackedValue;
}
 
inline TrackedType operator ++ (int)
{
__TRACKER_GLOBAL_HOOK((uintptr_t)&this->TrackedValue);
TRACKER_GLOBAL_HOOK_((uintptr_t)&this->TrackedValue);
return this->TrackedValue++;
}
 
inline TrackedType operator -- ()
{
__TRACKER_GLOBAL_HOOK((uintptr_t)&this->TrackedValue);
TRACKER_GLOBAL_HOOK_((uintptr_t)&this->TrackedValue);
return --this->TrackedValue;
}
 
inline TrackedType operator -- (int)
{
__TRACKER_GLOBAL_HOOK((uintptr_t)&this->TrackedValue);
TRACKER_GLOBAL_HOOK_((uintptr_t)&this->TrackedValue);
return this->TrackedValue--;
}
 
61,13 → 61,13
inline TrackedType cast() const;
};
 
#ifndef __tracker_hpp
#define __tracker_hpp
#ifndef tracker_hpp_
#define tracker_hpp_
 
enum {
__TRACKER_NOOP_RIGHTHAND_EQUAL = 0,
__TRACKER_NOOP_RIGHTHAND_ZERO,
__TRACKER_NOOP_RIGHTHAND_ONE,
TRACKER_NOOP_RIGHTHAND_EQUAL_ = 0,
TRACKER_NOOP_RIGHTHAND_ZERO_,
TRACKER_NOOP_RIGHTHAND_ONE_,
__TRACKER_NEVER,
};
 
80,13 → 80,13
#undef __TRACKER_RIGHTHAND
 
template<typename TrackedType>
inline __TRACKER_NAME<TrackedType>::operator TrackedType() const
inline TRACKER_NAME_<TrackedType>::operator TrackedType() const
{
return this->TrackedValue;
}
 
template<typename TrackedType>
inline TrackedType __TRACKER_NAME<TrackedType>::cast() const
inline TrackedType TRACKER_NAME_<TrackedType>::cast() const
{
return this->TrackedValue;
}
/polymer/eduke32/build/include/tracker_operator.hpp
1,17 → 1,17
 
template<typename TrackedType>
inline TrackedType __TRACKER_NAME<TrackedType>::operator __TRACKER_OPERATOR (__TRACKER_RIGHTHAND_TYPE)
inline TrackedType TRACKER_NAME_<TrackedType>::operator TRACKER_OPERATOR_ (__TRACKER_RIGHTHAND_TYPE)
{
bool isNoop;
 
switch (__TRACKER_NOOP) {
case __TRACKER_NOOP_RIGHTHAND_EQUAL:
switch (TRACKER_NOOP_) {
case TRACKER_NOOP_RIGHTHAND_EQUAL_:
isNoop = this->TrackedValue == __TRACKER_RIGHTHAND;
break;
case __TRACKER_NOOP_RIGHTHAND_ZERO:
case TRACKER_NOOP_RIGHTHAND_ZERO_:
isNoop = __TRACKER_RIGHTHAND == 0;
break;
case __TRACKER_NOOP_RIGHTHAND_ONE:
case TRACKER_NOOP_RIGHTHAND_ONE_:
isNoop = __TRACKER_RIGHTHAND == 1;
break;
default:
22,8 → 22,8
 
if (!isNoop) {
 
__TRACKER_GLOBAL_HOOK((uintptr_t)&this->TrackedValue);
return (this->TrackedValue __TRACKER_OPERATOR __TRACKER_RIGHTHAND);
TRACKER_GLOBAL_HOOK_((uintptr_t)&this->TrackedValue);
return (this->TrackedValue TRACKER_OPERATOR_ __TRACKER_RIGHTHAND);
} else {
return this->TrackedValue;
}
/polymer/eduke32/build/include/tracker_operators.hpp
1,59 → 1,59
#define __TRACKER_OPERATOR =
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_EQUAL
#define TRACKER_OPERATOR_ =
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_EQUAL_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR +=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ZERO
#define TRACKER_OPERATOR_ +=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ZERO_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR -=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ZERO
#define TRACKER_OPERATOR_ -=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ZERO_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR *=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ONE
#define TRACKER_OPERATOR_ *=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ONE_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR /=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ONE
#define TRACKER_OPERATOR_ /=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ONE_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR |=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ZERO
#define TRACKER_OPERATOR_ |=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ZERO_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR &=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_EQUAL
#define TRACKER_OPERATOR_ &=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_EQUAL_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR ^=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ZERO
#define TRACKER_OPERATOR_ ^=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ZERO_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR <<=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ZERO
#define TRACKER_OPERATOR_ <<=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ZERO_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
 
#define __TRACKER_OPERATOR >>=
#define __TRACKER_NOOP __TRACKER_NOOP_RIGHTHAND_ZERO
#define TRACKER_OPERATOR_ >>=
#define TRACKER_NOOP_ TRACKER_NOOP_RIGHTHAND_ZERO_
#include "tracker_operator.hpp"
#undef __TRACKER_OPERATOR
#undef __TRACKER_NOOP
#undef TRACKER_OPERATOR_
#undef TRACKER_NOOP_
/polymer/eduke32/build/include/winlayer.h
1,8 → 1,8
// Windows DIB/DirectDraw interface layer for the Build Engine
// Originally by Jonathon Fowler (jf@jonof.id.au)
 
#ifndef __build_interface_layer__
#define __build_interface_layer__ WIN
#ifndef build_interface_layer_
#define build_interface_layer_ WIN
 
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
31,8 → 31,8
#include "baselayer.h"
 
#else
#if (__build_interface_layer__ != WIN)
#error "Already using the " __build_interface_layer__ ". Can't now use Windows."
#if (build_interface_layer_ != WIN)
#error "Already using the " build_interface_layer_ ". Can't now use Windows."
#endif
#endif // __build_interface_layer__
#endif // build_interface_layer_
 
/polymer/eduke32/build/src/compat.c
78,7 → 78,7
 
//////////
 
#ifndef __compat_h_macrodef__
#ifndef compat_h_macrodef__
 
void Bassert(int expr)
{
/polymer/eduke32/build/src/dynamicgtk.c
2,7 → 2,7
#include <stdio.h>
#include <string.h>
 
#define __dynamicgtkfoo__
#define dynamicgtkfoo__
#include "dynamicgtk.h"
 
static void *handle = NULL;
/polymer/eduke32/source/_functio.h
28,8 → 28,8
// axis defaults are also included
 
 
#ifndef _function_private_
#define _function_private_
#ifndef function_private_h_
#define function_private_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/_rts.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __rts_private__
#define __rts_private__
#ifndef rts_private__
#define rts_private__
 
//===============
// TYPES
/polymer/eduke32/source/actors.c
2257,7 → 2257,7
{
A_Fall(i);
if (krand()&1) s->zvel -= 256;
if (klabs(s->xvel) < 48)
if ((s->xvel) < 48)
s->xvel += (krand()&3);
}
else KILLIT(i);
/polymer/eduke32/source/actors.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __actors_h__
#define __actors_h__
#ifndef actors_h_
#define actors_h_
 
#include "player.h"
 
/polymer/eduke32/source/actors_inline.c
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __actors_inline_c__
#define __actors_inline_c__
#ifndef actors_inline_c_
#define actors_inline_c_
 
#include "compat.h"
#include "build.h"
/polymer/eduke32/source/actors_inline.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __actors_inline_h__
#define __actors_inline_h__
#ifndef actors_inline_h_
#define actors_inline_h_
 
#if KRANDDEBUG
# define ACTOR_INLINE __fastcall
/polymer/eduke32/source/android.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __android_h__
#define __android_h__
#ifndef android_h_
#define android_h_
 
#ifdef __ANDROID__
#include "compat.h"
/polymer/eduke32/source/anim.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __anim_h__
#define __anim_h__
#ifndef anim_h_
#define anim_h_
 
#define NUM_HARDCODED_ANIMS 12
 
/polymer/eduke32/source/config.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef _config_public
#define _config_public
#ifndef config_public_h_
#define config_public_h_
 
#define SETUPNAMEPARM "SETUPFILE"
 
/polymer/eduke32/source/demo.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __demo_h__
#define __demo_h__
#ifndef demo_h_
#define demo_h_
 
#define DEMOFN_FMT "edemo%03d.edm"
#define MAXDEMOS 1000
/polymer/eduke32/source/duke3d.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __duke3d_h__
#define __duke3d_h__
#ifndef duke3d_h_
#define duke3d_h_
 
#ifdef EXTERNC
{
/polymer/eduke32/source/function.h
28,8 → 28,8
// axis defaults are also included
 
 
#ifndef _function_public_
#define _function_public_
#ifndef function_public_h_
#define function_public_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/game.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __game_h__
#define __game_h__
#ifndef game_h_
#define game_h_
 
#include "premap.h"
 
/polymer/eduke32/source/game_inline.c
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __game_inline_c__
#define __game_inline_c__
#ifndef game_inline_c_
#define game_inline_c_
 
#include "compat.h"
#include "duke3d.h"
/polymer/eduke32/source/game_inline.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __game_inline_h__
#define __game_inline_h__
#ifndef game_inline_h_
#define game_inline_h_
 
EXTERN_INLINE_HEADER void G_SetStatusBarScale(int32_t sc);
 
/polymer/eduke32/source/gamedef.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef _gamedef_h_
#define _gamedef_h_
#ifndef gamedef_h_
#define gamedef_h_
 
#include "build.h" // hashtable_t
#include "common.h" // tokenlist
948,6 → 948,4
};
// KEEPINSYNC with the keyword list in lunatic/con_lang.lua
#endif
 
 
#endif
#endif // gamedef_h_
/polymer/eduke32/source/gamedefs.h
28,8 → 28,8
//
//****************************************************************************
 
#ifndef _gamedefs_public_
#define _gamedefs_public_
#ifndef gamedefs_public_h_
#define gamedefs_public_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/gameexec.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __gameexec_h__
#define __gameexec_h__
#ifndef gameexec_h_
#define gameexec_h_
 
#include "build.h"
#include "sector.h" // mapstate_t
/polymer/eduke32/source/gamestructures.c
28,7 → 28,7
// this is all the crap for accessing the game's structs through the CON VM
// I got a 3-4 fps gain by inlining these...
 
#ifndef _gamevars_c_
#ifndef gamevars_c_
static void __fastcall VM_AccessUserdef(int32_t iSet, int32_t lLabelID, int32_t lVar2)
{
int32_t lValue=0;
3980,4 → 3980,4
return -1;
}
}
#endif // _gamevars_c_
#endif // gamevars_c_
/polymer/eduke32/source/gamevars.c
28,7 → 28,7
#include "savegame.h"
#include "menus.h"
 
#define _gamevars_c_
#define gamevars_c_
 
#ifdef LUNATIC
int32_t g_noResetVars;
/polymer/eduke32/source/gamevars.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __gamevars_h__
#define __gamevars_h__
#ifndef gamevars_h_
#define gamevars_h_
 
#include "gamedef.h"
 
/polymer/eduke32/source/global.c
20,7 → 20,7
*/
//-------------------------------------------------------------------------
 
#define __global_c__
#define global_c_
#include "global.h"
#include "duke3d.h"
 
/polymer/eduke32/source/global.h
20,10 → 20,10
*/
//-------------------------------------------------------------------------
 
#ifndef __global_h__
#define __global_h__
#ifndef global_h_
#define global_h_
 
#ifdef __global_c__
#ifdef global_c_
#define G_EXTERN
#else
#define G_EXTERN extern
124,7 → 124,7
G_EXTERN int32_t g_screenCapture;
G_EXTERN int32_t g_noEnemies;
 
#ifndef __global_c__
#ifndef global_c_
G_EXTERN const char *s_buildDate;
G_EXTERN int32_t g_spriteGravity;
G_EXTERN int16_t g_spriteDeleteQueueSize;
/polymer/eduke32/source/grpscan.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __grpscan_h__
#define __grpscan_h__
#ifndef grpscan_h_
#define grpscan_h_
 
#define MAXLISTNAMELEN 32
 
/polymer/eduke32/source/input.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __input_h__
#define __input_h__
#ifndef input_h_
#define input_h_
 
extern int32_t I_CheckAllInput(void);
extern void I_ClearAllInput(void);
/polymer/eduke32/source/jaudiolib/include/fx_man.h
28,8 → 28,8
(c) Copyright 1994 James R. Dose. All Rights Reserved.
**********************************************************************/
 
#ifndef __FX_MAN_H
#define __FX_MAN_H
#ifndef FX_MAN_H_
#define FX_MAN_H_
 
#include "inttypes.h"
#include "limits.h"
/polymer/eduke32/source/jaudiolib/include/sndcards.h
28,8 → 28,8
(c) Copyright 1994 James R. Dose. All Rights Reserved.
**********************************************************************/
 
#ifndef __SNDCARDS_H
#define __SNDCARDS_H
#ifndef SNDCARDS_H_
#define SNDCARDS_H_
 
typedef enum
{
/polymer/eduke32/source/jaudiolib/src/_multivc.h
28,8 → 28,8
(c) Copyright 1993 James R. Dose. All Rights Reserved.
**********************************************************************/
 
#ifndef ___MULTIVC_H
#define ___MULTIVC_H
#ifndef MULTIVC_H_
#define MULTIVC_H_
 
#include "limits.h"
#include "inttypes.h"
/polymer/eduke32/source/jaudiolib/src/linklist.h
17,101 → 17,96
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 
*/
#ifndef __linklist_h
#define __linklist_h
#ifndef linklist_h_
#define linklist_h_
#ifdef EXTERNC
{
#endif
 
 
#define NewNode(type) ((type*)Bmalloc(sizeof(type)))
#define NewNode(type) ((type *)Bmalloc(sizeof(type)))
 
 
#define LL_CreateNewLinkedList(rootnode,type,next,prev) \
{ \
(rootnode) = NewNode(type); \
(rootnode)->prev = (rootnode); \
(rootnode)->next = (rootnode); \
}
#define LL_CreateNewLinkedList(rootnode, type, next, prev) \
{ \
(rootnode) = NewNode(type); \
(rootnode)->prev = (rootnode); \
(rootnode)->next = (rootnode); \
}
 
 
#define LL_AddNode(rootnode, newnode, next, prev) \
{ \
(newnode)->next = (rootnode); \
(newnode)->prev = (rootnode)->prev; \
(rootnode)->prev->next = (newnode); \
(rootnode)->prev = (newnode); \
}
 
#define LL_AddNode(rootnode, newnode, next, prev) \
{ \
(newnode)->next = (rootnode); \
(newnode)->prev = (rootnode)->prev; \
(rootnode)->prev->next = (newnode); \
(rootnode)->prev = (newnode); \
}
#define LL_TransferList(oldroot, newroot, next, prev) \
{ \
if ((oldroot)->prev != (oldroot)) \
{ \
(oldroot)->prev->next = (newroot); \
(oldroot)->next->prev = (newroot)->prev; \
(newroot)->prev->next = (oldroot)->next; \
(newroot)->prev = (oldroot)->prev; \
(oldroot)->next = (oldroot); \
(oldroot)->prev = (oldroot); \
} \
}
 
#define LL_TransferList(oldroot,newroot,next,prev) \
{ \
if ((oldroot)->prev != (oldroot)) \
{ \
(oldroot)->prev->next = (newroot); \
(oldroot)->next->prev = (newroot)->prev; \
(newroot)->prev->next = (oldroot)->next; \
(newroot)->prev = (oldroot)->prev; \
(oldroot)->next = (oldroot); \
(oldroot)->prev = (oldroot); \
} \
}
#define LL_ReverseList(root, type, next, prev) \
{ \
type *newend, *trav, *tprev; \
\
newend = (root)->next; \
for (trav = (root)->prev; trav != newend; trav = tprev) \
{ \
tprev = trav->prev; \
LL_MoveNode(trav, newend, next, prev); \
} \
}
 
#define LL_ReverseList(root,type,next,prev) \
{ \
type *newend,*trav,*tprev; \
\
newend = (root)->next; \
for(trav = (root)->prev; trav != newend; trav = tprev) \
{ \
tprev = trav->prev; \
LL_MoveNode(trav,newend,next,prev); \
} \
}
 
#define LL_RemoveNode(node, next, prev) \
{ \
(node)->prev->next = (node)->next; \
(node)->next->prev = (node)->prev; \
(node)->next = (node); \
(node)->prev = (node); \
}
 
#define LL_RemoveNode(node,next,prev) \
{ \
(node)->prev->next = (node)->next; \
(node)->next->prev = (node)->prev; \
(node)->next = (node); \
(node)->prev = (node); \
}
 
#define LL_SortedInsertion(rootnode, insertnode, next, prev, type, sortparm) \
{ \
type *hoya; \
\
hoya = (rootnode)->next; \
while ((hoya != (rootnode)) && ((insertnode)->sortparm > hoya->sortparm)) \
{ \
hoya = hoya->next; \
} \
LL_AddNode(hoya, (insertnode), next, prev); \
}
 
#define LL_SortedInsertion(rootnode,insertnode,next,prev,type,sortparm) \
{ \
type *hoya; \
\
hoya = (rootnode)->next; \
while((hoya != (rootnode)) && ((insertnode)->sortparm > hoya->sortparm)) \
{ \
hoya = hoya->next; \
} \
LL_AddNode(hoya,(insertnode),next,prev); \
}
#define LL_MoveNode(node, newroot, next, prev) \
{ \
LL_RemoveNode((node), next, prev); \
LL_AddNode((newroot), (node), next, prev); \
}
 
#define LL_MoveNode(node,newroot,next,prev) \
{ \
LL_RemoveNode((node),next,prev); \
LL_AddNode((newroot),(node),next,prev); \
}
#define LL_ListEmpty(list, next, prev) (((list)->next == (list)) && ((list)->prev == (list)))
 
#define LL_ListEmpty(list,next,prev) \
( \
((list)->next == (list)) && \
((list)->prev == (list)) \
)
#define LL_Free(list) Bfree(list)
#define LL_Reset(list, next, prev) (list)->next = (list)->prev = (list)
#define LL_New LL_CreateNewLinkedList
#define LL_Remove LL_RemoveNode
#define LL_Add LL_AddNode
#define LL_Empty LL_ListEmpty
#define LL_Move LL_MoveNode
 
#define LL_Free(list) Bfree(list)
#define LL_Reset(list,next,prev) (list)->next = (list)->prev = (list)
#define LL_New LL_CreateNewLinkedList
#define LL_Remove LL_RemoveNode
#define LL_Add LL_AddNode
#define LL_Empty LL_ListEmpty
#define LL_Move LL_MoveNode
 
 
#ifdef EXTERNC
};
#endif
/polymer/eduke32/source/jaudiolib/src/ll_man.h
28,49 → 28,40
(c) Copyright 1994 James R. Dose. All Rights Reserved.
**********************************************************************/
 
#ifndef __LL_MAN_H
#define __LL_MAN_H
#ifndef LL_MAN_H_
#define LL_MAN_H_
 
enum LL_Errors
{
LL_Warning = -2,
LL_Error = -1,
LL_Ok = 0
};
{
LL_Warning = -2,
LL_Error = -1,
LL_Ok = 0
};
 
typedef struct list
{
void *start;
void *end;
} list;
{
void *start;
void *end;
} list;
 
void LL_AddNode( char *node, char **head, char **tail, int32_t next, int32_t prev );
void LL_RemoveNode( char *node, char **head, char **tail, int32_t next, int32_t prev );
void LL_UnlockMemory( void );
int32_t LL_LockMemory( void );
void LL_AddNode(char *node, char **head, char **tail, int32_t next, int32_t prev);
void LL_RemoveNode(char *node, char **head, char **tail, int32_t next, int32_t prev);
void LL_UnlockMemory(void);
int32_t LL_LockMemory(void);
 
#define LL_AddToHead( type, listhead, node ) \
LL_AddNode( ( char * )( node ), \
( char ** )&( ( listhead )->start ), \
( char ** )&( ( listhead )->end ), \
( int32_t )&( ( type * ) 0 )->next, \
( int32_t )&( ( type * ) 0 )->prev )
#define LL_AddToHead(type, listhead, node) \
LL_AddNode((char *)(node), (char **)&((listhead)->start), (char **)&((listhead)->end), \
(int32_t) & ((type *)0)->next, (int32_t) & ((type *)0)->prev)
 
#define LL_AddToTail( type, listhead, node ) \
LL_AddNode( ( char * )( node ), \
( char ** )&( ( listhead )->end ), \
( char ** )&( ( listhead )->start ), \
( int32_t )&( ( type * ) 0 )->prev, \
( int32_t )&( ( type * ) 0 )->next )
#define LL_AddToTail(type, listhead, node) \
LL_AddNode((char *)(node), (char **)&((listhead)->end), (char **)&((listhead)->start), \
(int32_t) & ((type *)0)->prev, (int32_t) & ((type *)0)->next)
 
#define LL_Remove( type, listhead, node ) \
LL_RemoveNode( ( char * )( node ), \
( char ** )&( ( listhead )->start ), \
( char ** )&( ( listhead )->end ), \
( int32_t )&( ( type * ) 0 )->next, \
( int32_t )&( ( type * ) 0 )->prev )
#define LL_Remove(type, listhead, node) \
LL_RemoveNode((char *)(node), (char **)&((listhead)->start), (char **)&((listhead)->end), \
(int32_t) & ((type *)0)->next, (int32_t) & ((type *)0)->prev)
 
#define LL_NextNode( node ) ( ( node )->next )
#define LL_PreviousNode( node ) ( ( node )->prev )
#define LL_NextNode(node) ((node)->next)
#define LL_PreviousNode(node) ((node)->prev)
 
#endif
/polymer/eduke32/source/jaudiolib/src/multivoc.h
28,153 → 28,142
(c) Copyright 1993 James R. Dose. All Rights Reserved.
**********************************************************************/
 
#ifndef __MULTIVOC_H
#define __MULTIVOC_H
#ifndef MULTIVOC_H_
#define MULTIVOC_H_
 
#ifndef UNREFERENCED_PARAMETER
# define UNREFERENCED_PARAMETER(x) x=x
#define UNREFERENCED_PARAMETER(x) x = x
#endif
 
#ifdef _MSC_VER
# define inline __inline
#define inline __inline
#endif
 
#if defined __POWERPC__ || defined GEKKO
static inline uint16_t SWAP16(uint16_t s)
{
return (s >> 8) | (s << 8);
}
static inline uint16_t SWAP16(uint16_t s) { return (s >> 8) | (s << 8); }
static inline uint32_t SWAP32(uint32_t s)
{
return (s >> 24) | (s << 24) | ((s&0xff00) << 8) | ((s & 0xff0000) >> 8);
return (s >> 24) | (s << 24) | ((s & 0xff00) << 8) | ((s & 0xff0000) >> 8);
}
# define LITTLE16(s) SWAP16(s)
# define LITTLE32(s) SWAP32(s)
#define LITTLE16(s) SWAP16(s)
#define LITTLE32(s) SWAP32(s)
#else
# define LITTLE16
# define LITTLE32
#define LITTLE16
#define LITTLE32
#endif
 
#ifndef TRUE
# define TRUE ( 1 == 1 )
#define TRUE (1 == 1)
#endif
#ifndef FALSE
# define FALSE ( !TRUE )
#define FALSE (!TRUE)
#endif
 
#ifndef min
# define min(x,y) ((x) < (y) ? (x) : (y))
#define min(x, y) ((x) < (y) ? (x) : (y))
#endif
#ifndef max
# define max(x,y) ((x) > (y) ? (x) : (y))
#define max(x, y) ((x) > (y) ? (x) : (y))
#endif
 
#if defined(_MSC_VER)
# define strcasecmp _stricmp
# define strncasecmp _strnicmp
#define strcasecmp _stricmp
#define strncasecmp _strnicmp
#elif defined(__QNX__)
# define strcasecmp stricmp
# define strncasecmp strnicmp
#define strcasecmp stricmp
#define strncasecmp strnicmp
#endif
 
typedef enum
{
Unknown,
Raw,
VOC,
DemandFeed,
WAV,
Vorbis,
FLAC,
XA,
Unknown,
Raw,
VOC,
DemandFeed,
WAV,
Vorbis,
FLAC,
XA,
} wavedata;
 
#define MV_MINVOICEHANDLE 1
#define MV_MINVOICEHANDLE 1
 
extern int32_t MV_ErrorCode;
 
enum MV_Errors
{
MV_Warning = -2,
MV_Error = -1,
MV_Ok = 0,
MV_UnsupportedCard,
MV_NotInstalled,
MV_DriverError,
MV_NoVoices,
MV_NoMem,
MV_VoiceNotFound,
MV_InvalidVOCFile,
MV_InvalidWAVFile,
MV_InvalidVorbisFile,
MV_InvalidFLACFile,
MV_InvalidXAFile,
MV_InvalidMixMode,
MV_NullRecordFunction
};
{
MV_Warning = -2,
MV_Error = -1,
MV_Ok = 0,
MV_UnsupportedCard,
MV_NotInstalled,
MV_DriverError,
MV_NoVoices,
MV_NoMem,
MV_VoiceNotFound,
MV_InvalidVOCFile,
MV_InvalidWAVFile,
MV_InvalidVorbisFile,
MV_InvalidFLACFile,
MV_InvalidXAFile,
MV_InvalidMixMode,
MV_NullRecordFunction
};
 
extern void (*MV_Printf)(const char *fmt, ...);
const char *MV_ErrorString( int32_t ErrorNumber );
int32_t MV_VoicePlaying( int32_t handle );
int32_t MV_KillAllVoices( void );
int32_t MV_Kill( int32_t handle );
int32_t MV_VoicesPlaying( void );
int32_t MV_VoiceAvailable( int32_t priority );
int32_t MV_SetPitch( int32_t handle, int32_t pitchoffset );
int32_t MV_SetFrequency( int32_t handle, int32_t frequency );
int32_t MV_PauseVoice( int32_t handle, int32_t pause );
int32_t MV_EndLooping( int32_t handle );
int32_t MV_SetPan( int32_t handle, int32_t vol, int32_t left, int32_t right );
int32_t MV_Pan3D( int32_t handle, int32_t angle, int32_t distance );
void MV_SetReverb( int32_t reverb );
void MV_SetFastReverb( int32_t reverb );
int32_t MV_GetMaxReverbDelay( void );
int32_t MV_GetReverbDelay( void );
void MV_SetReverbDelay( int32_t delay );
//int32_t MV_SetMixMode( int32_t numchannels, int32_t samplebits );
//int32_t MV_StartPlayback( void );
//void MV_StopPlayback( void );
int32_t MV_StartDemandFeedPlayback( void ( *function )( char **ptr, uint32_t *length ),
int32_t rate, int32_t pitchoffset, int32_t vol, int32_t left, int32_t right,
int32_t priority, uint32_t callbackval );
int32_t MV_PlayRaw( char *ptr, uint32_t length,
char *loopstart, char *loopend, unsigned rate, int32_t pitchoffset,
int32_t vol, int32_t left, int32_t right, int32_t priority,
uint32_t callbackval );
int32_t MV_PlayWAV3D( char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval );
int32_t MV_PlayWAV( char *ptr, uint32_t length, int32_t loopstart, int32_t loopend,
int32_t pitchoffset, int32_t vol, int32_t left, int32_t right, int32_t priority,
uint32_t callbackval );
int32_t MV_PlayVOC3D( char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval );
int32_t MV_PlayVOC( char *ptr, uint32_t length, int32_t loopstart, int32_t loopend,
int32_t pitchoffset, int32_t vol, int32_t left, int32_t right, int32_t priority,
uint32_t callbackval );
int32_t MV_PlayVorbis3D( char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval );
int32_t MV_PlayVorbis( char *ptr, uint32_t length, int32_t loopstart, int32_t loopend,
int32_t pitchoffset, int32_t vol, int32_t left, int32_t right, int32_t priority,
uint32_t callbackval );
int32_t MV_PlayFLAC3D( char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval );
int32_t MV_PlayFLAC( char *ptr, uint32_t length, int32_t loopstart, int32_t loopend,
int32_t pitchoffset, int32_t vol, int32_t left, int32_t right, int32_t priority,
uint32_t callbackval );
int32_t MV_PlayXA3D( char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval );
int32_t MV_PlayXA( char *ptr, uint32_t length, int32_t loopstart, int32_t loopend,
int32_t pitchoffset, int32_t vol, int32_t left, int32_t right, int32_t priority,
uint32_t callbackval );
//void MV_CreateVolumeTable( int32_t index, int32_t volume, int32_t MaxVolume );
void MV_SetVolume( int32_t volume );
int32_t MV_GetVolume( void );
void MV_SetCallBack( void ( *function )( uint32_t ) );
void MV_SetReverseStereo( int32_t setting );
int32_t MV_GetReverseStereo( void );
int32_t MV_Init( int32_t soundcard, int32_t MixRate, int32_t Voices, int32_t numchannels,
int32_t samplebits, void * initdata );
int32_t MV_Shutdown( void );
const char *MV_ErrorString(int32_t ErrorNumber);
int32_t MV_VoicePlaying(int32_t handle);
int32_t MV_KillAllVoices(void);
int32_t MV_Kill(int32_t handle);
int32_t MV_VoicesPlaying(void);
int32_t MV_VoiceAvailable(int32_t priority);
int32_t MV_SetPitch(int32_t handle, int32_t pitchoffset);
int32_t MV_SetFrequency(int32_t handle, int32_t frequency);
int32_t MV_PauseVoice(int32_t handle, int32_t pause);
int32_t MV_EndLooping(int32_t handle);
int32_t MV_SetPan(int32_t handle, int32_t vol, int32_t left, int32_t right);
int32_t MV_Pan3D(int32_t handle, int32_t angle, int32_t distance);
void MV_SetReverb(int32_t reverb);
void MV_SetFastReverb(int32_t reverb);
int32_t MV_GetMaxReverbDelay(void);
int32_t MV_GetReverbDelay(void);
void MV_SetReverbDelay(int32_t delay);
// int32_t MV_SetMixMode( int32_t numchannels, int32_t samplebits );
// int32_t MV_StartPlayback( void );
// void MV_StopPlayback( void );
int32_t MV_StartDemandFeedPlayback(void (*function)(char **ptr, uint32_t *length), int32_t rate, int32_t pitchoffset,
int32_t vol, int32_t left, int32_t right, int32_t priority, uint32_t callbackval);
int32_t MV_PlayRaw(char *ptr, uint32_t length, char *loopstart, char *loopend, unsigned rate, int32_t pitchoffset,
int32_t vol, int32_t left, int32_t right, int32_t priority, uint32_t callbackval);
int32_t MV_PlayWAV3D(char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval);
int32_t MV_PlayWAV(char *ptr, uint32_t length, int32_t loopstart, int32_t loopend, int32_t pitchoffset, int32_t vol,
int32_t left, int32_t right, int32_t priority, uint32_t callbackval);
int32_t MV_PlayVOC3D(char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval);
int32_t MV_PlayVOC(char *ptr, uint32_t length, int32_t loopstart, int32_t loopend, int32_t pitchoffset, int32_t vol,
int32_t left, int32_t right, int32_t priority, uint32_t callbackval);
int32_t MV_PlayVorbis3D(char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle,
int32_t distance, int32_t priority, uint32_t callbackval);
int32_t MV_PlayVorbis(char *ptr, uint32_t length, int32_t loopstart, int32_t loopend, int32_t pitchoffset, int32_t vol,
int32_t left, int32_t right, int32_t priority, uint32_t callbackval);
int32_t MV_PlayFLAC3D(char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval);
int32_t MV_PlayFLAC(char *ptr, uint32_t length, int32_t loopstart, int32_t loopend, int32_t pitchoffset, int32_t vol,
int32_t left, int32_t right, int32_t priority, uint32_t callbackval);
int32_t MV_PlayXA3D(char *ptr, uint32_t length, int32_t loophow, int32_t pitchoffset, int32_t angle, int32_t distance,
int32_t priority, uint32_t callbackval);
int32_t MV_PlayXA(char *ptr, uint32_t length, int32_t loopstart, int32_t loopend, int32_t pitchoffset, int32_t vol,
int32_t left, int32_t right, int32_t priority, uint32_t callbackval);
// void MV_CreateVolumeTable( int32_t index, int32_t volume, int32_t MaxVolume );
void MV_SetVolume(int32_t volume);
int32_t MV_GetVolume(void);
void MV_SetCallBack(void (*function)(uint32_t));
void MV_SetReverseStereo(int32_t setting);
int32_t MV_GetReverseStereo(void);
int32_t MV_Init(int32_t soundcard, int32_t MixRate, int32_t Voices, int32_t numchannels, int32_t samplebits,
void *initdata);
int32_t MV_Shutdown(void);
int32_t MV_SetVoiceCallback(int32_t handle, uint32_t callbackval);
void MV_SetPrintf(void (*function)(const char *fmt, ...));
 
/polymer/eduke32/source/jaudiolib/src/pitch.h
28,8 → 28,8
(c) Copyright 1994 James R. Dose. All Rights Reserved.
**********************************************************************/
 
#ifndef __PITCH_H
#define __PITCH_H
#ifndef PITCH_H_
#define PITCH_H_
 
#include "inttypes.h"
 
/polymer/eduke32/source/jmact/_control.h
32,8 → 32,8
//
//****************************************************************************
 
#ifndef _control_private
#define _control_private
#ifndef control_private_h_
#define control_private_h_
#ifdef EXTERNC
{
#endif
78,24 → 78,23
// NORMAL axis scale
#define NORMALAXISSCALE 65536
 
#define BUTTONSET(x,value) (CONTROL_ButtonState |= ((uint64_t)value<<((uint64_t)(x))))
#define BUTTONCLEAR(x) (CONTROL_ButtonState &= ~((uint64_t)1<<((uint64_t)(x))))
#define BUTTONSET(x, value) (CONTROL_ButtonState |= ((uint64_t)value << ((uint64_t)(x))))
#define BUTTONCLEAR(x) (CONTROL_ButtonState &= ~((uint64_t)1 << ((uint64_t)(x))))
 
#define BUTTONHELDSET(x,value) (CONTROL_ButtonHeldState |= (uint64_t)(value<<((uint64_t)(x))))
#define BUTTONHELDSET(x, value) (CONTROL_ButtonHeldState |= (uint64_t)(value << ((uint64_t)(x))))
 
#define LIMITCONTROL(x)\
{\
if ((*x)>MAXCONTROLVALUE) \
{\
(*x) = MAXCONTROLVALUE;\
}\
if ((*x)<-MAXCONTROLVALUE) \
{\
(*x) = -MAXCONTROLVALUE;\
}\
#define LIMITCONTROL(x) \
{ \
if ((*x) > MAXCONTROLVALUE) \
{ \
(*x) = MAXCONTROLVALUE; \
} \
if ((*x) < -MAXCONTROLVALUE) \
{ \
(*x) = -MAXCONTROLVALUE; \
} \
}
#define SGN(x) \
( ( (x) > 0 ) ? 1 : ( (x) < 0 ) ? -1 : 0 )
#define SGN(x) (((x) > 0) ? 1 : ((x) < 0) ? -1 : 0)
 
//****************************************************************************
//
104,30 → 103,30
//****************************************************************************
 
typedef enum
{
motion_Left = -1,
motion_Up = -1,
motion_None = 0,
motion_Right = 1,
motion_Down = 1
} motion;
{
motion_Left = -1,
motion_Up = -1,
motion_None = 0,
motion_Right = 1,
motion_Down = 1
} motion;
 
 
typedef struct
{
int32_t joyMinX;
int32_t joyMinY;
int32_t threshMinX;
int32_t threshMinY;
int32_t threshMaxX;
int32_t threshMaxY;
int32_t joyMaxX;
int32_t joyMaxY;
int32_t joyMultXL;
int32_t joyMultYL;
int32_t joyMultXH;
int32_t joyMultYH;
} JoystickDef;
{
int32_t joyMinX;
int32_t joyMinY;
int32_t threshMinX;
int32_t threshMinY;
int32_t threshMaxX;
int32_t threshMaxY;
int32_t joyMaxX;
int32_t joyMaxY;
int32_t joyMultXL;
int32_t joyMultYL;
int32_t joyMultXH;
int32_t joyMultYH;
} JoystickDef;
 
// int32_t ThrottleMin;
// int32_t RudderMin;
144,40 → 143,40
 
 
typedef struct
{
uint8_t active ;
uint8_t used ;
uint8_t toggle ;
uint8_t buttonheld ;
int32_t cleared ;
} controlflags;
{
uint8_t active;
uint8_t used;
uint8_t toggle;
uint8_t buttonheld;
int32_t cleared;
} controlflags;
 
typedef struct
{
kb_scancode key1;
kb_scancode key2;
} controlkeymaptype;
{
kb_scancode key1;
kb_scancode key2;
} controlkeymaptype;
 
typedef struct
{
uint8_t singleclicked;
uint8_t doubleclicked;
uint16_t extra;
} controlbuttontype;
{
uint8_t singleclicked;
uint8_t doubleclicked;
uint16_t extra;
} controlbuttontype;
 
typedef struct
{
uint8_t analogmap;
uint8_t minmap;
uint8_t maxmap;
uint8_t extra;
} controlaxismaptype;
{
uint8_t analogmap;
uint8_t minmap;
uint8_t maxmap;
uint8_t extra;
} controlaxismaptype;
 
typedef struct
{
int32_t analog;
int32_t digital;
} controlaxistype;
{
int32_t analog;
int32_t digital;
} controlaxistype;
 
 
//***************************************************************************
/polymer/eduke32/source/jmact/_scrplib.h
29,8 → 29,8
 
// scrplib.h
 
#ifndef _scriplib_private
#define _scriplib_private
#ifndef scriplib_private_h_
#define scriplib_private_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/jmact/animlib.h
31,8 → 31,8
//
/////////////////////////////////////////////////////////////////////////////
 
#ifndef _animlib_public_
#define _animlib_public_
#ifndef animlib_public_h_
#define animlib_public_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/jmact/control.h
31,8 → 31,8
//
//***************************************************************************
 
#ifndef _control_public
#define _control_public
#ifndef control_public_h_
#define control_public_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/jmact/file_lib.h
24,8 → 24,8
*/
//-------------------------------------------------------------------------
 
#ifndef _file_lib_public
#define _file_lib_public
#ifndef file_lib_public_
#define file_lib_public_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/jmact/keyboard.h
25,8 → 25,8
*/
//-------------------------------------------------------------------------
 
#ifndef _keyboard_public
#define _keyboard_public
#ifndef keyboard_public_h_
#define keyboard_public_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/jmact/mouse.h
25,8 → 25,8
*/
//-------------------------------------------------------------------------
 
#ifndef __mouse_h
#define __mouse_h
#ifndef mouse_h_
#define mouse_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/jmact/scriplib.h
26,8 → 26,8
 
// scriplib.h
 
#ifndef _scriplib_public
#define _scriplib_public
#ifndef scriplib_public_h_
#define scriplib_public_h_
#ifdef EXTERNC
{
#endif
/polymer/eduke32/source/m32def.h
22,8 → 22,8
*/
//-------------------------------------------------------------------------
 
#ifndef _m32def_h_
#define _m32def_h_
#ifndef m32def_h_
#define m32def_h_
 
// the parsing routines aren't good at error recovery yet...
#define ABORTERRCNT 1
/polymer/eduke32/source/menus.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __menus_h__
#define __menus_h__
#ifndef menus_h_
#define menus_h_
 
#include "compat.h"
 
/polymer/eduke32/source/net.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __netplay_h__
#define __netplay_h__
#ifndef netplay_h_
#define netplay_h_
 
#include "enet/enet.h"
 
345,4 → 345,4
 
#endif
 
#endif // __netplay_h__
#endif // netplay_h_
/polymer/eduke32/source/osdcmds.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __osdcmds_h__
#define __osdcmds_h__
#ifndef osdcmds_h_
#define osdcmds_h_
 
struct osdcmd_cheatsinfo {
int32_t cheatnum; // -1 = none, else = see DoCheats()
44,5 → 44,5
extern const keydef_t ConsoleKeys[];
extern const char *const ConsoleButtons[];
 
#endif // __osdcmds_h__
#endif // osdcmds_h_
 
/polymer/eduke32/source/player.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __player_h__
#define __player_h__
#ifndef player_h_
#define player_h_
 
extern int32_t playerswhenstarted;
 
/polymer/eduke32/source/premap.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __premap_h__
#define __premap_h__
#ifndef premap_h_
#define premap_h_
 
typedef struct {
int32_t x1, y1;
/polymer/eduke32/source/quotes.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __quotes_h__
#define __quotes_h__
#ifndef quotes_h_
#define quotes_h_
 
#define MAXQUOTES 16384
#define MAXQUOTELEN 128
/polymer/eduke32/source/rts.h
26,8 → 26,8
//
//***************************************************************************
 
#ifndef __rts_public__
#define __rts_public__
#ifndef rts_public_
#define rts_public_
 
extern char rts_lumplockbyte[11];
 
/polymer/eduke32/source/savegame.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __savegame_h__
#define __savegame_h__
#ifndef savegame_h_
#define savegame_h_
 
#include "game.h"
 
/polymer/eduke32/source/sector.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __sector_h__
#define __sector_h__
#ifndef sector_h_
#define sector_h_
 
#include "gamevars.h"
#include "actors.h" // actor_t
/polymer/eduke32/source/sector_inline.c
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __sector_inline_c__
#define __sector_inline_c__
#ifndef sector_inline_c_
#define sector_inline_c_
 
#include "compat.h"
#include "build.h"
/polymer/eduke32/source/sector_inline.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __sector_inline_h__
#define __sector_inline_h__
#ifndef sector_inline_h_
#define sector_inline_h_
 
EXTERN_INLINE_HEADER int32_t G_CheckPlayerInSector(int32_t sect);
 
/polymer/eduke32/source/sounds.h
26,8 → 26,8
//
//****************************************************************************
 
#ifndef _sounds_public_
#define _sounds_public_
#ifndef sounds_public_h_
#define sounds_public_h_
 
#include "sounds_common.h"
 
/polymer/eduke32/source/sounds_mapster32.h
20,8 → 20,8
*/
//-------------------------------------------------------------------------
 
#ifndef __sounds_mapster32_h__
#define __sounds_mapster32_h__
#ifndef sounds_mapster32_h_
#define sounds_mapster32_h_
 
#include "build.h"
#include "sounds_common.h"