Questions tagged [projections]
Questions about the conversions of a 3D model to a 2D model.
135
questions
0
votes
0
answers
39
views
Ocean screen grid projection and animation
I am trying to port the Bruneton Ocean demo to Vulkan and I am having a bit of trouble with the coordinate system. I am using the matrices from the original code but I am not sure what this is doing:
<...
0
votes
0
answers
31
views
Name of non-standard perspective projection where parallel lines do not meet at a single vanishing point
I have made a non-standard perspective projection for a rectangular room (see left figure), in which for stylistic reasons, I chose to make the perspective "width" of the walls equal ...
0
votes
1
answer
36
views
How are these two projection matrices related?
I have two 3D perspective projection matrices $A,B$ with standard projection parameters $k=\cot(\theta/2)$, where $\theta$ is the field of view, $n$ is the $z$-near value, $f$ is the $z$-far value, ...
1
vote
1
answer
46
views
In perspective projection matrices, why isn't $z_\text{eye}$ mapped linearly to NDC?
As far as my understanding goes, in projection matrices $x_\text{eye}$ and $y_\text{eye}$ are mapped linearly to NDC by first using proportions to find $x_n = \frac{n\cdot x_e}{-z_e}$ and $y_n = \frac{...
0
votes
0
answers
16
views
Determine horizontal FOV of a panoramic photo
Say I have a panoramic photo (less than 360) and would like to view it in a cylindrical screen in a VR headset to get an immersive experience. How to determine the optimal width and height of the ...
3
votes
1
answer
47
views
Formula for cubemap resolution for intended equirectangular resolution
Suppose I want to render out 6 cubemap cameras (90 degree FOV etc.) with the intention of combining them together in post-production into an equirectangular (latlong, 2:1) image.
Suppose I also know ...
0
votes
0
answers
19
views
How to extract points corresponding to faces from cube map projection (CMP) of panorama from point cloud data
I am working with the standford2d3d dataset http://buildingparser.stanford.edu/dataset.html which contains panoramas of various scenes and a .mat file of the point cloud information of all the scenes. ...
0
votes
1
answer
17
views
viewing direction vectors are not parallel in orthographic projection
I did some math with orthographic projection matrix to compute viewing direction vectors in screen space.
I thought all viewing direction vectors should be parallel in orthographic projection because, ...
0
votes
0
answers
31
views
Object appears in unintended parts of the screen when using manual WorldToScreenPoint
Hy guys I'm new to 3d graphics and i lack some Linear algebra knowledge. I tried to recreate Unity's worldToScreenPoint method with kotlin on android. I copied some code from their forum and wrote ...
0
votes
0
answers
37
views
3D engine projection distortions
I'm trying to write my own 3D engine using Python and Pygame.
I have successfully implemented rotation and projection matrices to display 3D models. However I am so far unable to implement translation ...
1
vote
0
answers
106
views
Is it possible to render to a octahedron texture directly?
I am considering using octahedron textures for environment mapping, opposed to sphere or cube mapping due to their low memory footprint and the quality they result in.
Is there a possibility to render ...
0
votes
1
answer
75
views
What are applications of 3D geometry to 2D geometry projection and occlusion handling?
As a layperson in the field of computer graphics, I rarely see practical applications of algorithms that take 3D geometry as the input (along with some camera and lighting parameters) and output the ...
0
votes
1
answer
69
views
My projection matrix for OpenGL fails on non-symmetric boundaries
Assuming my viewing volume has x coordinates varies from l to r, and y varies from top to bottom, and finally z-axis varies n to f, I derived the following projection matrix:
...
2
votes
2
answers
250
views
How do I evenly subdivide the projection of a circle in 3D?
I want to draw a circle in 3D from line segments. There are plenty of examples how to do this with an even number of subdivisions in 3D space, but I want the minimum number of subdivisions to produce ...
1
vote
2
answers
388
views
Clever projection of point onto triangle?
I know of at leas tone way to project a point onto a triangle.
Project onto the plane, check barycentric coordinates, if outisde triangle, project onto the 3 segments, check distance, retain closest ...
0
votes
1
answer
51
views
3D projection Axis inversion problem (Java/Processing)
Unfortunately, I always had problems with math and was never good at it. I'm currently trying to combine math with my knowledge and my passion for programming.
Brief introduction: In math, we have ...
0
votes
0
answers
76
views
Alternate projections in shader
I have a projection calculation which maps points from 3D space to pixel (image) space, and I want to use it as instead of the standard MVP projections in a vertex shader.
In the image below the lower ...
1
vote
1
answer
360
views
Why need glClipControl-like extensions when implementing ReverseZ in opgl?
I read this article (https://developer.nvidia.com/content/depth-precision-visualized) about reverseZ and I'm confused about why is glClipControl necessary.Can't we juse modify ProjectionMatrix to make ...
2
votes
0
answers
182
views
Finding Camera projection matrix from known input and output
Lets say I have a rectangle with known coordinates in 3D scene, and I'm projecting it using pin point camera to the plane (screen).
You can imagine it deforms on the screen per camera transformation ...
1
vote
3
answers
500
views
What projection matrix and world transformation do I need to have an isometric projection?
I'm doing my own engine in college to display a wireframe on screen with an isometric projection but I literally can't find any literature about maths behind doing it by hand just for game engines ...
1
vote
2
answers
467
views
mapping of a point from a sphere into UV plane
I am reading the book An introduction to raytracing by Eric Haines and it mentions an algorithm to map a point from a sphere into a UV plane, it calls it Inverse Spherical Mapping (page 49). I googled ...
0
votes
1
answer
563
views
Understanding orthographic projection matrix clip coordinates
I'm confused about what orthographic projection matrix outputs. Based on what I know so far, orthographic projection matrix converts vertexes in eye coordinates into clip coordinates. But what exactly ...
2
votes
1
answer
256
views
Is it possible to make a projection matrix to not project in the center?
I have the following projection matrix:
and I need to make a hole in the center of my matrix, something like that: (I don't want to project a custom W and H)
Is that possible ? Thanks.
1
vote
1
answer
72
views
What fields should a camera class have?
For a good and scalable project structure, what fields would you add to a camera class, apart from its position and orientation? Should I add the near and far planes? Or should that be global, what ...
0
votes
1
answer
481
views
Where exactly is the image plane / plane of projection
Perspective projection matrices we use map 3D coords onto some imaginary image plane in front of the cameras pinhole position by casting a ray directly from the eye position to that 3d coordinate and ...
4
votes
1
answer
1k
views
How to derive Field of View (FOV) angles from a 2D projection
I'm looking for some guidance.
I'm not sure if this is possible, and I'm not sure where to start.
I need to measure the FOV angles of a first-person, 3D game using only gameplay screenshots.
I'm bound ...
0
votes
1
answer
354
views
Unity - custom shadow from sun
due to some features in materials I need to create my own directional shadow map.
Everything seems to work ok, until the moment where I compare depths.
First I add camera component to directional ...
2
votes
1
answer
82
views
When fitting 3d cuboids into a box, how to find the order of drawing (in a 2D projection) so that the cuboids don't appear to overlap?
I am working on a 3D packing algorithm (MIT-licensed). The box and the cuboids it contains are displayed as a 2D projection. The order of drawing the cuboids (now represented as polygons) is important:...
-1
votes
1
answer
171
views
Why we calculate z buffer value from plane equation $AX+BY+CZ+D=0$?
Suppose in perspective projection $(x, y, z)$ coordinate projects to point $(x_p, y_p, z_{vp})$ in projection plane $AX+BY+CZ+D=0$ where projection plane kept at $z_{vp}$ position. And the plane $AX+...
0
votes
1
answer
208
views
OpenGL old-style diffuse shading producing unexpected effects
Question:
What is going wrong with the shape of the contours of constant illumination in the below picture ?
Detail:
Although Lambertian shading might be ill-regarded because it exposes the hard edges ...
2
votes
1
answer
418
views
3D homogenous coordinates versus 4D homogenous coordinates
We know that any 2D point $(x, y) $which represents as 3D homogeneous coordinates is of the form $(x, y, 1)$ which is the points of projective plane $P^2.$
If I use the same concepts for 3D points $(...
3
votes
2
answers
277
views
$(x, y, 1)$ is 2D homogenous coordinates or 3D homogenous coordinates?
We know that $(x, y, 1)$ are the homogenous coordinates of a 2D point $(x, y)$. $(x, y, 1)$ has 2 degrees of freedom. That's why we should call it 2D homogenous coordinates. But many websites say it's ...
2
votes
1
answer
109
views
Finding a texture pixel (X,Y) on a Sphere
I'm using three.js combined with face recognition, I want to rotate a sphere that displays my input video according to the detected eye location,
the face recognition gives me a X,Y on the texture ...
0
votes
1
answer
340
views
Perspective transformation is perspective projection? [duplicate]
I know that (
Reference )in transformation source and destination has same coordinates dimensions. But in projection destination coordinate system has fewer dimensions than the source coordinate ...
1
vote
5
answers
2k
views
Existence of vanishing point
Consider the following example of perspective projection: I have one railway track with two parallel lines meeting at the point $X$ at infinity which is the theoretical approach. This X is called the ...
1
vote
0
answers
68
views
3D shearing w. r. t $x$-axis [closed]
Shearing in $X$ axis is achieved by using the following shearing equations-
$X_{new} = X_{old},
Y_{new} = Y_{old} + Sh_y × X_{old},
Z_{new} = Z_{old} + Sh_z × X_{old}.$
My question is during $Y_{new}...
3
votes
1
answer
848
views
Difference between 2D and 3D pipeline
2D transformation and viewing:
The camera projects the 2D world co-ordinate $(x_w, y_w)$ on its projection plane which co-ordinates $(x_v, y_v)$.
3D transformation and viewing:
The camera projects the ...
2
votes
2
answers
323
views
Parallel projection is special case of perspective projection
I synchronized with @David k's first and second answer regarding perspective and parallel projection. From the first question I understand that the image on the screen is typically described in ...
3
votes
1
answer
955
views
Difference between transformation and projection? [closed]
We know that world coordinates $(x_w, y_w)$ transform to viewport coordinates $(x_v, y_v)$ which are the physical device coordinates. And during projection, any point $(x, y, z)$ projects to $(x, y)$ ...
1
vote
1
answer
85
views
Why shearing coefficients multiplying by y? [closed]
We know that shear is transformation that distorts the shape of the object. Shear relative to X-axis that is $y=0$ line can be written as:
$x'=x+sh_x.y, y'=y$
My question is why $sh_x$ is multiplying ...
1
vote
2
answers
306
views
Difference between perspective and parallel projection [closed]
We know that in orthographic Projection Projectors (projection vectors) are perpendicular to the projection plane.
And in Perspective Projection Object positions are transformed to the view plane ...
1
vote
1
answer
1k
views
Why are vanishing point and centre of projection the same [closed]
We know that in perspective projection object positions are transformed to the view plane along lines that converge to the projection reference (center) point like this:
But many websites say that COP(...
2
votes
1
answer
220
views
$P^2$ vs projection plane
I want to explain what I understood of definition of the two things.
Projection plane:
The general processing steps for modeling and converting a world coordinate description of a scene to
device ...
1
vote
0
answers
74
views
What should be considered the origin of a ray used for object picking with perspective projection
I need to create a ray to pick objects in 3d environment using cursor.
I'm not going to go into detailed math for this question. There's tons of information on that. In short terms, for orthogonal ...
0
votes
1
answer
338
views
How does 3D graphic software adjust for distortion inherent in perspective projection?
As this question and its answers point out, projecting a sphere on a flat picture plane, with perspective projection, may result in a ellipse, not a circle, and my understanding is that the only way a ...
1
vote
1
answer
621
views
how to change the near clipping plane of a perspective projection matrix for OpenGL
I am trying to only change the near clipping plane of a given perspective projection matrix for OpenGL.
My problem is, that the near clipping plane is way too close, and the far clipping plane is very ...
1
vote
2
answers
163
views
What is this graphical effect called?
I was watching this trailer:
https://www.youtube.com/watch?v=pWh5388AEHw
and at 1:22, the player used a magic trick that created a sphere that warped the projection of the scene.
Does anyone know ...
0
votes
0
answers
131
views
computing sheared perspective projection matrix
is it possible to calculate a "projection matrix" which is sheared as well?
the usual perspective projection matrix forms a pyramid where the near clipping plane is rectangular.
I have 4 ...
1
vote
1
answer
2k
views
is focal length equal to the distance from the optical center to the near clipping plane- openGL
The part confusing about opengl during studying the projection was that the focal length, top, left, bottom, right, wasn't declared, and it magically did it with FOV and image aspect ration. I ...
0
votes
1
answer
66
views
Moving a vertex through the cursor
There is a way to move a selected point in a mesh with a cursor(assuming a camera that doesn;t change between frames).
The way I remember the algorithm (but seems to be wrong) is:
Unproject the ...