Questions tagged [projection-matrix]

234 questions
3
votes
1 answer

How to draw an object and rotate it in oblique frontal projection

How to draw an object and rotate it in oblique frontal (dimetric) projection properly? An illustration of projection: I've already made a program (Pascal with Graph unit) which does it, but I think that it draws object incorrectly. program…
Artfaith
  • 1,183
  • 4
  • 19
  • 29
3
votes
1 answer

How to rotate a cube by its center

I am trying to rotate a "cube" full of little cubes using keyboard which works but not so great. I am struggling with setting the pivot point of rotation to the very center of the big "cube" / world. As you can see on this video, center of front…
Ady96
  • 686
  • 4
  • 12
  • 35
3
votes
1 answer

OpenGL 2D projection matrix not drawing anything

I am using OpenGL for 2D rendering and would like to use actual pixel coordinates. By this, I mean that I would like (0,0) to be in the top left of the window, and (width,height) to be in the bottom right of the window (where width and height are…
rodit
  • 1,746
  • 2
  • 19
  • 33
3
votes
1 answer

How to calculate OpenCV camera projectionMatrix in python

I am trying to calculate projection_matrix using OpenCV 2.4 in Python 2.7 for my camera (I am using ps eye). I need it for cv2.triangulatePoints(). I already did the calibration using cv2.calibrateCamera() (using calibrate.py from OpenCV examples)…
Repminister
  • 156
  • 1
  • 3
  • 6
3
votes
0 answers

Keystoning with JOGL

I am struggling to apply a projective transformation based on the 4 corners of my display, as followed : My insight is to tune up a bit the projection matrix, by first computing the perspective transformation, and multiplying the matrix by the…
Julien Mazars
  • 1,032
  • 11
  • 24
3
votes
2 answers

Why does graphics pipeline need mapping to clip coordinates and normalized device coordinates?

On perspective projection, if I use simple projection matrix like: 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1/near 0 , which is just projecting onto the image plane. It can be easily get view space coordinates by discarding and normalizing, I think. If on…
Hyunan Kwon
  • 545
  • 1
  • 4
  • 14
3
votes
1 answer

3D reconstruction using the projection matrices from the trifocal tensor

I have computed the trifocal tensor and corresponding projection matrices P_0, P_1 and P_2 from line correspondences over 3 views, according to 'Multiple View Geometry by Hartley & Zisserman, 2nd edition', Chapter 16. The computed matrices are: P_0…
3
votes
1 answer

Moving the Projection Matrix to a Specific X,Y,Z Point ? OpenGLES 2.0 - iOS

Say I am using the below code to setup a projection view : float aspect = fabsf(self.view.bounds.size.width / self.view.bounds.size.height); GLKMatrix4 projectionMatrix = GLKMatrix4MakePerspective(GLKMathDegreesToRadians(65.0f), aspect, 4.0f,…
3
votes
1 answer

Projection matrix from Unity3D to DirectX

I found this question to perform a transformation between OpenGL and DirectX, but it doesn't seem to be working when performing the same things from Unity3D. I was hoping that there is someone here who knows anything about the differences between an…
Marnix
  • 6,384
  • 4
  • 43
  • 78
3
votes
1 answer

Pixel-perfect projection matrix in OpenGL?

I'm using OpenTK and I would like to be able to render polygons and textures pixel perfect when their Z is a certain number, anywhere else in the projection doesn't matter (this is for a UI). Is there a way to set up a projection matrix that does…
3
votes
0 answers

OpenGLES adding a projection

I'm started to learn a OpenGLES and currently I'm reading this TUTORIAL I have reached paragraph Adding a Projection and I'm stuck there: // Add to render, right before the call to glViewport CC3GLMatrix *projection = [CC3GLMatrix matrix]; float h =…
iWheelBuy
  • 5,470
  • 2
  • 37
  • 71
3
votes
1 answer

How to build the correct projection matrices?

Can someone please tell me how the projection Matrices look like for triangulatePoints? Its not that easy, I found several possible projection Matrices but couldn't figure out by now which one is the right one. If I have KeyPoints from Robust…
user1651460
  • 450
  • 1
  • 5
  • 16
3
votes
0 answers

Triangulation, from calibrateCameras()s' tvec and rvec

its hard too find exactly the answer to my question, that's why I want to ask it here, even it is poorly explained somewhere else. I try to add the solution in code so that everyone can get back to my results. But first it has to be solved. Its…
3
votes
1 answer

Align a camera to a rectangle

We are trying to align our camera in order to see as closest as possible a rectangle(a face of a parallelepiped since we are in 3D). The aspect ratio of the viewport considered here and the rectangle to align do not match. What we do: In our scene…
Mr.Pe
  • 719
  • 1
  • 7
  • 19
2
votes
1 answer

Homogeneous matrix has eight independent ratios of matrix elements?

I'm reading some paper about computer vision. It looks like a simple fact but I can't understand. It is about homogenous [3x3] matrix that is used for planar projective transformation. And it is said to have eight independent ratios of matrix…
1 2
3
15 16