Code Monkey home page Code Monkey logo

tray's Introduction

TRay

TRay for "yet another Ray Tracer".

Served as my bachelor's undergraduate graduation project, now as a playground for leaning rendering.

Build and Run

TRay is OK with clang 15.0.7. Some builtin function may fail MSVC.

cd build and build .. should be ok. The required libs should be libglfw.a only, for supporting ImGUI and some other features based on OpenGL.

I dislike build systems, so any related problems please work it out by yourself. I am trying to make it OK on most platforms, by writing (for me) most portable codes.

Project Structure

+---.vscode
+---apps
|   +---sample_images
|   +---test
|   |   \---bin
|   \---TRay
|       \---bin
+---build
+---extern
|   +---file_dialog
|   +---glad
|   +---GLFW
|   +---ImGui
|   +---KHR
|   \---nlohmann
+---include
|   +---accelerators
|   +---cameras
|   +---core
|   +---filters
|   +---gui
|   +---integrators
|   +---lights
|   +---loaders
|   +---materials
|   +---samplers
|   +---shapes
|   \---textures
+---lib
\---src
    +---accelerators
    +---cameras
    +---core
    +---filters
    +---gui
    +---integrators
    +---lights
    +---loaders
    +---materials
    +---samplers
    \---shapes

Features

IO

GUI

  • Basic Framework
    • Image Preview
    • Render Control
      • Start/Pause Rendering
    • Scene Description File I/O

TODO

Obj-based scene file formats. Class-based loaders, each class handles its own json.

API


  • Geometry, Transformation
    • Coordinate System
    • Vector
    • Point
    • Normal
    • Ray
    • Bounding Box
    • Transformation
    • Applying Transformation
    • Animating Transformation
    • Interaction
  • Shape
    • Interface
    • Sphere
    • Triangle Meshes with tiny_obj_loader
  • Primitive (Shape and shading info), Acceleration
    • Interface
    • Primitives
      • Geometric Primitive
      • Transformed Primitive
      • ...
    • Aggregates
      • Plain linear structure
      • BVH
      • ...
  • Color, Radiometry
    • Interface
    • Color Representation
      • RGB Tuple
      • XYZ
      • ...
  • Camera
    • Interface
    • Camera Model
    • Cameras
      • Perspective Camera with Thin Lens
      • Environment Camera
      • Realistic Camera
      • ...
  • Sampling
    • Interfaces
    • Samplers
      • Stratified
      • Halton
      • (0, 2)-Sequence
      • Maximized Minimal Distance
      • Sobol'
      • Cascaded Sobol' Sampling
      • MatBuilder
    • Film and Filter
    • JPEG and uint_8 Output Support
  • Reflection, Material
    • Interface
    • Reflections
      • Specular
      • Lambertian
      • Microfacet Models
        • Oren–Nayar Diffuse Reflection
        • ...
    • BSDF
  • Texture
    • Interface
    • Textures
      • Checkerboard
      • ...
    • Noise
  • Light
    • Interface
    • Light Sources
      • Distant (Directional) Light
      • Area Light
      • Infinite Area Light
      • Point Light
      • ...
  • Integrator
    • Whitted
    • Direct Lighting
    • Basic Path Tracing
    • ...
  • System
    • Parallelism
    • Statistics (Counter only)
    • Memory Pool (This?)
    • Better Scene Format and Loader
    • API
    • Better UI

https://www.pbr-book.org/3ed-2018/Utilities/Parallelism#ParallelForLoops

Others

Design: Film + Filter = Sensor?

Framework: Everything on a rooted obj-tree?

Code style

  • File name: KeyClass, or keyFunction.
  • Class and type: BigCamel.
  • Function: aloneFunction, memberFunction, parseHtml, checkId.
  • Variable: local_var, global_var, m_private_var, public_var.
  • Const or macro: kConstValue, SOME_MACRO.

tray's People

Contributors

jasonphone avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.