Questions tagged [frustum]

A frustum is a region of space delimited by a solid geometrical shape and two parallel planes cutting it, in particular the region of (virtual) space that is rendered on screen in computer graphics applications.

A frustum is a region of space delimited by a solid geometrical shape and two parallel planes cutting it. It may also refer to the region of (virtual) space that is rendered on screen in computer graphics applications (e.g. the visible area of a first-person shooter computer game or of a virtual reality application, like a virtual planetarium - Viewing frustum).

159 questions
3
votes
1 answer

width of a frustum at a given distance from the near plane

I'm using CML to manage the 3D math in an OpenGL-based interface project I'm making for work. I need to know the width of the viewing frustum at a given distance from the eye point, which is kept as a part of a 4x4 matrix that represents the camera.…
joshfisher
  • 227
  • 1
  • 3
  • 8
3
votes
1 answer

Frustum and sphere intersection

I'm reading along this neat article here: Frustum Culling and it reads that to find the distance between a sphere and a frustum side (a plane) is: C = center of sphere N = normal of plane D = distance of plane along normal from origin Distance =…
sgtHale
  • 1,507
  • 1
  • 16
  • 28
3
votes
1 answer

Processing camera frustum() and perspective() rotations

How can I make a camera that I can move around and rotate around its own axis in processing 2+? I have a camera that I can move around in the world space and have some kind of rotation: frustum(-10,10,-10,10,10,2000); translate(camX,camY,camZ);//I…
Patrick Dahlin
  • 286
  • 2
  • 5
  • 19
3
votes
0 answers

OpenGL Frustum visibility test with sphere : Far plane not working

I am doing a program to test sphere-frustum intersection and being able to determine the sphere's visibility. I am extracting the frustum's clipping planes into camera space and checking for intersection. It works perfectly for all planes except the…
StackAttack
  • 57
  • 1
  • 6
2
votes
1 answer

How know which particles of a particlesystem are in the frustum

I'm using Three.js and webGLrender to display a hockey stadium with its seats (80k particles) and i want to be able to do picking on each seat. I've tried to create a hidden object to use ray interception but with 80k objects all becomes too slow.…
2
votes
1 answer

OpenGL : Line jittering with large scene and small values

I'm currently drawing a 3D solar system and I'm trying to draw the path of the orbits of the planets. The calculated data is correct in 3D space but when I go towards Pluto, the orbit line shakes all over the place until the camera has come to a…
batterj2
  • 130
  • 1
  • 10
2
votes
0 answers

GPU frustum culling : why using scan?

I'm trying to implement frustum culling in the gpu. After reading a bit and also stumbling on this very helpfull repo : https://github.com/ellioman/Indirect-Rendering-With-Compute-Shaders , I've noticed that the goto implementation seems to be Test…
Ragekit
  • 41
  • 2
2
votes
1 answer

How to retrieve the camera origin/position from the view projection matrix? (OpenGL)

Is there any way to retrieve the camera origin/position from the view projection matrix? (OpenGL) I'm trying to draw the camera's frustum and I have no problems calculating corners for the Far and the Near planes. But I can't figure out how to…
Gediminas
  • 1,830
  • 3
  • 27
  • 47
2
votes
1 answer

About view matrix and frustum culling

I was trying to determine if an object (sphere) is inside a view frustum. My strategy was first to get the view matrix: glm::lookAt(cameraPosition, lookAtPosition, cameraUp); Where cameraPosition is the position of the camera, lookAtPosition is…
Tien Dinh
  • 351
  • 1
  • 12
2
votes
1 answer

How to return the frustum of the THREE.Perspective camera and store it as a variable?

I was looking on Three.js API and I found that the Frustum is used for the camera visible area. I was wondering if I can access the view frustum of my PerspectiveCamera and declare the frustum as an object. Basically, my goal is to color the frustum…
Loizos Vasileiou
  • 674
  • 10
  • 37
2
votes
0 answers

Implement camera with off-axis projection

I'm trying to create a 3D viewer for a parallax barrier display, but I'm stuck with camera movements. You can see a parallax barrier display at: displayblocks.org Multiple views are needed for this effect, this tutorial provide code for calculating…
Leon
  • 554
  • 4
  • 18
2
votes
1 answer

View frustum visualization

Given a 3D position of a camera, 3D target position of the camera (the point the camera points to), far plane distance from the camera, field of view and aspect ratio, how can I calculate the four 3D points in the far plane? This should be possible…
bittersoon
  • 393
  • 4
  • 14
2
votes
1 answer

OpenGL How to calculate worldspace coordinates from frustum aligned vectors?

I am a graphics programming beginner working on my own engine and tried to implement frustum-aligned volume rendering. The idea was to render multiple planes as vertical slices across the view frustum and then use the world coordinates of those…
2
votes
1 answer

How to draw camera frustum using inverse view matrix in openGL

I try to draw the camera frustum for debugging purpose. I can draw it using the NDC space with the following code Matrix inv = (camera.getViewMatrix() * camera.getProjectionMatrix()).inverse(); Vector4 f[8u] = { // near face {1, 1, -1,…
jbalestr42
  • 74
  • 1
  • 6
2
votes
0 answers

Distance from center to out of ortographic camera view in three.js

I have a scene with an ortographic camera and I need to find the distance from the center of my world axis to the external in way to move an object outside the camera view. I know how to calculate the frustum of the camera but I'm not able to…
1 2
3
10 11