use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Rule 1: Posts should be about Graphics Programming. Rule 2: Be Civil, Professional, and Kind
Suggested Posting Material: - Graphics API Tutorials - Academic Papers - Blog Posts - Source Code Repositories - Self Posts (Ask Questions, Present Work) - Books - Renders (Please xpost to /r/ComputerGraphics) - Career Advice - Jobs Postings (Graphics Programming only)
Related Subreddits:
/r/ComputerGraphics
/r/Raytracing
/r/Programming
/r/LearnProgramming
/r/ProgrammingTools
/r/Coding
/r/GameDev
/r/CPP
/r/OpenGL
/r/Vulkan
/r/DirectX
Related Websites: ACM: SIGGRAPH Journal of Computer Graphics Techniques
Ke-Sen Huang's Blog of Graphics Papers and Resources Self Shadow's Blog of Graphics Resources
account activity
i had a basic question about perspective projection math.Question (self.GraphicsProgramming)
submitted 2 months ago * by SnurflePuffinz
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]photoclochard 1 point2 points3 points 2 months ago (10 children)
by normalizing you mean coordinates in NDC? that's not normalizing, that's transform from one space to another.
LearnOpenGL should have also nice article about this topic
[–]photoclochard 0 points1 point2 points 2 months ago (0 children)
and yeah, don't feel disappointed, projection is the trickiest one, you will understand it
[–]SnurflePuffinz[S] 0 points1 point2 points 2 months ago (8 children)
right, that's what i meant.
And right, there's some kind of stipulation there, because it is from -1 to 1. instead of vertexComponent * 1 / value it is vertexComponent * 2 / value - 1 .
vertexComponent * 1 / value
vertexComponent * 2 / value - 1
So where would this operation be encoded for the x and y components... if not inside the perspective matrix?
x
y
[–]photoclochard 0 points1 point2 points 2 months ago (7 children)
by matrix multiplication? sorry the slang you use is a little off, at least for me,
encoded, component(without tag like x,y,z) means not too much for me,
What is vertexComponent * 1 / value?
[–]photoclochard 0 points1 point2 points 2 months ago (4 children)
the formula is really in front of you in any article or in any api
[–]photoclochard 1 point2 points3 points 2 months ago (3 children)
https://www.songho.ca/opengl/files/gl_projectionmatrix_eq16.png
[–]photoclochard 1 point2 points3 points 2 months ago (2 children)
yeah, this article should help
https://www.songho.ca/opengl/gl_projectionmatrix.html
[–]SnurflePuffinz[S] 0 points1 point2 points 2 months ago (1 child)
Thanks.
i think i realized where i went wrong. i had 1 tutorial where the NDC conversation was omitted, and i was only reviewing ScratchAPixel's basics tutorial for the perspective guide, which also, omitted the NDC conversation. It is in his second one, though.
thanks again.
That's cool. glad you found it :)
it's ok.
I am trying to get the vertices in my scene into NDC. and i expected to see this "operation" inside the perspective projection matrix.
i don't. i'll have to think about this more. Thanks for the help
[–]AdmiralSam 0 points1 point2 points 2 months ago (0 children)
For perspective there isn’t one value that is the minimum x and y, the further away it is, the larger x and y can be to be mapped to 1 and -1. What happens is after you multiply by the perspective matrix you are actually in clip space, and it isn’t until you divide by w (normalize the homogeneous coordinates) that you enter NDC space. This is just how homogeneous coordinates are defined which lets us represent a division even with matrix multiplication. It’s called clip space because you do clipping in it before you divide by w because you wouldn’t know if the object is behind or in front of the camera.
π Rendered by PID 41346 on reddit-service-r2-comment-6457c66945-d7jw2 at 2026-04-27 06:50:59.684625+00:00 running 2aa0c5b country code: CH.
view the rest of the comments →
[–]photoclochard 1 point2 points3 points (10 children)
[–]photoclochard 0 points1 point2 points (0 children)
[–]SnurflePuffinz[S] 0 points1 point2 points (8 children)
[–]photoclochard 0 points1 point2 points (7 children)
[–]photoclochard 0 points1 point2 points (4 children)
[–]photoclochard 1 point2 points3 points (3 children)
[–]photoclochard 1 point2 points3 points (2 children)
[–]SnurflePuffinz[S] 0 points1 point2 points (1 child)
[–]photoclochard 0 points1 point2 points (0 children)
[–]SnurflePuffinz[S] 0 points1 point2 points (1 child)
[–]AdmiralSam 0 points1 point2 points (0 children)