Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17825

Questions about compute coverage in shader

$
0
0
I googled around but are unable to find source code or details of implementation. What keywords should I search for this topic? Things I would like to know: A. How to ensure that partially covered pixels are rasterized? Apparently by expanding each triangle by 1 pixel or so, rasterization problem is almost solved. But it will result in an unindexable triangle list without tons of overlaps. Will it incur a large performance penalty? B. A-buffer like bitmask needs a read-modiry-write operation. How to ensure proper synchronizations in GLSL? GLSL seems to only allow int32 atomics on image. C. Is there some simple ways to estimate coverage on-the-fly? In case I am to draw 2D shapes onto an exisitng target: 1. A multi-pass whatever-buffer seems overkill. 2. Multisampling could cost a lot memory though all I need is better coverage. Besides, I have to blit twice, if draw target is not multisampled.

Viewing all articles
Browse latest Browse all 17825

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>