mirror of
https://github.com/ClassiCube/ClassiCube.git
synced 2025-09-14 18:15:28 -04:00
Fix menus not rendering in OpenGL
This commit is contained in:
parent
af948f0aed
commit
2a0cc4cf8c
@ -1072,10 +1072,11 @@ static void* tmpData;
|
|||||||
static int tmpSize;
|
static int tmpSize;
|
||||||
|
|
||||||
static void* FastAllocTempMem(int size) {
|
static void* FastAllocTempMem(int size) {
|
||||||
if (size <= tmpSize) return tmpData;
|
if (size > tmpSize) {
|
||||||
Mem_Free(tmpData);
|
Mem_Free(tmpData);
|
||||||
|
tmpData = Mem_Alloc(size, 1, "Gfx_AllocTempMemory");
|
||||||
|
}
|
||||||
|
|
||||||
tmpData = Mem_Alloc(size, 1, "Gfx_AllocTempMemory");
|
|
||||||
tmpSize = size;
|
tmpSize = size;
|
||||||
return tmpData;
|
return tmpData;
|
||||||
}
|
}
|
||||||
|
@ -20,7 +20,7 @@ static GfxResourceID Particles_TexId, Particles_VB;
|
|||||||
static RNGState rnd;
|
static RNGState rnd;
|
||||||
static cc_bool particle_hitTerrain;
|
static cc_bool particle_hitTerrain;
|
||||||
|
|
||||||
void Particle_DoRender(Vec2* size, Vec3* pos, TextureRec* rec, PackedCol col, VertexP3fT2fC4b* v) {
|
void Particle_DoRender(const Vec2* size, const Vec3* pos, const TextureRec* rec, PackedCol col, VertexP3fT2fC4b* v) {
|
||||||
struct Matrix* view;
|
struct Matrix* view;
|
||||||
float sX, sY;
|
float sX, sY;
|
||||||
Vec3 centre;
|
Vec3 centre;
|
||||||
|
@ -18,7 +18,7 @@ struct Particle {
|
|||||||
};
|
};
|
||||||
|
|
||||||
/* http://www.opengl-tutorial.org/intermediate-tutorials/billboards-particles/billboards/ */
|
/* http://www.opengl-tutorial.org/intermediate-tutorials/billboards-particles/billboards/ */
|
||||||
void Particle_DoRender(Vec2* size, Vec3* pos, TextureRec* rec, PackedCol col, VertexP3fT2fC4b* vertices);
|
void Particle_DoRender(const Vec2* size, const Vec3* pos, const TextureRec* rec, PackedCol col, VertexP3fT2fC4b* vertices);
|
||||||
void Particles_Render(float t);
|
void Particles_Render(float t);
|
||||||
void Particles_Tick(struct ScheduledTask* task);
|
void Particles_Tick(struct ScheduledTask* task);
|
||||||
void Particles_BreakBlockEffect(IVec3 coords, BlockID oldBlock, BlockID block);
|
void Particles_BreakBlockEffect(IVec3 coords, BlockID oldBlock, BlockID block);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user