[osg-users] glMemoryBarrier

44 views
Skip to first unread message

Tyler Durden

unread,
Sep 24, 2018, 4:19:16 AM9/24/18
to osg-...@lists.openscenegraph.org
Hi,

I have two compute shader and i need that second cs must wait until first cs finished his work. Do i have to use memory barriers between each dispatch compute invocation? How can i invoke glMemoryBarrier in openscenegraph?

Thank you!

Cheers,
Tyler

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=74964#74964





_______________________________________________
osg-users mailing list
osg-...@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Paweł Księżopolski

unread,
Sep 24, 2018, 7:14:00 AM9/24/18
to osg-...@lists.openscenegraph.org

sergio2k18 wrote:
>
> I have two compute shader and i need that second cs must wait until first cs finished his work. Do i have to use memory barriers between each dispatch compute invocation? How can i invoke glMemoryBarrier in openscenegraph?
>


You certainly should use memory barrier in this case.

In osggpucull example there is InvokeMemoryBarrier draw callback, that you may connect to your osg::DispatchCompute.

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=74966#74966
Reply all
Reply to author
Forward
0 new messages