Questions tagged [zbuffer]

is an array used to store the maximum Z coordinate of any feature plotted at a given (X, Y) location on the screen.

The Z-buffer is a memory buffer (array) used in a graphics accelerator to hold the maximum z-axis value of each (X, Y) location. This allows a pixel check so that if any pixel is "below" the z-buffer value for that location, it can be ignored. This is for "hidden surface removal."

114 questions
0
votes
1 answer

Why is duplicate text being rendered onto the Z buffer of a different texture when using D3DXFont::DrawText?

I've been stumbling over this for a while and was wondering if anyone has run into this problem before. The application I'm working on is divided into multiple data plots and a single timeline at the bottom of the screen. Each plot (which is…
bsruth
  • 5,372
  • 6
  • 35
  • 44
0
votes
2 answers

What is wrong with my Z-buffer calculations?

I am implementing a Z-buffer to determine which pixels should be drawn in a simple scene filled with triangles. I have structural representations of a triangle, a vertex, a vector (the mathematical (x, y, z) kind, of course), as well as a function…
norman
  • 5,128
  • 13
  • 44
  • 75
0
votes
1 answer

Fastest way to implement z-buffering for a software renderer?

I'm implementing a javascript software renderer (for academic purposes). It handles representing a 3d object as triangles, and handles Perspective Projection from 3d space to 2d space. Until now, I used the lineTo and fillRect to represent the…
Spectraljump
  • 4,189
  • 10
  • 40
  • 55
0
votes
1 answer

Flash CS4 3D Sprite Rotation Z Order Problem

I suspect this is a maths issue rather than a flash one. In a nutshell, I have two cubes that rotate around their common center point. So far so good. Using the appendTranslation and appendRotation matrix functions, I've managed to get the two cubes…
Oni
  • 652
  • 2
  • 9
  • 22
-1
votes
1 answer

What is hidden surface problem and why does z buffer precision even matter?

As beginner to OpenGL (and computer graphics in general) I'm quite curious regarding the following questions: I know what is Z buffer, it is a depth buffer which stores value ranging from 0 to 1. But why does its precision matter? What is hidden…
Sparsh_Mishra
  • 41
  • 1
  • 10
-1
votes
1 answer

Implementation of a simple Z-Buffer in CUDA

I have a 3D point cloud and I project the pixels to an image plane. Since some 3D points get mapped to the same pixel, I only want the pixel with the lowest Z-value to my camera. I use a Z-Buffer - a float array - to keep track of my depth values.…
Close Call
  • 653
  • 1
  • 6
  • 18
-1
votes
1 answer

Is there a bug in WebGL polygonOffset or am I missing something?

I am seeing very odd behavior where polygonOffset initially works, but if I re-render it stops working. I made a simple example to illustrate it. I started with the z-fighting example from Ch7 of the WebGL Programming Guide…
DrBlack
  • 13
  • 4
-1
votes
1 answer

why the z-buffer value is always 0 when i use glReadPixels() to read the z-buffer?

Why the z-buffer value is always 0 when I use glReadPixels() to read the z-buffer? int main() { glReadPixels(0.0,0.0,width,height,GL_DEPTH_COMPONENT,GL_FLOAT,depth_data); for(int i=0;i<10;i++) for (int j=0;j<10;j++) …
-2
votes
1 answer

Opengl transparent cube faces

I am drawing transparent cubes,which share vertices, in a grid(Windows 7 VC++ VS 2012). Problem is when i rotate the picture i see strange visual effect in planes where cubes touch each other. Is this effect because of that reason only and i need to…
1 2 3 4 5 6 7
8