Share Your Experience: Take the 2024 Developer Survey

# Tag Info

Accepted

### What is an index buffer and how is it related to vertex buffers?

Could someone ELI5 to me, what is an index buffer and how is it related to vertex buffers Your vertex buffer contains the X and Y coordinates of 5 vertices. They are: ...
• 443
Accepted

### Tone Mapping vs Gamma Correction

I think it would be a good idea to get back to the basics. It's a large post, so there's a recap at the end. Colour can be represented in a couple of ways. We can have Red, Green and Blue (RGB). We ...
• 1,605
Accepted

### Perspective Correct Texture Mapping

You are on the right track but what you need to do is to calculate u/w and v/w, and also 1/w for each vertex, which you interpolate linearly in screen space in your rasterizer. Then for every pixel ...
• 3,636
Accepted

• 154
Accepted

### Controlling "zoom" and "position" of a cubemap in shaders

Reflections based on a cubemap best represent a reflection at infinity. That is, since the only factor that a cubemap provides is direction, the cubemap acts as though it were at a distance from the ...
• 9,832
1 vote
Accepted

### convert image pixel dimensions to UV

UV coordinates are defined such that (0, 0) is your lower left (or upper left, depending on what you're working with) corner of the image and (1, 1) the opposite corner (technically (1, 1) is outside ...
• 1,566
1 vote

### How is this normals map supposed to work?

Yeah, that doesn’t look like any bump, height, or normal map I’ve ever seen—as you’ve identified, there’s only information about the surface contour along a single axis. If anything, it looks like it’...
• 2,222
1 vote
Accepted

### What is mipmapping?

Mipmapping is a pre-computed texture scheme that tries to solve the problem of texturemap aliasing. When a screen pixel from a textured polygon covers many texture pixels, the pixel should be sampled ...
• 315
1 vote

### I need to build my own map renderer

If you have the prerendered images, you can "simply" render them onto a grid of quads. This is done with texturing, i.e. you upload the image to your GPU as a texture and apply texturecoordinates to ...
• 1,566
1 vote

### Getting texture value of cartesian coordinate from a Obj file

Your question is very broad because it is close again to "how to I render 3D objects". So some people might give you a more precise answer than mine but at least I will try to give you some pointers. ...
• 656
1 vote

### Texture Mapping jagged pixel edges

In my case, i fixed the problem adding Dx' for interpolation of x-direction. In edge scan line of x-direction, I use integer-type for speed-up but ingnored dx' as below. I changed variable type from ...
• 11
1 vote

### Why map Hammersley 2D set's (u,v) to sphere's (θ, φ) coordinates (and not to (φ, θ) )?

The "Uniform Mapping" here is incorrect. It does not transform to a uniform distribution on the sphere. Very very bad me. I misread the equation AND I didn't even consult my own reference [...
• 154

Only top scored, non community-wiki answers of a minimum length are eligible