Giter VIP home page Giter VIP logo

mc-sandpaper's Introduction

Sandpaper is a free and open-source optimization mod for the Minecraft client that improves frame rates, reduces micro-stutter, and fixes graphical issues in Minecraft.

Minecraft rendering graph

Technical details

When connected to a multiplayer server, the Minecraft client synchronizes a local copy of the multiplayer world. Objects represented by entities are simulated both on the server and the client.

Minecraft runs at a fixed rate of 20 game ticks per second, where entities are updated in accordance with physics, momentum, and collision. However, client-side game ticks are computed on the main thread, which also runs the OpenGL rendering system, causing a lag spike every 50ms. In a world with a high amount of entities, the significant tick duration leads to an effective frame rate of 20 fps, despite the average frame rate running at above 60 fps.

Sandpaper offloads a significant portion of Minecraft's client-side game ticks to an internal thread pool, which performs the necessary calculations related to entities. Entity updates are parallelized and synchronized by neighboring chunk boundaries, allowing independent behavior to operate simultaneously. This greatly reduces the lag spike caused by the client-side tick duration, resulting in smoother gameplay.

Sandpaper is compatible with renderer optimization mods, including OptiFine and Sodium. While Sandpaper is focused on the client tick, OptiFine and Sodium both optimize the OpenGL renderer itself. It is recommended to use both sets of optimizations together for the best possible performance.

Building from source

Requirements

  • OpenJDK 8 (required by Minecraft Forge)

Building with Gradle

Sandpaper uses a typical Gradle project structure and can be built by simply running the default build task. After Gradle finishes building the project, you can find the build artifacts (typical mod binaries, and their sources) in build/libs.

mc-sandpaper's People

Contributors

danielhuang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

mc-sandpaper's Issues

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.