Skip to content

Commit

Permalink
check compute binding resource limit
Browse files Browse the repository at this point in the history
  • Loading branch information
junjie020 committed Jan 22, 2024
1 parent 58c9027 commit 40bf332
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pkg/ant.render/render_system/render_system.lua
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,13 @@ function render_sys:device_check()
error(("need device support 16 texture samplers: %d"):format(caps.limits.maxTextureSamplers))
end

--TODO: need refactor compute shading code, 8 compute binding resource will be enough
if caps.limits.maxComputeBindings < 16 then
error(("need device support 16 compute sampler bindings: %d"):format(caps.limits.maxCounputeBindings))
end

if not caps.formats.RGBA8["2D_SRGB"] then
error("device framebuffer format RGBA8_SRGB should be supported.")
error("need device framebuffer format RGBA8_SRGB should be supported.")
end

if not caps.supported.DRAW_INDIRECT then
Expand Down

0 comments on commit 40bf332

Please sign in to comment.