Earlier quoted context omitted.
I fixed it. Thanks.
What was it originally? Hard to get more amusing than the actual article title...
Rendering my (billiard) balls in a fragment shader
11–20 of 88 posts
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
#12Came 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
#13I happened to notice that PI is #define'd to 3.1415926538, which isn't the correctly rounded off value of 3.14159265358...
Seems like they missed a '5'.
Re: Rendering my (billiard) balls in a fragment shader
#14Re: Rendering my (billiard) balls in a fragment shader
#15I happened to notice that PI is #define'd to 3.1415926538, which isn't the correctly rounded off value of 3.14159265358... Seems like they missed a '5'.
Lol, wow what a find. You notice the details. I corrected it. Thank you.
Re: Rendering my (billiard) balls in a fragment shader
#16Cool to read about C-like GLSL on a Pascal website
[deleted]
Re: Rendering my (billiard) balls in a fragment shader
#17What's the benefit of rendering using this technique over a regular sphere rendered with the usual pipeline?
Re: Rendering my (billiard) balls in a fragment shader
#18What'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
#19Re: Rendering my (billiard) balls in a fragment shader
#20What'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.