Class SodiumAnimatedTextureCompat

java.lang.Object
dev.engine_room.vanillin.item.SodiumAnimatedTextureCompat

public class SodiumAnimatedTextureCompat extends Object
An attempt to be compatible with sodium's animated texture optimization.

Unfortunately Vanillin does not have high time resolution as to what models are on the screen, so once a sprite is observed we'll keep marking it as active until the next renderer reload.

This should probably be implemented in Flywheel proper with an API on Mesh to get a list of TextureAtlasSprites. That way a backend would be able to decide which sprites are active based on instance counts, visibility, etc. I have a feeling such an API could be useful otherwise too.

  • Constructor Details

    • SodiumAnimatedTextureCompat

      public SodiumAnimatedTextureCompat()
  • Method Details

    • add

      public static void add(net.minecraft.client.renderer.texture.TextureAtlasSprite sprite)
    • beginFrame

      public static void beginFrame()
    • onReloadRenderer

      public static void onReloadRenderer()