Most Popular
1500 questions
7
votes
2 answers
Why replicating the higher bits of RGB565 when converting to RGBA8888?
I have seen in some computer graphics software's code bases that sometimes the higher bits of RGB565-format image data are replicated into the lower bits when converting to higher-bit-depth format RGBA8888.
I have found for example the comment by…
wip
- 1,851
- 1
- 13
- 26
7
votes
1 answer
How does this small fractal shader work?
I would like to know the magic behind this tiny fractal shader; I didn't really understand the code and the mentioned thread...
Is there an accessible explaination?
https://www.shadertoy.com/view/4ttBWM
arthur.sw
- 377
- 2
- 14
7
votes
1 answer
Hodge Decomposition in fluid simulations
I have just started implementing a fluid simulator based on the navier stokes equation.
I am following Jos Stam's paper to do so.
In this paper, it says that the velocity field must be mass conserving. Which I understand as, the velocity that flows…
Mn9
- 83
- 3
7
votes
1 answer
How to decompose a complex mesh to simple geometry shape programmatically?
I have a complex geometry mesh object, which is an irregular shape.
I want to redraw that complex geometry mesh object using multiple simple primitive shapes.
For example, I want to use cuboid, sphere and cylinder to represent a complex geometry…
user2150279
- 191
- 1
7
votes
0 answers
Supersampling HDR
I'm encountering some issues supersampling in HDR for an SDR result and was curious what the usual method for doing this is. Notice how pixelated the edge of the white sphere is.
Here's how I render the image:
Get the (linear HDR) shaded color…
Alan Wolfe
- 7,801
- 3
- 30
- 76
7
votes
1 answer
Intuitively understanding conservation of energy for the Lambertian BRDF
The Lambertian BRDF is defined as $R / \pi$, where the division by $\pi$ is there to maintain conservation of energy. The derivation is provided here.
The maths makes sense, and I can understand where the BRDF comes from in a mechanical sense. But…
Paul Ferris
- 447
- 2
- 11
7
votes
1 answer
Ray tracing - partial derivatives for texture lookup
I'm doing some ray tracing on GPU using a fragment shader...
How can I calculate texture coordinates partial derivatives with respect to screen coordinates so I could perform filtered texture lookup with textureGrad GLSL function?
Do I need to use…
zduny
- 377
- 2
- 6
7
votes
1 answer
How does voxel cone tracing work?
Assume that we have voxelized a 3D scene into a regular 3D grid of cubes, storing the average (diffuse) radiance and some flag indicating whether or not a voxel is empty. Next, the finer levels of the 3D texture (voxels) are downsampled to get…
Matthias
- 1,074
- 9
- 25
7
votes
1 answer
Visualizing the Lane-Riesenfeld Algorithm
Ok so, I keep reading papers about this and non of them have pictures. The lane Riesenfeld algorithm provides a way to subdivide set of points with B-spline conversion.
The quesiton is simple HOW? If you can give me a set of pictures with the…
Makogan
- 1,706
- 12
- 28
7
votes
1 answer
An Effective way to explain Ray Tracing?
In my CS class in high school I'm doing a presentation on Computer Graphics and I wanted to talk about Ray Tracing. I was wondering what would be the easiest way to do this without confusing my audience?
What are some of your personal favorite…
Arjan Singh
- 2,511
- 3
- 22
- 38
7
votes
1 answer
Constant screen-space-width rim shading
As of lately I've been studying a bit of shaders (in Unity), and am trying to recreate the "light-based inline" that can be observed in the latest Legend of Zelda. But maybe the task is a bit above my knowledge, for now.
As from what I can analyze,…
Kroltan
- 171
- 3
7
votes
1 answer
2D sampling with multidimensional transformations
I'm currently learning mathemetical concepts of distribution and the way to use them in a ray tracer with the book "Physically Based Rendering".
Let's start by uniformly sampling an hemisphere:
As you probably know, a way to generate the uniformly…
Qzaac
- 73
- 5
7
votes
2 answers
Why is AO considered Post-Processing?
Ambient Occlusion is a physical approximation to occlude ambient light. If ambient light is not considered post-processing, why is AO? Ambient occlusion has the same inputs as regular deferred lighting, plus kernels and a noise map, but essentially,…
Karim Abdel Hamid
- 295
- 1
- 6
7
votes
2 answers
Fresnel equation with incident angle, n and k as input
I've seen a Fresnel equation for calculating the reflection amount at incidence angle with n and k values defined. This formula usually comes up in relation to computer graphics, but I can't find this equation anywhere in a science context.
Here is…
Kristoffer Helander
- 439
- 3
- 12
7
votes
1 answer
Why is the scan line filling algorithm so seemingly over complicated?
It makes use of tables, buckets, and sorting, which all seem unnecessary.
I don't understand why I can't just fill between pairs of scan line intersections, ignoring vertices and edges with gradient 0.
My lecturer didn't provide the best notes on…
toastedDeli
- 173
- 1
- 3