mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-07-08 00:02:58 +12:00
Fix shader compilation errors
This commit is contained in:
parent
58da6ea8a4
commit
ddc14cea09
3 changed files with 80 additions and 8 deletions
|
@ -388,7 +388,15 @@ void RendererGL::drawVertices(PICA::PrimType primType, std::span<const Vertex> v
|
|||
OpenGL::TriangleFan,
|
||||
OpenGL::Triangle,
|
||||
};
|
||||
std::cout << fragShaderGen.generate(regs);
|
||||
|
||||
std::string vs = fragShaderGen.getVertexShader(regs);
|
||||
std::string fs = fragShaderGen.generate(regs);
|
||||
std::cout << fs << "\n\n\n";
|
||||
|
||||
OpenGL::Program program;
|
||||
OpenGL::Shader vertShader({vs.c_str(), vs.size()}, OpenGL::Vertex);
|
||||
OpenGL::Shader fragShader({fs.c_str(), fs.size()}, OpenGL::Fragment);
|
||||
program.create({vertShader, fragShader});
|
||||
|
||||
const auto primitiveTopology = primTypes[static_cast<usize>(primType)];
|
||||
gl.disableScissor();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue