Skip to content

Commit

Permalink
a
Browse files Browse the repository at this point in the history
  • Loading branch information
Velaron committed Nov 7, 2023
1 parent 3ad3285 commit fb1fef1
Showing 1 changed file with 0 additions and 29 deletions.
29 changes: 0 additions & 29 deletions ref/gl/gl_rsurf.c
Original file line number Diff line number Diff line change
Expand Up @@ -2451,15 +2451,9 @@ static void R_AdditionalPasses( vboarray_t *vbo, int indexlen, void *indexarray,
}
}
<<<<<<< HEAD
#define MINIMIZE_UPLOAD
#define DISCARD_DLIGHTS
=======
/*
=====================
R_DrawLightmappedVBO
>>>>>>> parent of 29a64478 (ref_gl: add ability to skip uploading unused data (disabled))
static void R_DrawDlightedDecals( vboarray_t *vbo, msurface_t *newsurf, msurface_t *surf, int decalcount, texture_t *texture )
Expand Down Expand Up @@ -2623,8 +2617,6 @@ static void R_DrawVBODlights( vboarray_t *vbo, vbotexture_t *vbotex, texture_t *
// clear the block
LM_InitBlock();
<<<<<<< HEAD
=======
if( vbos.dlight_vbo )
{
Expand All @@ -2638,7 +2630,6 @@ static void R_DrawVBODlights( vboarray_t *vbo, vbotexture_t *vbotex, texture_t *
min_index = 0;
}
>>>>>>> parent of 29a64478 (ref_gl: add ability to skip uploading unused data (disabled))
// accumulate indexes for every dlighted surface until dlight block full
for( surf = newsurf = vbotex->dlightchain; surf; surf = surf->info->lightmapchain )
{
Expand Down Expand Up @@ -2670,8 +2661,6 @@ static void R_DrawVBODlights( vboarray_t *vbo, vbotexture_t *vbotex, texture_t *
// out of free block space. Draw all generated index array and clear it
// upload already generated block
<<<<<<< HEAD
=======
if( vbos.dlight_vbo )
{
pglBindBufferARB( GL_ARRAY_BUFFER_ARB, vbos.dlight_vbo );
Expand All @@ -2686,18 +2675,14 @@ static void R_DrawVBODlights( vboarray_t *vbo, vbotexture_t *vbotex, texture_t *
pglTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, BLOCK_SIZE, BLOCK_SIZE, 0, GL_RGBA, GL_UNSIGNED_BYTE, 0 );
>>>>>>> parent of 29a64478 (ref_gl: add ability to skip uploading unused data (disabled))
LM_UploadDynamicBlock();
#if !defined XASH_NANOGL || defined XASH_WES && XASH_EMSCRIPTEN // WebGL need to know array sizes
if( pglDrawRangeElements )
pglDrawRangeElements( GL_TRIANGLES, 0, vbo->array_len, dlightindex, GL_UNSIGNED_SHORT, dlightarray );
else
#endif
pglDrawElements( GL_TRIANGLES, dlightindex, GL_UNSIGNED_SHORT, dlightarray );
<<<<<<< HEAD
=======
max_index = 0;
>>>>>>> parent of 29a64478 (ref_gl: add ability to skip uploading unused data (disabled))
// draw decals that lighted with this lightmap
if( decalcount )
Expand Down Expand Up @@ -2815,16 +2800,8 @@ static void R_DrawVBODlights( vboarray_t *vbo, vbotexture_t *vbotex, texture_t *
vbos.dlight_tc[index][1] = surf->polys->verts[index - indexbase][6] - ( surf->light_t - info->dlight_t ) * ( 1.0f / (float)BLOCK_SIZE );
}
<<<<<<< HEAD
if( vbos.dlight_vbo )
{
pglBindBufferARB( GL_ARRAY_BUFFER_ARB, vbos.dlight_vbo );
pglBufferSubDataARB( GL_ARRAY_BUFFER_ARB, sizeof( vec2_t ) * indexbase, sizeof( vec2_t )* surf->polys->numverts, vbos.dlight_tc + indexbase );
}
=======
if( max_index < indexbase + surf->polys->numverts )
max_index = indexbase + surf->polys->numverts;
>>>>>>> parent of 29a64478 (ref_gl: add ability to skip uploading unused data (disabled))
// if surface has decals, build decal array
R_AddSurfaceDecalsDlight( surf, &decalcount );
Expand All @@ -2833,11 +2810,6 @@ static void R_DrawVBODlights( vboarray_t *vbo, vbotexture_t *vbotex, texture_t *
if( dlightindex )
{
<<<<<<< HEAD
// update block
LM_UploadDynamicBlock();
=======
pglTexImage2D( GL_TEXTURE_2D, 0, GL_RGBA, BLOCK_SIZE, BLOCK_SIZE, 0, GL_RGBA, GL_UNSIGNED_BYTE, 0 );
// update block
LM_UploadDynamicBlock();
Expand All @@ -2853,7 +2825,6 @@ static void R_DrawVBODlights( vboarray_t *vbo, vbotexture_t *vbotex, texture_t *
GL_SelectTexture( XASH_TEXTURE1 );
}
>>>>>>> parent of 29a64478 (ref_gl: add ability to skip uploading unused data (disabled))
// draw remaining array
#if !defined XASH_NANOGL || defined XASH_WES && XASH_EMSCRIPTEN // WebGL need to know array sizes
if( pglDrawRangeElements )
Expand Down

0 comments on commit fb1fef1

Please sign in to comment.