Files
WickedEngine/WickedEngine/CommonInclude.h
T
Turanszki Janos 4fcf2020af added linux build
2020-06-13 19:38:49 +01:00

37 lines
1.2 KiB
C++

#ifndef WICKEDENGINE_COMMONINCLUDE_H
#define WICKEDENGINE_COMMONINCLUDE_H
// This is a helper include file pasted into all engine headers try to keep it minimal!
// Do not include engine features in this file!
#include <cstdlib>
#include <cstring>
#include <cstdint>
#if __has_include("DirectXMath.h")
// In this case, DirectXMath is coming from Windows SDK.
// It is better to use this on Windows as some Windows libraries could depend on the same
// DirectXMath headers
#include <DirectXMath.h>
#include <DirectXPackedVector.h>
#include <DirectXCollision.h>
#else
// In this case, DirectXMath is coming from supplied source code
// On platforms that don't have Windows SDK, the source code for DirectXMath is provided
// as part of the engine utilities
#include "Utility/DirectXMath.h"
#include "Utility/DirectXPackedVector.h"
#include "Utility/DirectXCollision.h"
#endif
using namespace DirectX;
using namespace DirectX::PackedVector;
static const XMFLOAT4X4 IDENTITYMATRIX = XMFLOAT4X4(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);
#define arraysize(a) (sizeof(a) / sizeof(a[0]))
#define NOMINMAX
#define ALIGN_16 void* operator new(size_t i){return _mm_malloc(i, 16);} void operator delete(void* p){_mm_free(p);}
#endif //WICKEDENGINE_COMMONINCLUDE_H