2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2025-11-25 22:22:05 +00:00

refactor: streamline IW4 asset loading

This commit is contained in:
Jan Laupetin
2025-08-05 01:13:58 +02:00
parent 81a67151b5
commit 6806337f46
49 changed files with 398 additions and 397 deletions

View File

@@ -5,6 +5,7 @@
#include "Game/IW4/Shader/LoaderVertexShaderIW4.h"
#include "Game/IW4/TechsetConstantsIW4.h"
#include "Shader/D3D9ShaderAnalyser.h"
#include "Shader/ShaderCommon.h"
#include "StateMap/StateMapReader.h"
#include "Techset/TechniqueFileReader.h"
#include "Techset/TechniqueStateMapCache.h"
@@ -460,7 +461,8 @@ namespace
if (pass.m_vertex_shader->Asset()->name && pass.m_vertex_shader->Asset()->name[0] == ',')
{
pass.m_vertex_shader_info = m_shader_info_cache.LoadShaderInfoFromDisk(m_search_path, GetVertexShaderFileName(vertexShaderName));
pass.m_vertex_shader_info =
m_shader_info_cache.LoadShaderInfoFromDisk(m_search_path, ::shader::GetFileNameForVertexShaderAssetName(vertexShaderName));
}
else
{
@@ -495,7 +497,8 @@ namespace
if (pass.m_pixel_shader->Asset()->name && pass.m_pixel_shader->Asset()->name[0] == ',')
{
pass.m_pixel_shader_info = m_shader_info_cache.LoadShaderInfoFromDisk(m_search_path, GetPixelShaderFileName(pixelShaderName));
pass.m_pixel_shader_info =
m_shader_info_cache.LoadShaderInfoFromDisk(m_search_path, ::shader::GetFileNameForPixelShaderAssetName(pixelShaderName));
}
else
{