three-raytracing-renderer

1.0.2 • Public • Published

three-raytracing-renderer

pure headless JS renderer based off the original THREE.RaytracingRenderer

Features

  • RaytracingRenderer ES module
  • Runs with up to date threejs version
  • Runs pure JS, headless without canvas, weblgl or other GPU dependencies

Background

One of the strengths of Three.js is its design simplicity, which allows for new renderers and add-ons to be easily developed. In its early days, I found many of the "extras" renderers fun and interesting. However, it's understandable that these get removed when they become less maintainable or less relevant to modern web trends.

In this package I wanted to bring back RaytracingRenderer that was removed in 2020 similar to what three-software-renderer did for THREE.SoftwareRenderer.

One reason why I recently wanted to use RaytracingRenderer over SoftwareRenderer was to have richer tones compared to the flat shadding in SoftwareRenderer, which I noticed after migrating threejs-term away from it's canvas dependency.

Variants

  • RaytracingRenderer - the current non-browser, UIntArray implementation
  • RaytracingRendererClassic - the original single threaded raytracing renderer that writese out to a canvas
  • RaytracingRendererWorkers - the changes I added to allow Web Workers to speed up rendering (To be added)

Usage

browser-test

terminal-test

Other renderers

/three-raytracing-renderer/

    Package Sidebar

    Install

    npm i three-raytracing-renderer

    Weekly Downloads

    0

    Version

    1.0.2

    License

    MIT

    Unpacked Size

    494 kB

    Total Files

    11

    Last publish

    Collaborators

    • zz85