Fixed missing 16 byte alignment on 32 bit Linux for SSE structs.

This commit is contained in:
Robert Beckebans 2012-12-15 14:53:11 +01:00
parent d7888cf99d
commit b7d3481f57
2 changed files with 20 additions and 15 deletions

View file

@ -116,13 +116,9 @@ If you have questions concerning this license or the applicable additional terms
#define _alloca alloca
// DG: mingw/GCC (and probably clang) support
#define ALIGN16( x ) x __attribute__ ((aligned (16)))
// FIXME: change ALIGNTYPE* ?
#define ALIGNTYPE16
#define ALIGNTYPE128
// DG end
#define ALIGNTYPE16 __attribute__ ((aligned (16)))
#define ALIGNTYPE128 __attribute__ ((aligned (128)))
#define FORMAT_PRINTF( x )

View file

@ -75,16 +75,25 @@ struct decalProjectionParms_t
bool force;
};
// RB begin
#if defined(_WIN32)
ALIGNTYPE16 struct decal_t
{
ALIGNTYPE16 idDrawVert verts[MAX_DECAL_VERTS];
ALIGNTYPE16 triIndex_t indexes[MAX_DECAL_INDEXES];
float vertDepthFade[MAX_DECAL_VERTS];
int numVerts;
int numIndexes;
int startTime;
const idMaterial* material;
};
#endif
struct decal_t
{
ALIGNTYPE16 idDrawVert verts[MAX_DECAL_VERTS];
ALIGNTYPE16 triIndex_t indexes[MAX_DECAL_INDEXES];
float vertDepthFade[MAX_DECAL_VERTS];
int numVerts;
int numIndexes;
int startTime;
const idMaterial* material;
}
#if !defined(_WIN32)
ALIGNTYPE16
#endif
// RB end
;
class idRenderModelDecal
{