And what if the programmer is already using the stencil buffer for something else? Besides which, do you even know where stencil test runs in the pipeline relative to clipping and polygon division? Or that stencil test is dependent on clipping and polygon division? You really haven’t thought this through at all, have you?
You’re now moving well away from “direct support” and towards “crutched up by a load of fragile hacks that are going to break if you even look funny at them”.
GL_LINE_LOOP can be rendered very fast: http://wiki.delphigl.com/index.php/glBegin
[ATTACH=CONFIG]499[/ATTACH]
Where should be the problem, to fill the inner side of these areas with pixels also
verry fast ?
Rediculous, that it´s not able !
No, it’s actually a great idea. You see, there’s little magic elves that live inside your graphics card, and sometimes they can be a bit stubborn, but if you tell them “because it’s cool” they can get motivated and do some work for you. So, with a polygon rendering buffer they can take concave polygons and sprinkle magic elf dust all over them and thereby make those concave polygons be natively supported.
And here you can see, how it works:
left side: polygon Buffer ( help for construction to mark cross points, endpoints and the single lines ),
right side: frame buffer/color buffer with the rendered polygon
[ATTACH=CONFIG]500[/ATTACH]
The polygon buffer is cleared in the same loop as the frame buffer will be filled,
so the next polygon can be rendered
cool
here, I found an interesting discussion from Thursday, July 27, 2006
a guy suggested to use the stencil buffer for Hardware accelerated polygon rendering
“… So in the spirit of writing down about the things I’m working on on a daily basis today comes hardware accelerated rendering of complex polygons. Ignacio Castaño finally convinced me to this ingenious method so all credit for it should go to him. I’ve spent last few moments at the office today looking into this method and it’s just gorgeous so I’ll give a brief overview of it…”
here a comment from the linked page: “The method is awesome, as it (in theory) doesn’t involve any kind of client side computations (besides a trivial min/max test) and (again in theory) operates in whole on the hardware. A wonderful sideeffect of all of this is that we avoid robustness issues that tessellation introduces.”
http://www.linkedin.com/in/castano http://www.ludicon.com/castano/blog/about/resume/
actual: Senior Programmer at Thekla
former: Developer Technology Engineer at NVIDIA
3D Tools and Technology Engineer at NVIDIA
Game Programmer at Oddworld Inhabitants
Graphics Programmer at Relic Entertainment, Inc
Graphics Programmer at Nebula Technologies, SA
Lead Programmer at Crytek GmbH
its said “the method is awsome” - as I say it´s cool ----------------------------------------------------------------------------------------------------------------------
If there would be an new polygonbuffer, it could be combined with the stencil buffer, which could do it´s native job.
That would be great.
This “polygon buffer” method works great when you draw polygons sequentially, anything deserving the attribute “fast” on a GPU has to work parallelized.