mirror of
https://github.com/id-Software/DOOM-3-BFG.git
synced 2025-05-30 16:31:10 +00:00
First time Vulkan can render a map without light interactions
This commit is contained in:
parent
2f8413b2ee
commit
49eb54d1ad
12 changed files with 167 additions and 134 deletions
|
@ -1195,10 +1195,10 @@ GENERAL INTERACTION RENDERING
|
|||
*/
|
||||
|
||||
const int INTERACTION_TEXUNIT_BUMP = 0;
|
||||
const int INTERACTION_TEXUNIT_FALLOFF = 1;
|
||||
const int INTERACTION_TEXUNIT_PROJECTION = 2;
|
||||
const int INTERACTION_TEXUNIT_DIFFUSE = 3;
|
||||
const int INTERACTION_TEXUNIT_SPECULAR = 4;
|
||||
const int INTERACTION_TEXUNIT_SPECULARMIX = 1;
|
||||
const int INTERACTION_TEXUNIT_BASECOLOR = 2;
|
||||
const int INTERACTION_TEXUNIT_FALLOFF = 3;
|
||||
const int INTERACTION_TEXUNIT_PROJECTION = 4;
|
||||
const int INTERACTION_TEXUNIT_SHADOWMAPS = 5;
|
||||
const int INTERACTION_TEXUNIT_JITTER = 6;
|
||||
|
||||
|
@ -1318,14 +1318,14 @@ void idRenderBackend::DrawSingleInteraction( drawInteraction_t* din )
|
|||
GL_SelectTexture( INTERACTION_TEXUNIT_BUMP );
|
||||
din->bumpImage->Bind();
|
||||
|
||||
// texture 3 is the per-surface diffuse map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_DIFFUSE );
|
||||
din->diffuseImage->Bind();
|
||||
|
||||
// texture 4 is the per-surface specular map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_SPECULAR );
|
||||
// texture 1 is the per-surface specular map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_SPECULARMIX );
|
||||
din->specularImage->Bind();
|
||||
|
||||
// texture 2 is the per-surface diffuse map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_BASECOLOR );
|
||||
din->diffuseImage->Bind();
|
||||
|
||||
DrawElementsWithCounters( din->surf );
|
||||
}
|
||||
|
||||
|
@ -1779,14 +1779,14 @@ void idRenderBackend::RenderInteractions( const drawSurf_t* surfList, const view
|
|||
GL_SelectTexture( INTERACTION_TEXUNIT_BUMP );
|
||||
surfaceShader->GetFastPathBumpImage()->Bind();
|
||||
|
||||
// texture 3 is the per-surface diffuse map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_DIFFUSE );
|
||||
surfaceShader->GetFastPathDiffuseImage()->Bind();
|
||||
|
||||
// texture 4 is the per-surface specular map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_SPECULAR );
|
||||
// texture 1 is the per-surface specular map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_SPECULARMIX );
|
||||
surfaceShader->GetFastPathSpecularImage()->Bind();
|
||||
|
||||
// texture 2 is the per-surface diffuse map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_BASECOLOR );
|
||||
surfaceShader->GetFastPathDiffuseImage()->Bind();
|
||||
|
||||
DrawElementsWithCounters( surf );
|
||||
|
||||
renderLog.CloseBlock();
|
||||
|
@ -2160,14 +2160,14 @@ void idRenderBackend::AmbientPass( const drawSurf_t* const* drawSurfs, int numDr
|
|||
GL_SelectTexture( INTERACTION_TEXUNIT_BUMP );
|
||||
surfaceMaterial->GetFastPathBumpImage()->Bind();
|
||||
|
||||
// texture 3 is the per-surface diffuse map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_DIFFUSE );
|
||||
surfaceMaterial->GetFastPathDiffuseImage()->Bind();
|
||||
|
||||
// texture 4 is the per-surface specular map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_SPECULAR );
|
||||
// texture 1 is the per-surface specular map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_SPECULARMIX );
|
||||
surfaceMaterial->GetFastPathSpecularImage()->Bind();
|
||||
|
||||
// texture 2 is the per-surface diffuse map
|
||||
GL_SelectTexture( INTERACTION_TEXUNIT_BASECOLOR );
|
||||
surfaceMaterial->GetFastPathDiffuseImage()->Bind();
|
||||
|
||||
DrawElementsWithCounters( drawSurf );
|
||||
|
||||
renderLog.CloseBlock();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue