0
0
Fork 0
mirror of https://github.com/id-Software/DOOM-3-BFG.git synced 2025-03-15 15:11:29 +00:00

Merge branch 'master' into 635-nvrhi2

This commit is contained in:
Robert Beckebans 2022-06-26 10:27:45 +02:00
commit cd41a6b785
7 changed files with 40 additions and 10 deletions
doomclassic/doom
neo

View file

@ -66,9 +66,9 @@ void D_PageDrawer (void);
void D_AdvanceDemo (void); void D_AdvanceDemo (void);
void D_StartTitle (void); void D_StartTitle (void);
#define R_OK 0x01 //#define R_OK 0x01
#define X_OK 0x02 //#define X_OK 0x02
#define W_OK 0x04 //#define W_OK 0x04
int access(char* name, int val); int access(char* name, int val);

View file

@ -408,7 +408,7 @@ This is an out-of-sequence screen update, not the normal game rendering
// DG: added possibility to *not* release mouse in UpdateScreen(), it fucks up the view angle for screenshots // DG: added possibility to *not* release mouse in UpdateScreen(), it fucks up the view angle for screenshots
void idCommonLocal::UpdateScreen( bool captureToImage, bool releaseMouse ) void idCommonLocal::UpdateScreen( bool captureToImage, bool releaseMouse )
{ {
if( insideUpdateScreen ) if( insideUpdateScreen || com_shuttingDown )
{ {
return; return;
} }

View file

@ -2207,6 +2207,24 @@ void MapPolygonMesh::ConvertFromBrush( const idMapBrush* mapBrush, int entityNum
st.x = ( xyz * texVec[0].ToVec3() ) + texVec[0][3]; st.x = ( xyz * texVec[0].ToVec3() ) + texVec[0][3];
st.y = ( xyz * texVec[1].ToVec3() ) + texVec[1][3]; st.y = ( xyz * texVec[1].ToVec3() ) + texVec[1][3];
// support Valve 220 projection
if( mapSide->GetProjectionType() == idMapBrushSide::PROJECTION_VALVE220 )
{
const idMaterial* material = declManager->FindMaterial( mapSide->GetMaterial() );
idVec2i texSize = mapSide->GetTextureSize();
idImage* image = material->GetEditorImage();
if( image != NULL )
{
texSize.x = image->GetUploadWidth();
texSize.y = image->GetUploadHeight();
}
st.x /= texSize[0];
st.y /= texSize[1];
}
// flip y // flip y
//st.y = 1.0f - st.y; //st.y = 1.0f - st.y;

View file

@ -239,11 +239,11 @@ struct stencilStage_t
// (if either Pass, Fail or ZFail is set to replace). // (if either Pass, Fail or ZFail is set to replace).
byte ref = 0; byte ref = 0;
// An 8 bit mask as an 0255 integer, used when comparing the reference value with the contents of the buffer // An 8 bit mask as an 0<EFBFBD>255 integer, used when comparing the reference value with the contents of the buffer
// (referenceValue & readMask) comparisonFunction (stencilBufferValue & readMask). // (referenceValue & readMask) comparisonFunction (stencilBufferValue & readMask).
byte readMask = 255; byte readMask = 255;
// An 8 bit mask as an 0255 integer, used when writing to the buffer.Note that, like other write masks, // An 8 bit mask as an 0<EFBFBD>255 integer, used when writing to the buffer.Note that, like other write masks,
// it specifies which bits of stencil buffer will be affected by write // it specifies which bits of stencil buffer will be affected by write
// (i.e.WriteMask 0 means that no bits are affected and not that 0 will be written). // (i.e.WriteMask 0 means that no bits are affected and not that 0 will be written).
byte writeMask = 255; byte writeMask = 255;

View file

@ -609,7 +609,7 @@ static const cgShaderDef_t cg_renderprogs[] =
" *\n" " *\n"
" * The shader has three passes, chained together as follows:\n" " * The shader has three passes, chained together as follows:\n"
" *\n" " *\n"
" * |input|------------------·\n" " * |input|------------------\n"
" * v |\n" " * v |\n"
" * [ SMAA*EdgeDetection ] |\n" " * [ SMAA*EdgeDetection ] |\n"
" * v |\n" " * v |\n"
@ -619,7 +619,7 @@ static const cgShaderDef_t cg_renderprogs[] =
" * v |\n" " * v |\n"
" * |blendTex| |\n" " * |blendTex| |\n"
" * v |\n" " * v |\n"
" * [ SMAANeighborhoodBlending ] <------·\n" " * [ SMAANeighborhoodBlending ] <------\n"
" * v\n" " * v\n"
" * |output|\n" " * |output|\n"
" *\n" " *\n"
@ -2072,7 +2072,7 @@ static const cgShaderDef_t cg_renderprogs[] =
"}\n" "}\n"
"\n" "\n"
"// Fresnel term F( v, h )\n" "// Fresnel term F( v, h )\n"
"// Fnone( v, h ) = F(0°) = specularColor\n" "// Fnone( v, h ) = F(0) = specularColor\n"
"half3 Fresnel_Schlick( half3 specularColor, half vDotN )\n" "half3 Fresnel_Schlick( half3 specularColor, half vDotN )\n"
"{\n" "{\n"
" return specularColor + ( 1.0 - specularColor ) * pow( 1.0 - vDotN, 5.0 );\n" " return specularColor + ( 1.0 - specularColor ) * pow( 1.0 - vDotN, 5.0 );\n"

View file

@ -1708,8 +1708,12 @@ sysEvent_t Sys_GetEvent()
common->Warning( "unknown user event %u", ev.user.code ); common->Warning( "unknown user event %u", ev.user.code );
} }
continue; // just handle next event continue; // just handle next event
case SDL_KEYMAPCHANGED:
continue; // just handle next event
default: default:
common->Warning( "unknown event %u", ev.type ); common->Warning( "unknown event %u = %#x", ev.type, ev.type );
continue; // just handle next event continue; // just handle next event
} }
} }

View file

@ -409,6 +409,14 @@ void Dmap( const idCmdArgs& args )
idStr generated = va( "generated/%s.bproc", dmapGlobals.mapFileBase ); idStr generated = va( "generated/%s.bproc", dmapGlobals.mapFileBase );
fileSystem->RemoveFile( generated.c_str() ); fileSystem->RemoveFile( generated.c_str() );
// delete any old generated binary cm files
generated = va( "generated/%s.bcm", dmapGlobals.mapFileBase );
fileSystem->RemoveFile( generated.c_str() );
// delete any old ASCII collision files
idStr::snPrintf( path, sizeof( path ), "%s.cm", dmapGlobals.mapFileBase );
fileSystem->RemoveFile( path );
// //
// start from scratch // start from scratch
// //