Giter VIP home page Giter VIP logo

starlight's Introduction

Starlight (Fabric) (BETA)

Fabric mod for completely rewriting the vanilla light engine.

Known Issues (This is why we're in BETA)

Check out The issues tab Please note that since this is a beta, there could be some (severe) light corrupting issues. Do not use if you do not want to take that risk!

Contact

Discord

Results

Starlight crushing all

  • seed: vanillakekw
  • CPU: Intel i7-8750H @ 2.20GHz (Turboboost disabled)
  • Benchmark 101x101 chunks syncloaded centered at (0,0), Warmup 101x101 chunks syncloaded centered at (-10000, -10000)
  • CPU time was measured by forcing the light executor to be single threaded, which allowed very simple CPU thread time measuring via visualvm.
  • Starlight implementation was tested on Tuinity

The data shows everything we need to know. Starlight took ~7 seconds to generate the light, while Vanilla's light engine took ~220s seconds. Phosphor took ~170s. Compared to the best mod available (Phosphor), Starlight is about 25 times faster at generating light for chunks - and about 35 times faster than the vanilla light engine.

Starlight will relight vanilla lit chunks due to a difference in how sky light is managed, and the new skylight data is incompatible with the vanilla skylight format. However, when vanilla loads the chunks, it will simply relight the chunks, so the save format is compatible with vanilla. If you are going to compare starlight to vanilla or vice versa, you should be aware of the above - relighting chunks is always more expensive than loading them.

Purpose

The performance of the vanilla engine is just awful. Existing modifications like Phosphor or Paper's light engine changes (some of Paper's changes include Phosphor's) fail to fix this issue.

Phosphor's changes to the existing light engine are very good, but there's only so much that can be done to vanilla's code to improve performance.

Paper also suffers from the same issue as Phosphor, as they also opt for changing vanilla code. However, Paper's changes have some technical problems that result in lighting broken lighting. See https://i.imgur.com/bK38jgS.png. For reference, this is what it should look like (generated via starlight): https://i.imgur.com/VND58Yr.jpg

Could these technical issues be fixed? Maybe, nobody knows what exactly is causing the issue, and when the vanilla light engine is overcomplicated debugging it was such a mess that everyone working on it gave up. Paper's changes also don't even target obvious issues with the light engine...

Effectively, it's really hard to fix the performance of the light engine by editing it - it's such a catastrophe it's better off burning it to the ground and starting anew.

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.