diff options
author | Yuri Kunde Schlesner <yuriks@yuriks.net> | 2016-12-18 01:16:02 +0100 |
---|---|---|
committer | Yuri Kunde Schlesner <yuriks@yuriks.net> | 2017-01-26 03:53:25 +0100 |
commit | 0e9081b97348c65029c96697443acb0dbbc58756 (patch) | |
tree | 58091caadcd6a11a96b48713c41ebf54716e1cc3 /src/video_core/shader/shader_interpreter.cpp | |
parent | VideoCore/Shader: Move per-batch ShaderEngine state into ShaderSetup (diff) | |
download | yuzu-0e9081b97348c65029c96697443acb0dbbc58756.tar yuzu-0e9081b97348c65029c96697443acb0dbbc58756.tar.gz yuzu-0e9081b97348c65029c96697443acb0dbbc58756.tar.bz2 yuzu-0e9081b97348c65029c96697443acb0dbbc58756.tar.lz yuzu-0e9081b97348c65029c96697443acb0dbbc58756.tar.xz yuzu-0e9081b97348c65029c96697443acb0dbbc58756.tar.zst yuzu-0e9081b97348c65029c96697443acb0dbbc58756.zip |
Diffstat (limited to 'src/video_core/shader/shader_interpreter.cpp')
-rw-r--r-- | src/video_core/shader/shader_interpreter.cpp | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/src/video_core/shader/shader_interpreter.cpp b/src/video_core/shader/shader_interpreter.cpp index e44abbf1d..c0c89b857 100644 --- a/src/video_core/shader/shader_interpreter.cpp +++ b/src/video_core/shader/shader_interpreter.cpp @@ -652,32 +652,31 @@ static void RunInterpreter(const ShaderSetup& setup, UnitState& state, DebugData } } -void InterpreterEngine::SetupBatch(ShaderSetup& setup) {} +void InterpreterEngine::SetupBatch(ShaderSetup& setup, unsigned int entry_point) { + ASSERT(entry_point < 1024); + setup.engine_data.entry_point = entry_point; +} MICROPROFILE_DECLARE(GPU_Shader); -void InterpreterEngine::Run(const ShaderSetup& setup, UnitState& state, - unsigned int entry_point) const { - ASSERT(entry_point < 1024); +void InterpreterEngine::Run(const ShaderSetup& setup, UnitState& state) const { MICROPROFILE_SCOPE(GPU_Shader); DebugData<false> dummy_debug_data; - RunInterpreter(setup, state, dummy_debug_data, entry_point); + RunInterpreter(setup, state, dummy_debug_data, setup.engine_data.entry_point); } DebugData<true> InterpreterEngine::ProduceDebugInfo(const ShaderSetup& setup, - const InputVertex& input, int num_attributes, - unsigned int entry_point) const { - ASSERT(entry_point < 1024); - + const InputVertex& input, + int num_attributes) const { UnitState state; DebugData<true> debug_data; // Setup input register table boost::fill(state.registers.input, Math::Vec4<float24>::AssignToAll(float24::Zero())); state.LoadInputVertex(input, num_attributes); - RunInterpreter(setup, state, debug_data, entry_point); + RunInterpreter(setup, state, debug_data, setup.engine_data.entry_point); return debug_data; } |