All Projects → JVillella → tiny-path

JVillella / tiny-path

Licence: MIT license
An instructive one-file Ruby path tracer

Programming Languages

ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to tiny-path

mcrt
Monte Carlo Raytracer from Scratch in C++11/14
Stars: ✭ 22 (-58.49%)
Mutual labels:  monte-carlo, global-illumination, ray-tracer
Super-Sunshine
A ray-tracer with a simple scene description language for easily generating beautiful images.
Stars: ✭ 115 (+116.98%)
Mutual labels:  computer-graphics, ray-tracer
Yocto Gl
Yocto/GL: Tiny C++ Libraries for Data-Driven Physically-based Graphics
Stars: ✭ 1,391 (+2524.53%)
Mutual labels:  computer-graphics, path-tracer
Miyuki Renderer
Experimental Physically Based Renderer
Stars: ✭ 89 (+67.92%)
Mutual labels:  computer-graphics, path-tracer
Giraffe
Distributed Monte Carlo Path Tracer 分布蒙特卡洛路径追踪器
Stars: ✭ 155 (+192.45%)
Mutual labels:  computer-graphics, path-tracer
LumillyRender
Monte Carlo path tracing implementation on Rust
Stars: ✭ 36 (-32.08%)
Mutual labels:  path-tracer, ray-tracer
monte-carlo-ray-tracer
Physically based renderer with Path Tracing and Photon Mapping.
Stars: ✭ 246 (+364.15%)
Mutual labels:  monte-carlo, global-illumination
fluctus
An interactive OpenCL wavefront path tracer
Stars: ✭ 55 (+3.77%)
Mutual labels:  global-illumination, path-tracer
Ray-Tracer
Simple Ray Tracer
Stars: ✭ 18 (-66.04%)
Mutual labels:  computer-graphics, ray-tracer
rasterator
Real-time software rasterizer written in C++ with windowing and model loading support.
Stars: ✭ 15 (-71.7%)
Mutual labels:  computer-graphics
mcx
Monte Carlo eXtreme (MCX) - GPU-accelerated photon transport simulator
Stars: ✭ 77 (+45.28%)
Mutual labels:  monte-carlo
glText
Cross-platform single header text rendering library for OpenGL
Stars: ✭ 93 (+75.47%)
Mutual labels:  computer-graphics
PARE
Code for ICCV2021 paper PARE: Part Attention Regressor for 3D Human Body Estimation
Stars: ✭ 222 (+318.87%)
Mutual labels:  computer-graphics
MineCube
A Cool Voxel Editor Based on OpenGL 3.3+ !
Stars: ✭ 23 (-56.6%)
Mutual labels:  computer-graphics
GX-EncinoWaves
Graphics Experiment - FFT Ocean Water Simulation
Stars: ✭ 34 (-35.85%)
Mutual labels:  computer-graphics
GOMC
GOMC - GPU Optimized Monte Carlo is a parallel molecular simulation code designed for high-performance simulation of large systems
Stars: ✭ 41 (-22.64%)
Mutual labels:  monte-carlo
papers
Summarizing the papers I have read (Japanese)
Stars: ✭ 38 (-28.3%)
Mutual labels:  computer-graphics
WebGL-Billiards
ThreeJS based 8-ball pool
Stars: ✭ 28 (-47.17%)
Mutual labels:  computer-graphics
ProceduralTerrain
Polygon is a procedural mesh generator in Unity.
Stars: ✭ 18 (-66.04%)
Mutual labels:  computer-graphics
ComputerGraphics-OpenGL
No description or website provided.
Stars: ✭ 25 (-52.83%)
Mutual labels:  computer-graphics

Tiny Path

A tiny, one-file, Monte Carlo path tracer written in a few hundred lines of Ruby. The source accompanied a short talk I gave as an introduction to Ray Tracing (presentation slides available here). The hope is that it provides a simple to understand example. The image below is the rendered output at 1024spp.

Features

  • Monte Carlo method
  • Global illumination
  • Diffuse, and specular BRDFs
  • Ray-sphere intersection
  • Soft shadows
  • Anti-aliasing
  • Modified Cornell box
  • PNG image format output
  • Progressive saving

Usage

$ ruby tiny-path.rb --help

Usage: tiny-path.rb [options]
    -w, --width=width                Image width
    -h, --height=height              Image height
    -s, --spp=spp                    Samples per pixel
    -o, --output=filename            Output filename
    -p, --[no-]progressive-save      Save file while rendering

To render the scene at 16 samples per pixel, run the following command,

$ ruby tiny-path.rb -s 16

It will save a file in the same directory titled output.png.

Author

Julian Villella

License

Tiny Path is available under the MIT license. See the LICENSE file for more info.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].