首页 > 其他 > 详细

Raytracing On Compute Shader

时间:2020-05-10 16:02:07      阅读:64      评论:0      收藏:0      [点我收藏+]

Compute Shader GLSL Variables

uvec3 gl_NumWorkGroups    global work group size we gave to glDispatchCompute()
uvec3 gl_WorkGroupSize    local work group size we defined with layout
uvec3 gl_WorkGroupID    position of current invocation in global work group
uvec3 gl_LocalInvocationID    position of current invocation in local work group
uvec3 gl_GlobalInvocationID    unique index of current invocation in global work group
uint gl_LocalInvocationIndex    1d index representation of gl_LocalInvocationID

Execution:

方式渲染一个texture到full-screen quad

Creating Texture/Image创建纹理/Image:

 

 

 

REF:http://antongerdelan.net/opengl/compute.html

Raytracing On Compute Shader

原文:https://www.cnblogs.com/gearslogy/p/12863318.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!