Git Product home page Git Product logo

babylon_1000_lights_example's Introduction

babylon_1000_lights_example

Capture

1000 lights on 1000 individual meshes + instances at 60fps, can we get a proper web based forward+ engine now?

Works about the same in WebGL or WebGPU. If I push it to 10K objects with 1000 light sources (so 10 instances per), then I get about 10FPS more on WebGPU, still about 55FPS on a single thread, not bad! Initial compilation time is just slow as you scale up. It starts getting VERY slow after 800 lights due to the recursive compilation process.

Note you can extend this with instances but each instance uses the same parent material so instanced meshes need to be close to the maximum of 4 light sources that can effect a single material. You can sort of fake a forward+ scene this way and reassign affected meshes on the fly CPU-side but this is not as efficient as proper modern lighting engines.

Just open the HTML file in browser, it will use cdn links to pull BabylonJS.

babylon_1000_lights_example's People

Contributors

joshbrew 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.