Added HDRI environment mapping on reflections
Experimenting with writing triton kernels with AI assistance.
Code available at https://github.com/nomadicsynth/trito...
Triton Raytracing Kernel
Geometry: spheres
Animated: 2 spheres (sin/cos)
Camera: pinhole, pixel-center, aspect-correct
Sampling: single-sample (no AA)
Intersection: analytic ray–sphere
Normals: per-hit geometric normal
Lighting: single point light
Shading: ambient + Lambertian diffuse + Blinn‑Phong specular
Specular: per-sphere shininess
Shadows: hard (shadow rays)
Reflections: single-bounce
Tonemap: clamp 0–1 - 8-bit
Output: float RGB - uint8, PNG/EXR or BGR24 - ffmpeg
Accel: Triton GPU kernels, block/grid, async pinned transfers
Environment: equirectangular HDRI (EXR) sampling
Env sampling: sample_equirect — bilinear grid_sample on CUDA, cached EXR tensor
Refl env: reflection miss - env contribution blended by material reflectivity
HDRI: Golden Bay - Greg Zaal (https://polyhaven.com/a/golden_bay)
Sound: Outdoor Suburb Ambience - Youtube Audio Library