Questions tagged [projection]

The tag has no usage guidance.

40 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
6
votes
0answers
223 views

How to set the camera projectionmatrix so that it's 4 rays always exactly hit the corners of a defined plane?

I have a camera, and I have a plane. The plane has 4 corner points. I need to find out how to change the projection-matrix of the camera so that the projection-rays of the camera always hit the ...
5
votes
0answers
98 views

How do I align the cube in which shadows are computed with the view frustrum? (“View Space aligned frustum”)

Short and concise: Given 8 world space positions that form a cube of arbitrary size, position and orientation and given an arbitrary light direction. How do I compute the View and Projection matrix ...
4
votes
0answers
162 views

How to implement a pannini projection in opengl?

I have read about the pannini projection, which involves (I think) projecting a scene onto a cyclinder instead of a rectangle. How can I implement this projection in a vertex shader? Blinky is using ...
4
votes
0answers
228 views

Filling Closed Shapes

Game Engine : Unity 5.1 Developing on Windows 7 Hello, I am using Vectrosity to draw some some shapes on screen run time. I also need to fill these shapes and none of them are really trivial shapes. ...
3
votes
3answers
1k views

How to render top-down perspective in a tile-based RPG?

My question is specifically about the type of perspective that GBA Pokemon games like Fire Red/Leaf Green have: I'm not sure of the correct terms for what I'm trying to achieve. I am using SDL2 and ...
3
votes
1answer
2k views

Deproject Screen To World Coordinates (Unreal Engine 4.15)

I am working on a small game in Unreal Engine 4.15 using blueprints only and encountered a behaviour I don't understand. The game is based on the Top Down Example. As I'd like to teleport an actor ...
3
votes
0answers
82 views

Projector does only affect model

I'm working on a simple selection of a RTS unit. Therefore I used a projector to display a circle on the ground around the unit. But it happened, that the circle is only displayed on the head of the ...
3
votes
0answers
483 views

Control frustum near and far clip plane sizes in a Projection Matrix

I'm trying to achieve a dolly zoom effect. My first try was the obvious one, the original "zoom in & dolly out" technique, which works nicely. Except that there are cases which this is not ...
2
votes
0answers
104 views

How to convert screen to world coordinates while using gluLookAt / gluPerspective or similar matrix transforms?

I am just starting an adventure in looking under the hood of graphics for a game project I've been working on for a while, and I could use some guidance. I am using Python/Kivy (though that is not ...
2
votes
0answers
32 views

How to change a shape project when obstructed by object

I have a customized shape (mesh) in 3D as shown below: Now that customized shape projection will change when there are several obstacles located in front of the customized shape. I expect the result ...
2
votes
0answers
116 views

DirectX 11 - Problem with low resolution decals

I'm trying to add a decal system in my DirectX engine but i'm facing some problems with the quality of the textures projected. Every other no decal texture look fine, but these ones look really bad. ...
2
votes
0answers
457 views

glOrtho and VBO

I'm trying to send triangles to OpenGL using screen coordinates. Using the deprecated glBegin and glEnd I could just set up an orthographic projection and use screen-space coordinates as the triangles/...
2
votes
0answers
183 views

Unproject considering parallax depth

How can I take screen coordinates (or alternatively world coordinates on the 'primary' parallax plane) and find out what world coordinates they translate into when taking parallax depth into account? ...
2
votes
0answers
181 views

Stereo 3D: drawing 2D elements at apparent screen depth

I'm developing an application making use of DirectX11's stereoscopic features. At such I am not relying on nVidia's automatic implementation. That means I have to replicate a way to render 2d elements ...
1
vote
0answers
11 views

How to add a falloff (transparency) to projector shader in Unity?

I am new to Unity shaders and I was wondering if it was possible to add a falloff variable to control the transparency of the projected color. Here is the shader code : ...
1
vote
0answers
14 views

Projector making the scene objects grey in Unity

Everytime I enable my projector, it makes all the overlapping elements look entirely grey. The shadows also disapear. I tryed a couple of other shaders found on the internet but the issue still ...
1
vote
1answer
111 views

Tiles on sphere - check visibility

I have a sphere with tiles. I need to heck if tile is visible or not. See the image. Tiles are red squares, "screen" is represented by yellow quad. Currently, I calculate coordinates of tile in ...
1
vote
0answers
63 views

Why projection window is between -1 and 1

Is it a convetion ? What we achieve with this ? I am reading about how the perspective and orthographic matrix is getting calculated and everyone is trying to normalize the homogenous coordinates to [...
1
vote
0answers
747 views

Screen-space shadows?

Is there such a thing as screen-space shadows? I know that most shadow projection comes from rendering the world from the viewpoint of the light source, projecting the shadows onto a large square ...
1
vote
0answers
20 views

How do I change x,y,z coordinates if I want to make a perspective projection?

How do I supposed to modify x,y,z coordinates to make the perspective projection? I'm talking not about matrix, could you explain me each coodinate specifically? Like, x =... y=... z=... I'm asking ...
1
vote
0answers
66 views

How to use GetViewProjMatrix().TransformVector(LineDirection) in UE4?

I try to project a 3D vector (a direction, not a position) in screen space, but it does not return satisfying results: ...
1
vote
0answers
133 views

Construction of perspective matrix

Is it possible to Construct a perspective matrix by multiplying a perspective transformation with a parallel projection ? I want a perspective projection in 2D space which is calculated by ...
1
vote
0answers
365 views

What is the connection between an isometric angle and scale

I am trying to work out an isometric projection matrix for a custom angle. In the engine I'm using there's a projection matrix defined like so: ...
0
votes
1answer
37 views

How to project a 3D circle/ellipse to 2D?

The 3D ellipse is represented by its center and the vectors for its major and minor axes and the 2D ellipse by its center, the length of the major and minor axes and the angle between the major axis ...
0
votes
0answers
35 views

Deferred shading - g-buffer positions, world or view space?

So, i am doing this for the first time. I have a lodded terrain that i would like shade deferred. I have built the g-buffer with positions/normals/albedo/depth and render vertices like I did before ...
0
votes
0answers
129 views

Unity custom camera projection only working in scene editor

I've found this article on Gamasutra on a custom camera projection to make 3D look more 2D and decided to implement it to make some gameplay tests. I had to make some changes to make it work on URP(on ...
0
votes
0answers
44 views

Game Maker - Raycasting from camera in orthographic projection

I have been trying to figure out how to click on 3D objects in Game Maker Studio 2. I am using an orthographic projection. I know the basic idea is to calculate a ray that comes from the camera ...
0
votes
0answers
45 views

Does Unity provide access to a camera's Viewport Rect in a shader?

If I, for example, set a camera's Viewport Rect to W:0.5 H:0.5, is there some way to access that in a shader? Is there some way to extract it from unity_CameraProjection? I thought about comparing ...
0
votes
0answers
25 views

Projecting Coordinates from one Space into another, but with “twisting”

i'm trying to generate a decal mesh kinda like this: http://blog.wolfire.com/2009/06/how-to-project-decals/ but instead of projecting the decal with a box, i need to project it with a sort of ...
0
votes
0answers
30 views

Libnoise bounding box - from spherical to planar

I'm trying to convert a bounding box inside a spherical map (equirectangular image as a result of Libnoise/c++) into a planar projection, but I can't find the correct algorithm for it and I'm not good ...
0
votes
0answers
39 views

Confused on graphics rendering

Implementing a viewport is just a rectangular space on the back buffer usually a 2d texture set to the size of the client window that we render to. However in direct3d when we describe the viewport ...
0
votes
1answer
107 views

Can we flip znear and zfar so that positive z values increase away from the viewer?

I am confused about the projection matrix in OpenGL. i have a habit of writing the code as follows. ...
0
votes
0answers
78 views

Perspective projection matrix with a non-orthogonal near plane

I'm trying to figure out a way to provide such a perspective projection matrix to a shader that the "near" plane wouldn't necessarily be orthogonal to the camera vector. More specifically, I'm ...
0
votes
0answers
34 views

Camera LookAt position with fixed screen position

I have a perspective "lookAt-type" camera. I'm trying to compute specific focus point of the camera, which should be placed in the middle of the screen: I also have a custom 3d point in world space, ...
0
votes
0answers
53 views

Why does this work in the fragment shader but not in the vertex shader?

I'm doing some model view and projection transforms in the vertex shader and I want to determine whether the current vertex will end up on the viewport or not. After searching a bit I found that ...
0
votes
0answers
530 views

2.5D UI, perspecitve view, distort objects by angle but not position

Instead of thousand words, a few pictures to explain what I want to achieve How do I get the merit of UI objects rotation in perspective projection, but ignore the position of an object(as in Overlay ...
0
votes
0answers
147 views

Perspective projection

I'm studying Perspective projection in a computer graphics course and i'm really confused about a detail. The study material says there are 3 cases: Case 1: View plane parallel to the xy plane and ...
0
votes
0answers
424 views

Perspective Projection Far Plane Not Clipping?

I've just discovered that far away objects in my world don't seem to clip like they should with a perspective projection matrix. When I fly far away from my main landscape, so that I am much more ...
0
votes
0answers
71 views

Rasterizing euclidean planes

I'd like to visualize a BSP tree. To do this, I need to project an arbitrary euclidean plane onto a projection plane. I was thinking about calculating the intersections of the plane with the viewing ...
-1
votes
1answer
97 views

What is the alternative (new) 3d projection called that solves the stretching / zooming at sides of monitor?

I understand about camera's and projections etc, such that we have distortion and zooming when at the sides of the screen (exacerbated on 21:9 monitors), however a few years ago, in a Unity forum ...