Skip to content

Taeil-Nam/RayTracing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RayTracing

This project is made by Taeil-Nam, GunJoong-Kim

Limitation

  • Program doesn't use GPU, only use CPU.
  • Not supported Real-Time Rendering.
  • In "PATH" rendering mode, program uses Path Tracing and it takes a more time to rendering.
  • In "PATH" rendering mode, if you want to see clean image, increase SAMPLE_PER_PIXEL in inc/minirt.h:17
    • Recommend increasing the value at least 500 but rendering would be TOO SLOW..

Getting Started

Prerequisites

  • Intel CPU Mac
  • MacOS Version = 12.6.2
  • Clang Version = 12.0.0
  • MiniLibX (graphics library)
  • swiftc 5.7.2 (to compile MiniLibX)

Installation

  1. Git clone
    $> git clone https://github.com/Taeil-Nam/RayTracing.git
  2. Move to project directory
    $> cd RayTracing/
  3. Use "make" command to create program
    $> make

Usage

Execute the program with valid map file as argument.

Valid map file name format = map/[file name].rt

Ex) rendering map "box.rt"

$> ./RayTracing map/box.rt

please refer to the Demo video

📌All file names with "_bonus" shown in the video have been changed to file names with "_bonus" removed.

Rendering mode

You can select the rendering mode by editing the code.

  1. PHONG(default mode)
    • Uses Phong Reflection model.
  2. PATH
    • Uses Path Tracing model.

Ex) in src/main.c:49 minirt->illumination = PHONG; or minirt->illumination = PATH;

Features

  • Ray Tracing
  • Phong Reflection
  • Path Tracing
  • Rendering object (sphere, plane, cylinder, cone)
  • Camera
  • Multi-spot light
  • Checkerboard texture
  • Image texture
  • Bump map (Normal map) texture
  • multi-threading
  • BVH (Boundary Volume Hierarchy)

Results

  • In "PATH" rendering mode, SAMPLE_PER_PIXEL = 2000 남태일-RT

License

Distributed under the MIT License. See LICENSE.txt for more information.

Contact

Taeil-Nam - nam0314@gmail.com

Project Link: https://github.com/Taeil-Nam/RayTracing

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published