mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-08 16:05:56 +00:00
gl: Add extra checks around invalid render/compute passes
- These would have saved a lot of time debugging problems
This commit is contained in:
parent
5907a6a67d
commit
008bfa2cd2
2 changed files with 8 additions and 5 deletions
|
|
@ -58,6 +58,8 @@ namespace gl
|
|||
|
||||
if (!compiled)
|
||||
{
|
||||
ensure(!m_src.empty(), "Compute shader is not initialized!");
|
||||
|
||||
m_shader.create(::glsl::program_domain::glsl_compute_program, m_src);
|
||||
m_shader.compile();
|
||||
|
||||
|
|
@ -82,6 +84,7 @@ namespace gl
|
|||
|
||||
void compute_task::run(gl::command_context& cmd, u32 invocations_x, u32 invocations_y)
|
||||
{
|
||||
ensure(compiled && m_program.id() != GL_NONE);
|
||||
bind_resources();
|
||||
|
||||
cmd->use_program(m_program.id());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue