Maraytr - Marek's Ray-tracer
Maraytr is a ray-tracer written with high focus on algorithms and data structures rather than on performance. I decided to make it as revision and deeper understanding of theory and math behind ray-tracing. And also because ray-tracing is fun! The core was written in four days and without third-party libraries. The scene is represented as CSG and supported primitives are sphere, cube, and plane. It is possible to do basic boolean operations like union, intersection, subtraction, or xor.
Personal project, tags: C#, Win Forms
GitHub repository: NightElfik/Maraytr
Figure 1: Various images from this project.
One day I have decided that I want to write a ray-tracer. I have been taught in school a lot of theory but I have never written a ray-tracer from scratch.
This report is not meant to be a step-by-step tutorial how to make a ray-tracer but rather explanation of features and design decisions of my implementation. However, this article offers a good overview of core functionalities and can serve as an inspiration for your own implementation. I believe that a step-by-step guide is actually not that useful and solving problems by your own (with hints) is the best way to learn. In case you are stuck please refer to the code hosted on GitHub.
Comments for this chapterNote that comments are separate for every chapter.comments powered by Disqus
Table of contents
- 1 Introduction
- 2 Scene representation
- 3 Ray caster
- 4 Ray tracer
- 5 Extensions
- 6 Conclusion