Live data from Hacker News

Rendering my (billiard) balls in a fragment shader

getlazarus.org

11–20 of 88 posts

Re: Rendering my (billiard) balls in a fragment shader

#11
post #6

Earlier quoted context omitted.

I fixed it. Thanks.

What was it originally? Hard to get more amusing than the actual article title...

The actual article was titled "Rendering Pool Balls". He fixed it by updating the article title rather than the HN submission(which I don't think you even can).

Re: Rendering my (billiard) balls in a fragment shader

#12

Came for the title, stayed for the shaders. Well written and very educational

> Came for the title

Well played

Edit: I’ll take the downvotes, the author edited the thing for silly innuendo, it’s silly, I’ll have fun too and take my lashes.

Re: Rendering my (billiard) balls in a fragment shader

#14
post #7

From the HN guidelines: please use the original title, unless it is misleading or linkbait; don't editorialize. The correct title is Rendering Pool Balls , not "Rendering my balls in a fragment shader".

Fixed.

…well played

Re: Rendering my (billiard) balls in a fragment shader

#18

What's the benefit of rendering using this technique over a regular sphere rendered with the usual pipeline?

It is faster for the case of a "top-down" 2D game. You render this and just draw a single quad per ball. You do not really have any vert shader.

Re: Rendering my (billiard) balls in a fragment shader

#19
post #7

From the HN guidelines: please use the original title, unless it is misleading or linkbait; don't editorialize. The correct title is Rendering Pool Balls , not "Rendering my balls in a fragment shader".

Fixed.

Outrageous! Well done.

Re: Rendering my (billiard) balls in a fragment shader

#20

What's the benefit of rendering using this technique over a regular sphere rendered with the usual pipeline?

Well first of you get infinite smoothness and better lighting (and reflections if you add them) because there is no underlying geometry. It's just math. It's also much faster, as you're only giving the GPU four vertices defining the square. This can even be sped up further by using point sprites which consume only one vertex.
Post reply on HN