7
votes
Is there a method to do ray marching style modulus repeat with raytracing?
I've tried to figure this out as well, but I don't think there is a solution that is just as performant as tracing one sphere. Basically you would want to cast one ray to hit a infinite set of ...
7
votes
Accepted
Volume Rendering (Path Tracing & Real-Time)
Ray marching is a ray tracing method where you take multiple steps along a ray to find intersection with geometry or to perform integration of in-scattered light from participating media (fog, clouds, ...
6
votes
Accepted
Volumetric integration in Frostbite
What is wrong with it seems to be explained on the next two slides: it leads to non-energy-conserving results, where the apparent brightness of the volume changes depending on the scattering ...
5
votes
Accepted
How to compute normal of surface from implicit equation for ray-marching?
The usual way of doing this with raymarching is to define your surface as a signed-distance field and use finite differences to get the gradient of the distance function at the point you’re sampling. ...
4
votes
Accepted
How to align Ray Marching on top of traditional 3D rasterization?
The problem, I think, is that you are comparing two different kinds of depth values. For want of better terms, the rasterizer's depth buffer stores 'parallel' depth, whereas raymarching calculates '...
3
votes
Accepted
Approximating surface normals from signed distance bounds
Let $f:\mathbb{R}^n\to \mathbb{R}$ be a signed distance function for the set $\mathbb{R}^n \setminus \Omega$, meaning:
$$f(p) = \begin{cases} d(p, \partial\Omega), & p \in \Omega, \\ -d(p,\partial\...
3
votes
Accepted
Why is the z coordinate simply set to 1 for setting up direction of a ray in ray marching
It depends on your setup. Of course you can normalize the direction to have length 1, but it is usually unnecessary. The following figure depicts the differences:
Round frustum end face
Flat frustum ...
3
votes
Vulkan Ray Tracing analogue of Optix's OPTIX_BUILD_INPUT_TYPE_CURVES
I don't think vulkan has any way of natively doing curves.
I think you will need to program it yourself using VK_RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_KHR, by providing your own bounding ...
3
votes
Accepted
Ray Tracing With Continuous Refraction
You can refer to the available literature on the topic. The papers I am aware of are:
Ray Tracing in Non-Constant Media
Interactive Rendering of Non-Constant, Refractive Media Using the Ray Equations ...
3
votes
Accepted
Is there a better, more elegant way of translating/rotating my camera in my 3d raymarched world or am I stuck with trigonometry?
A reliable way of getting the forward/left directions relative to the view is to use the camera rotation matrix itself to produce forward, Up and right vectors.
...
3
votes
Accepted
Rendering a particle system as a smooth blob
For culling faraway particles: as lightxbulb said, the keyword to search for is "acceleration structure". There are a variety of options: BVH, octree, kd-tree, uniform grid, or some ...
3
votes
How can I convert signed distance field to a mesh?
with CGAL you can generate mesh by implicit function. https://doc.cgal.org/latest/Mesh_3/index.html
Search for "implicit". There is an example of generating meshes from the funciton of a sphere.
2
votes
Is there a method to do ray marching style modulus repeat with raytracing?
If you want to warp the space as in the raymarching infinite spheres example,
...
2
votes
Accepted
Reading thesis on cone tracing, did the author make a mistake?
It’s kind of inaccurately stated—by comparing the SDF with a linearly increasing radius, the shape that’s being traced out is a cone with a hemisphere on the end, something like this:
At any point ...
2
votes
How can I convert signed distance field to a mesh?
After many research I figured out how it works:
he defined three buffer in glsl and i get 3 sampler2D for multipass, in each fbo attachments. the params are (buffer : file : id) file is the targeted ...
2
votes
Accepted
Why does UV tiling affect performance in volumetric ray marching?
It sounds like you are experiencing a loss of texture cache hit rate on your 3D texture.
As with any modern processor, GPUs have a cache hierarchy. Texture units typically read from a local L1 cache, ...
1
vote
Accepted
understanding SDF[Signed Distance Functions] for a torus
This turned into a rabbit hole for me hopefully it helps answer your question, I recommend trying out the various functions on the ShaderToy website. Just drop them in and change the call to "...
1
vote
understanding SDF[Signed Distance Functions] for a torus
The following video discusses the SDFs of various primitives (linked to torus section):
https://youtu.be/Ff0jJyyiVyw?t=491
It discusses a torus but not the capped variant. The rest of the channel has ...
1
vote
How to calculate ray-origin and ray-direction in vertex shader working universally for any projection and using interpolators for performance
There is no universal solution here since there are many different small variations that can be applied to get a specific result.
One of the things that trips people up when computing ray's in the ...
1
vote
Glitches with raymarcher shader
The code isn't taking enough steps for the ray to hit anything where the sphere and the floor meet. minF is smaller in that region, so the ray marches forward until it runs out of steps and then gives ...
1
vote
Porting from DXR/HLSL to Vulkan Ray Tracing Extension/GLSL
As I understand GLSL_EXT_ray_tracing.txt, gl_RayTmaxEXT contains the current t in intersection shaders, due to the following pieces of information given in ...
1
vote
Porting from DXR/HLSL to Vulkan Ray Tracing Extension/GLSL
According to this document, one should be able to extract those values through
gl_RayTminEXT and gl_RayTmaxEXT GLSL built-ins for intersection shader.
Further comments are welcome.
1
vote
Accepted
SSR/RTLR - hitting object/ending condition
The termination condition is that the ray passes through the surface represented in the depth buffer. To track this, you have to calculate the z position of the ray at the current step, and compare it ...
1
vote
Parallax/relief mapping with gl_FragDepth and conservative depth
Unfortunately, gl_FragDepth won't enable you to write outside of the rasterized triangle's screen-space bounds. All it enables is to modify the values written to ...
1
vote
Volume Rendering: Implementation
For your first question, the basic process should be (simplified version):
...
1
vote
Frustum aligned volume integration - aliasing issue - temporal reprojection
You can look into alias-free volumetric sampling algorithm by Huw Bowles for potential solution to the ray marching aliasing issues. The basic idea is to snap your samples to planes based on the ray ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
raymarching × 35raytracing × 9
volumetric × 7
glsl × 6
rendering × 3
shader × 3
texture × 3
pathtracing × 3
lighting × 3
rasterizer × 3
3dtexture × 3
signed-distance-field × 3
volumetric-scattering × 3
opengl × 2
mathematics × 2
vulkan × 2
webgl × 2
hlsl × 2
normal-mapping × 2
voxelization × 2
3d × 1
mesh × 1
geometry × 1
brdf × 1
gpu × 1