Class VanillaShaderCompiler
java.lang.Object
foundry.veil.impl.client.render.dynamicbuffer.VanillaShaderCompiler
Compiles vanilla shaders asynchronously.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
clear()
static int
getActiveDynamicBuffers
(net.minecraft.client.renderer.ShaderInstance shaderInstance) Retrieves the active buffers for an existing shader program.boolean
static void
markRendered
(String shaderInstace) reload
(Collection<net.minecraft.client.renderer.ShaderInstance> shaders) Attempts to preload all vanilla minecraft shader files before creating the shaders on the CPU.
-
Constructor Details
-
VanillaShaderCompiler
public VanillaShaderCompiler()
-
-
Method Details
-
reload
public CompletableFuture<?> reload(Collection<net.minecraft.client.renderer.ShaderInstance> shaders) Attempts to preload all vanilla minecraft shader files before creating the shaders on the CPU.- Parameters:
shaders
- The shaders to reload- Returns:
- A future for when vanilla shaders have reloaded
-
isCompilingShaders
public boolean isCompilingShaders()- Returns:
- Whether shaders are currently being rendered
-
getActiveDynamicBuffers
public static int getActiveDynamicBuffers(net.minecraft.client.renderer.ShaderInstance shaderInstance) Retrieves the active buffers for an existing shader program.- Returns:
- The active buffers in the specified program
- Since:
- 2.3.0
-
markRendered
-
clear
@Internal public static void clear()
-