rayito

Simple Ray Tracer written in Go.

  • 所有者: phrozen/rayito
  • 平台:
  • 許可證: MIT License
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

Rayito

Rayito is a simple but educational ray tracer written in Go meant as a project to learn programming languages and optimization in Computer Graphics.

"In computer graphics, ray tracing is a technique for generating an image by tracing the path of light through pixels in an image plane and simulating the effects of its encounters with virtual objects." - Wikipedia

Rayito is meant to be simple, but implements a full set of features like:

  • Multi Threading
  • Oversampling (anti aliasing)
  • Ambient and Point Lights
  • Custom Materials
  • Specular and Difuse shading (Phong)
  • Reflection (mirror)
  • Refraction (transparency)
  • Soft Shadows
  • Scene description and parsing
  • PNG Export
  • and more...

Code is meant to be as clear as possible (no cutting names on variables) so it's meant to be read directly. In order to try Rayito either clone the git repository or do:

go get github.com/phrozen/rayito

After building the binary you can start to render by using some scenes in the samples directory or write your own.

Usage

Set workers to the number of threads your CPU can handle (defaults to CPU Max Threads).

rayito -workers=8 -file="samples/scene.txt"

Samples

Helix

Spheres

主要指標

概覽
名稱與所有者phrozen/rayito
主編程語言Go
編程語言Go (語言數: 1)
平台
許可證MIT License
所有者活动
創建於2015-10-01 02:36:17
推送於2017-02-06 20:12:30
最后一次提交2017-02-06 14:04:30
發布數0
用户参与
星數117
關注者數6
派生數4
提交數8
已啟用問題?
問題數2
打開的問題數1
拉請求數0
打開的拉請求數0
關閉的拉請求數0
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?