What if you AA'ed by......

Apologies for blatent tiler promotion but.... :idea:

Say I have my 32x16 tile and I am rasterising it. The Rasteriser determines which pixels a triangle lay under. So have another 32x16 buffer corresponding to rendered pixels that the rasteriser increments for each pixel under the current triangle.

So in the end, when all the triangles are rasterised, you will have a buffer that is mostly 1's, but at the triangle edges will be 2's, and at multiple triangle intersections will be greater.

Now the tiler has the job of rendering the scene. The new buffer can be used to determine how many AA samples must be taken per pixel. Where there is a 1 you only need 1 because you are inside a triangle. With a 2 you need more, one from either triangle. Where there is a triangle fan you might have 12 triangles under the same pixel, so take 12 samples - or up to an upper limit.

This buffer could of course be multiplied according to what kind of AA quality you desire. Double all the numbers in the buffer then subtract 1 and you have a higher level of edge AA'ing but no more AA'ing inside the triangle.

There is the possible problem of 'I need to take 3 samples on this pixel, where do I take them from'. Instead of just a preset grid; perhaps have another component of the buffer which points to sample positions determined by the rasteriser.

Picture a square bisected by a line (the pixel by the tri boundary). You have a number of possible results.

2 triangles (top left to bot right)
2 rectangles (across or down the middle)
1 triangle and 1 triangle+rhombus (somewhere inbetween)

Determine the most centre point of these shapes and you have your sample position.

Determine the area of the shapes produced by the pixel bi-section and you have the information you need for correct weighting of your AA sample blend coefficient.


What do you think? Genius or Penius?

Dave
 
First of all, assuming standard rasterization, two or more triangles will only hit a single pixel if they overlap, and in that case, it is pretty likely that one of them completely covers the other(s). You would have to add to the count for any pixels where the triangle was closer than x units from the pixel center.

The other problem is that even if you know that two triangles will contribute to a given pixel how to distribute the samples is non-trivial. I'm sure you'll find that more AA-samples make even a single white triangle on a black backghround look better.

It wuld probably be easier to keep the tile being rasterised in some sort of embedded memory and use supersampling.
 
"It wuld probably be easier to keep the tile being rasterised in some sort of embedded memory and use supersampling."

lol of course it would, thats the way the KYRO/Neon250 series AA'ed.

In a standard rasteriser you point bout overlapping triangles will be true, but it would not be such a significant modification for it to increment by 1 in the AA buffer for every pixel it lies underneath. I cant say that with technical expertise but desn't sound like a major problem to me, obviously the different rasterisation info will be no good for the renderer tho so either two versions must be calced at once or one version calced from tother.
 
OH and thanks for seeing right through me and pointing out what I am *really* interested in Ingenu :LOL:

That pdf doesn't specifically say much about AA'ing though.
 
Maybe I didn't understand correctly, but if you've already rasterized the scene to get the AA count buffer how do you propose to get the AA samples? Would the vertex data be kept around for a second rasterization pass? If so you might be re-rasterizing many triangles that won't contribute to AA pixels. For a scene without a lot of edge pixels this could be very inefficient.
 
Dave B(TotalVR) said:
OH and thanks for seeing right through me and pointing out what I am *really* interested in Ingenu :LOL:

That pdf doesn't specifically say much about AA'ing though.

You're welcome.
Part "5 Discontinuity Edges" and "5.2 Application to Adaptive Supersampling" talks about supersampling edges only, for higher performance, isn't it what you wanted to do with your method ?
 
Ingenu said:
Dave B(TotalVR) said:
OH and thanks for seeing right through me and pointing out what I am *really* interested in Ingenu :LOL:

That pdf doesn't specifically say much about AA'ing though.

You're welcome.
Part "5 Discontinuity Edges" and "5.2 Application to Adaptive Supersampling" talks about supersampling edges only, for higher performance, isn't it what you wanted to do with your method ?

Probably stupid question: isn't Acceleon using MatrixAA and doesn't Delaystreams have a problem with stenciling?
 
Ingenu said:
Dave B(TotalVR) said:
OH and thanks for seeing right through me and pointing out what I am *really* interested in Ingenu :LOL:

That pdf doesn't specifically say much about AA'ing though.

You're welcome.
Part "5 Discontinuity Edges" and "5.2 Application to Adaptive Supersampling" talks about supersampling edges only, for higher performance, isn't it what you wanted to do with your method ?
I could easily be wrong, but at SIGGRAPH last year I thought that there were limitations in what it could do.... stretching my memory I think that maybe intersections are not AA'd.
 
Simon F said:
I could easily be wrong, but at SIGGRAPH last year I thought that there were limitations in what it could do.... stretching my memory I think that maybe intersections are not AA'd.
It's been a while since I read the paper as well, but I think you're correct.
 
Back
Top