Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [transformations]

Transformations are mathematical operations that can be applied to an object to change its scale, position and orientation.

5
votes
1answer
301 views

Understanding view matrix

I've been reading several sources in the web about transforming world-space points into camera-space ones. I am building my view-matrix from the following parameters ...
5
votes
1answer
981 views

Image rotation algorithm

I would like to rotate a raster image by an arbitrary angle. I don't really care for speed: the rotation should be of highest quality possible. Could someone please suggest a suitable algorithm? I'm ...
2
votes
1answer
197 views

Unwinding an image on a spiral to make it long and flat

Here's an odd intellectual puzzle. Something I was daydreaming about on a train - but the maths are somewhat beyond me. How would someone go about un-winding a spiral to produce a long flat image? ...
3
votes
2answers
515 views

3D rotation matrix around vector

I am using matrix for performing 3D rotations. I know that in 3D space the matrix product order is important - changing the order of the matrices can effect the rotate result. So I am interesting ...
4
votes
1answer
172 views

Affine Transformation

We have a matrix $$\begin{bmatrix} a_{11} & a_{12} & a_{13} \\ a_{21} & a_{22} & a_{23} \\ a_{31} & a_{32} & a_{33} \end{bmatrix}$$ This matrix represents a ...
3
votes
0answers
148 views

Creating an Object Orientated Bounding Volume

I'm attempting to test out the maths behind bounding volume algorithms (prior to ray tracing) using MATLAB. So far, I have successfully created the relatively trivial axis aligned bounding volume, ...
4
votes
1answer
927 views

Computing camera front direction from Euler angles

I am new to OpenGL and Computer Graphics in general. Lately I was learning how to model a camera, specifically how to model the rotation of camera. I was introduced to Euler angles for this purpose. ...
10
votes
2answers
3k views

Cause of shadow acne

I know how shadow mapping works but I am not getting the cause of shadow acne! Can anyone tell me cause of shadow acne in a simple way and how is it related to depth map resolution?
4
votes
0answers
145 views

OpenSCAD Hull/Minkowski function by hand?

I am trying to model an organic object using OpenSCAD. However this will need to be ported over to older software. This restricts the primitives I can use (only cone, cylinder, torus, sphere and cubes)...
9
votes
1answer
262 views

Moving each point of a surface in direction of corresponding normal

So let assume that I have some convex smooth and unclosed surface. I'm moving each point of it in a normal direction by some constant factor (This factor is same for all points on surface). Can I ...
1
vote
0answers
335 views

A question about derivation in oblique view frustum

Problem Description: Reference: Oblique View Frustum Depth Projection and Clipping "Mathematics for 3D Game Programming and Computer Graphics" 3rd edition, chapter 5.6. M is the original projection ...
7
votes
1answer
229 views

How to invert an affine matrix with small values?

I'm using an affine transformation matrix to transform 2D coordinates from screen (magnitude 10e3) to small parts of fractal sets (magnitude as little as 10e-15). I also need to map the other way ...
7
votes
2answers
503 views

Rotate line around center

I have to use a propriertary graphics-engine for drawing a line. I can rotate the whole drawing by its origin point (P1). What I want, is to rotate it around its center point(M). So basically that it ...
4
votes
1answer
477 views

Choosing & Using a Projection Matrix

I'm looking into the graphics pipeline processes and at the moment in particular, perspective projection matrices. After looking in several different sources, and across the breadth of previous ...
3
votes
2answers
566 views

Correct view-space transform

I am attempting to model a simple graphics pipeline (i.e. Local->Word->View->Screen->2D spaces). I've been looking at the algorithm required to transform from world to view-space and using the ...
6
votes
1answer
189 views

Graphics Pipeline: Viewspace & Back face culling incorrectly

I'm attempting to model a simple graphics pipeline - using Matlab at the moment as a modelling tool to get the transformations correct. I appreciate there are software tools that would make this ...
7
votes
1answer
97 views

implementing right handed coord system APIs on top of a left-handed rendering engine

I am trying to plug in a 3D game engine as the rendering engine for an existing graphic API system that uses a right-handed coordinate system. Game engines often uses a left handed coordinate system ...
3
votes
1answer
104 views

culling meshes across mulitple layers

I am implementing foveated rendering. My FBO is divided into 2 layers which are concentric. The first layer covers 1/3 of the Framebuffer whereas the second one covers the rest of the screen. Now I ...
4
votes
2answers
781 views

How to determine the object-to-world matrix

I want to ray trace a triangular mesh that I load from a file. The vertices' coordinates are expressed in the reference frame associated with the object (i.e the mesh) and I don't know the object-to-...
4
votes
1answer
81 views

Is there a way to script image creation?

I am facing a though challange - I need to perform repetitive Image formating. Firstly, I need resize picture A so that it has some fixed width in pixels. Then, I need to place picture A in the middle ...
6
votes
2answers
158 views

Finding the angle of any side of a polygon

I'm trying to find the angle it would take for me to rotate a polygon so that a specific side is completely horizontal and on the bottom. For example, a shape like this: Needs to be rotated so the ...
4
votes
1answer
485 views

Angle between two points in Cartesian coordinate system C++

I'm trying to rotate a rectangle so that it faces another rectangle in a spiral. Im using the Bullet pyhics library and freeglut for the 3d application, for anyone interested https://github.com/...
5
votes
1answer
136 views

How to get polygon coordinates in screen space

I need to be able to click on this polygon in 2d. This polygons set of vertices aren't in the same space as the screen. (Ie: the edge of the screen may be a value of 20 in one space but 1920 in the ...
4
votes
2answers
178 views

How to get the transform amount from a screen vector and a direction vector?

I am working on the move tool in a 3D modeling software. I need to know how much to move when the user drags an axis of the gizmo (for example along the x axis). I have the 2D vector describing how ...
8
votes
1answer
372 views

Calculate aspect ratio from 2D shape in 3D space

Given the 4 coordinates of a 2D shape in a 3D space I want to calculate its aspect ratio. The 3D space is created with 2 vanishing points. The 4 coordinates - marked blue - are the 2D coordinates on ...
7
votes
1answer
163 views

After a deformation operation on polygons, how can I check for and fix inverted polys?

I'm doing a quick and dirty automated deformation routine on a polygon body. If it was a tree, and my axis was in the center of the tree, I would like to bend the body by bending the axis. I would ...
1
vote
0answers
61 views

How is smooth animation accomplished? [closed]

How are objects moved smoothly from point A to point B given matrix transformations that describe next position?
12
votes
2answers
286 views

Ray Transformation to Object Space for Motion Blur

My raytracer supports a wide variety of objects. To intersect them, I use the standard technique of transforming rays into object-space. This works fantastically until I add motion blur. I model ...
7
votes
3answers
8k views

How to combine rotation in 2 axis into one matrix

I already know about the matrices I have to use in order to perform rotations. If I have to rotate in z-axis and then in x-axis, I would do it in 2 steps. My question is, is it possible to combine ...
3
votes
3answers
236 views

Transform a point into another point

I have the following problem: Give a matrix that will transform the point $(x,y,z)$ into the point $(\frac{2}{x+y}, \frac{5y + z}{2x + 2y}, 3)$. I have been reading my book to find a way to solve it ...
12
votes
7answers
20k views

Why are Homogeneous Coordinates used in Computer Graphics?

Why are Homogeneous Coordinates used in Computer Graphics? What would be the problem if Homogeneous Coordinates were not used in matrix transformations?
21
votes
2answers
5k views

Why is the transposed inverse of the model view matrix used to transform the normal vectors?

When rendering 3D scenes with transformations applied to the objects, normals have to be transformed with the transposed inverse of the model view matrix. So, with a normal $n$, modelViewMatrix $M$, ...
4
votes
2answers
150 views

Software to compose separate models into an articulated model?

I've inherited a system which animates a humanoid avatar by loading various models and manually calculating transformations for each one. I'm in the process of porting part of this system to Three.js, ...
21
votes
1answer
5k views

What are Affine Transformations?

What are Affine Tranformations? Do they apply just to points or to other shapes as well? What does it mean that they can be "composed"?
8
votes
2answers
132 views

When is it better to upload partial model matrices to the vertex shader?

As of now, when rendering my scene and while iterating through the scene graph, for each node its model matrix is calculated from the parent's model matrix and the scene node's pose. This is quite ...
5
votes
2answers
1k views

Image rotation using FFT

I'm not sure how practical this might be but is it possible to use Fast Fourier Transform to rotate a raster image? To be honest, I never really understood FFT, but I saw it being used for JPEG, for ...
4
votes
1answer
66 views

Why is the color in the cube being weirdly swapped?

I am implementing a trackball, i.e. a camera orbiting about a fixed point, in my case the origin. When I do left click with the mouse and start moving it, I compute delta values for the angles of a ...
12
votes
4answers
2k views

When should quaternions be used to represent rotation and scaling in 3D?

Quaternions (a four-dimensional extension of complex numbers) can used to represent rotation and scaling of a 3D vector, and the application of a quaternion onto a 3D vector involves two quaternion ...
8
votes
2answers
213 views

What transformations should I apply to a model to produce this 3D effect?

I saw a video on YouTube where a person uses a transparant, knotted pyramid to display "holograms" using their smartphone. (I have not been able to reproduce this yet, so I can't tell for sure if it ...