fix: forgot a free to match a malloc
This commit is contained in:
parent
60496cce50
commit
f497a24fe9
|
@ -820,6 +820,8 @@ static void generate(SubmissionTarget* target, const GLenum mode, const GLsizei
|
|||
genTriangleStrip(_glSubmissionTargetStart(target), count);
|
||||
break;
|
||||
default:
|
||||
printf("mode: 0x%08x\n", mode);
|
||||
fflush(stdout);
|
||||
assert(0 && "Not Implemented");
|
||||
}
|
||||
|
||||
|
|
12
GL/state.c
12
GL/state.c
|
@ -206,11 +206,13 @@ void _glUpdatePVRTextureContext(pvr_poly_cxt_t* context, GLshort textureUnit) {
|
|||
/* If we don't have complete mipmaps, and yet mipmapping was enabled, we disable texturing.
|
||||
* This is effectively what standard GL does (it renders a white texture)
|
||||
*/
|
||||
if(!_glIsMipmapComplete(tx1) && enableMipmaps) {
|
||||
context->txr.enable = PVR_TEXTURE_DISABLE;
|
||||
context->txr.base = 0;
|
||||
context->txr.format = 0;
|
||||
return;
|
||||
if(!_glIsMipmapComplete(tx1)) {
|
||||
filter = PVR_FILTER_BILINEAR;
|
||||
enableMipmaps = GL_FALSE;
|
||||
//context->txr.enable = PVR_TEXTURE_DISABLE;
|
||||
//context->txr.base = 0;
|
||||
//context->txr.format = 0;
|
||||
//return;
|
||||
}
|
||||
} else {
|
||||
if(tx1->minFilter == GL_LINEAR && tx1->magFilter == GL_LINEAR) {
|
||||
|
|
|
@ -923,6 +923,7 @@ void _glAllocateSpaceForMipmaps(TextureObject* active) {
|
|||
|
||||
/* If there was existing data, then copy it where it should go */
|
||||
memcpy(_glGetMipmapLocation(active,0), temp, size);
|
||||
free(temp);
|
||||
}
|
||||
|
||||
void APIENTRY glTexImage2D(GLenum target, GLint level, GLint internalFormat,
|
||||
|
|
2
Makefile
2
Makefile
|
@ -14,7 +14,7 @@ OBJS += containers/stack.o containers/named_array.o containers/aligned_vector.o
|
|||
SUBDIRS =
|
||||
|
||||
EXTRA_CFLAGS= -Wall -Wextra -Wstrict-aliasing=0
|
||||
KOS_CFLAGS += -ffast-math -O2 -funroll-loops -fsingle-precision-constant -Iinclude -funsafe-math-optimizations -DBUILD_LIBGL
|
||||
KOS_CFLAGS += -ffast-math -O2 -funroll-loops -fsingle-precision-constant -Iinclude -funsafe-math-optimizations -DBUILD_LIBGL $(EXTRA_CFLAGS)
|
||||
#KOS_CFLAGS += -O1 -mlra -Iinclude -DBUILD_LIBGL -Wall -Wextra
|
||||
#GCC5_FLAGS = -mfsca -mfsrra -mlra
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user