Skip to content

Commit

Permalink
Workaround core context issues
Browse files Browse the repository at this point in the history
  • Loading branch information
mittorn committed Oct 5, 2023
1 parent f684544 commit a9ee916
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion ref/gl/gl_image.c
Original file line number Diff line number Diff line change
Expand Up @@ -1418,7 +1418,7 @@ static gl_texture_t *GL_AllocTexture( const char *name, texFlags_t flags )
// copy initial params
Q_strncpy( tex->name, name, sizeof( tex->name ));

if( FBitSet( flags, TF_SKYSIDE ))
if( FBitSet( flags, TF_SKYSIDE ) && glConfig.context != CONTEXT_TYPE_GL_CORE )
tex->texnum = tr.skyboxbasenum++;
else
{
Expand Down
7 changes: 2 additions & 5 deletions ref/gl/gl_warp.c
Original file line number Diff line number Diff line change
Expand Up @@ -761,11 +761,8 @@ void EmitWaterPolys( msurface_t *warp, qboolean reverse )
float s, t, os, ot;
glpoly_t *p;
int i;
#ifndef XASH_GLES
const qboolean useQuads = FBitSet( warp->flags, SURF_DRAWTURB_QUADS );
#else
const qboolean useQuads = false; // TODO: figure out why
#endif

const qboolean useQuads = FBitSet( warp->flags, SURF_DRAWTURB_QUADS ) && glConfig.context == CONTEXT_TYPE_GL;

if( !warp->polys ) return;

Expand Down

0 comments on commit a9ee916

Please sign in to comment.