Showing the changes to libraries/render-utils/src/GeometryCache.cpp (1 of 5 files). Show all
Unified · Split
| @@ -35,7 +35,7 @@ · 34 unmodified lines | ||
| 35 | 35 | #include "simple_vert.h" |
| 36 | 36 | #include "simple_textured_frag.h" |
| 37 | 37 | #include "simple_textured_unlit_frag.h" |
| 38 | −#include "simple_srgb_textured_unlit_no_dst_alpha_frag.h" | |
| 38 | +#include "simple_srgb_textured_unlit_no_tex_alpha_frag.h" | |
| 39 | 39 | #include "glowLine_vert.h" |
| 40 | 40 | #include "glowLine_geom.h" |
| 41 | 41 | #include "glowLine_frag.h" |
| @@ -1749,25 +1749,25 @@ inline bool operator==(const SimpleProgramKey& a, const SimpleProgramKey& b) { · 1707 unmodified lines | ||
| 1749 | 1749 | return a.getRaw() == b.getRaw(); |
| 1750 | 1750 | } |
| 1751 | 1751 | |
| 1752 | −void GeometryCache::bindSimpleSRGBTexturedUnlitNoDstAlphaProgram(gpu::Batch& batch) { | |
| 1753 | − batch.setPipeline(getSimpleSRGBTexturedUnlitNoDstAlphaPipeline()); | |
| 1752 | +void GeometryCache::bindSimpleSRGBTexturedUnlitNoTexAlphaProgram(gpu::Batch& batch) { | |
| 1753 | + batch.setPipeline(getSimpleSRGBTexturedUnlitNoTexAlphaPipeline()); | |
| 1754 | 1754 | // Set a default normal map |
| 1755 | 1755 | batch.setResourceTexture(render::ShapePipeline::Slot::MAP::NORMAL_FITTING, |
| 1756 | 1756 | DependencyManager::get<TextureCache>()->getNormalFittingTexture()); |
| 1757 | 1757 | } |
| 1758 | 1758 | |
| 1759 | −gpu::PipelinePointer GeometryCache::getSimpleSRGBTexturedUnlitNoDstAlphaPipeline() { | |
| 1759 | +gpu::PipelinePointer GeometryCache::getSimpleSRGBTexturedUnlitNoTexAlphaPipeline() { | |
| 1760 | 1760 | // Compile the shaders, once |
| 1761 | 1761 | static std::once_flag once; |
| 1762 | 1762 | std::call_once(once, [&]() { |
| 1763 | 1763 | auto VS = gpu::Shader::createVertex(std::string(simple_vert)); |
| 1764 | − auto PS = gpu::Shader::createPixel(std::string(simple_srgb_textured_unlit_no_dst_alpha_frag)); | |
| 1764 | + auto PS = gpu::Shader::createPixel(std::string(simple_srgb_textured_unlit_no_tex_alpha_frag)); | |
| 1765 | 1765 | |
| 1766 | − _simpleSRGBTexturedUnlitNoDstAlphaShader = gpu::Shader::createProgram(VS, PS); | |
| 1766 | + _simpleSRGBTexturedUnlitNoTexAlphaShader = gpu::Shader::createProgram(VS, PS); | |
| 1767 | 1767 | |
| 1768 | 1768 | gpu::Shader::BindingSet slotBindings; |
| 1769 | 1769 | slotBindings.insert(gpu::Shader::Binding(std::string("normalFittingMap"), render::ShapePipeline::Slot::MAP::NORMAL_FITTING)); |
| 1770 | − gpu::Shader::makeProgram(*_simpleSRGBTexturedUnlitNoDstAlphaShader, slotBindings); | |
| 1770 | + gpu::Shader::makeProgram(*_simpleSRGBTexturedUnlitNoTexAlphaShader, slotBindings); | |
| 1771 | 1771 | auto state = std::make_shared<gpu::State>(); |
| 1772 | 1772 | state->setCullMode(gpu::State::CULL_NONE); |
| 1773 | 1773 | state->setDepthTest(true, true, gpu::LESS_EQUAL); |
| @@ -1775,10 +1775,10 @@ gpu::PipelinePointer GeometryCache::getSimpleSRGBTexturedUnlitNoDstAlphaPipeline · 1 unmodified line | ||
| 1775 | 1775 | gpu::State::SRC_ALPHA, gpu::State::BLEND_OP_ADD, gpu::State::INV_SRC_ALPHA, |
| 1776 | 1776 | gpu::State::FACTOR_ALPHA, gpu::State::BLEND_OP_ADD, gpu::State::ONE); |
| 1777 | 1777 | |
| 1778 | − _simpleSRGBTexturedUnlitNoDstAlphaPipeline = gpu::Pipeline::create(_simpleSRGBTexturedUnlitNoDstAlphaShader, state); | |
| 1778 | + _simpleSRGBTexturedUnlitNoTexAlphaPipeline = gpu::Pipeline::create(_simpleSRGBTexturedUnlitNoTexAlphaShader, state); | |
| 1779 | 1779 | }); |
| 1780 | 1780 | |
| 1781 | − return _simpleSRGBTexturedUnlitNoDstAlphaPipeline; | |
| 1781 | + return _simpleSRGBTexturedUnlitNoTexAlphaPipeline; | |
| 1782 | 1782 | } |
| 1783 | 1783 | |
| 1784 | 1784 | void GeometryCache::bindSimpleProgram(gpu::Batch& batch, bool textured, bool culled, bool unlit, bool depthBiased) { |