This project is inspired by Peter Shirley's Ray Tracing series.
- Basics
- Computer Graphics
- C in Practice
- Hopefully
- CUDA Acceleration
- Perfromance Engineering
1200 16:9 500 samples per pixel 50 max depth
16 partitions
./inOneWeek > image_parallel.ppm 49831.04s user 333.87s system 1242% cpu 1:07:16.10 total
prime-select nvidia
# restart the computer to make sure correct driver is loaded
time ./obj > final.ppm
Rendering a 1200x800 image with 500 samples per pixel in 8x8 blocks.
took 146.189 seconds.
./obj > final.ppm 146.42s user 0.14s system 99% cpu 2:26.65 total
Rendering a 1200x800 image with 500 samples per pixel in 8x8 blocks.
took 129.241 seconds.
./obj > final.ppm 129.46s user 0.15s system 99% cpu 2:09.67 total
Rendering a 1200x800 image with 500 samples per pixel in 8x8 blocks.
took 130.967 seconds.
./obj > final.ppm 131.20s user 0.14s system 99% cpu 2:11.39 total
-
Ray Tracing Essentials from nVidia
-
Ray Tracing Essentials, Part 1: Basics of Ray Tracing
- view ray, shadow ray
- do it from the eye, limited number of rays to cast
- in film, 3000 rays per pixel, add up rays and approximate the right answer.
-
Ray Tracing Essentials Part 2: Rasterization versus Ray Tracing
-
Rasterization (z-buffer) loop:
for each object for each pixel -> closer ?
-
Ray Tracing loop:
for each pixel for each object -> closest ?
-
Bounding Volume Hierarchy (BVH)
- a tree structure for effecient rendering
- model's triangles are divided by multiple boxes, so the ray only will check a subset of all triangles.
-
Rasterization and Ray Tracing can work together.
-
-
Ray Tracing Essentials Part 4: The Ray Tracing Pipeline
- Ray Tracing pipeline has 5 shaders:
- Control other shaders:
- Ray generation shader
- Define object shapes:
- Intersection shader(s)
- Control per-ray behavior (often many types)
- Miss shader(s)
- Closest-hit shader(s)
- Any-hit shader(s)
- Control other shaders:
- Ray Tracing pipeline has 5 shaders:
-
Ray Tracing Essentials Part 5: Ray Tracing Effects
- Hard shadows: shooting one ray from a point light
- Soft shadows: shooting a bunch of rays from an area light
- light bouncing around: Interreflection / Indirect lighting / Color bleeding / Global illumination
- Glossy reflections
- Ambient occlusion
- It has been used with rasterization for a long time.
- With ray tracing, we can get a better answer.
- Depth of field.
- Motion blur
- Ray marching (an atmospheric effect)
- Caustics
- light effect with water or other transparent media
-
Ray Tracing Essentials Part 6: The Rendering Equation
- It sums up how lights get into the eye
- How to sample the rays on one point in the scene
- Random sampling uniformaly over a unit sphere
- Add BSDF
- Add ligithing
-
Ray Tracing Essentials Part 7: Denoising for Ray Tracing
- using denoise will improve the performance.
- less samples per pixel
- start with a noisy result and reconstruct
- many different approaches
- denoising by effect
- deep learning for image denoising
- using denoise will improve the performance.
-
-
Ray Tracing Gems II (Under construction)
-
Introduction to Computer Graphics (fall 2018), Lecture 12: Accelerating Ray Tracing
-
Future of Gaming : Rasterization vs Ray Tracing vs Path Tracing
Use valfrind
and cuda-memcheck
together. reference
com.spotify.docker.client
is no longer maintained, I have to download 2 jars manually and copy them to $ECLISPE/dropins/plugins
.
Then start eclipse with eclipse -clean
, so the eclipse will clean the cache and load plugins.
- Dependencies
com.fasterxml.jackson.datatype.jackson-datatype-guava_2.9.9.v20190906-1522.jar
com.spotify.docker.client_8.11.7.v20180731-1413.jar
Beginner-Friendly Vulkan Tutorials
After installation, vkcube
is a black window. I have to remove intel_icd.*
and radeon_icd.*
from /usr/share/vulkan/icd.d/
in order to pass vkvia