Package foundry.veil.render.post
Interface PostPipeline.Context
- All Superinterfaces:
ShaderTextureSource.Context
- All Known Implementing Classes:
PostPipelineContext
- Enclosing interface:
- PostPipeline
Context for applying post pipelines.
-
Method Summary
Modifier and TypeMethodDescriptionvoidapplySamplers(ShaderProgram shader) Applies each sampler to the specified shader.voidDraws a quad onto the full screen usingDefaultVertexFormat.POSITION.default AdvancedFbogetFramebufferOrDraw(net.minecraft.resources.ResourceLocation name) Retrieves a framebuffer by id or the main framebuffer if it doesn't exist.default net.minecraft.client.renderer.texture.AbstractTexturegetTexture(net.minecraft.resources.ResourceLocation name) Retrieves a texture by id.voidsetFramebuffer(net.minecraft.resources.ResourceLocation name, AdvancedFbo framebuffer) Sets a framebuffer to a name.voidsetSampler(CharSequence name, int id) Binds a named sampler id.Methods inherited from interface foundry.veil.render.shader.texture.ShaderTextureSource.Context
getFramebuffer
-
Method Details
-
drawScreenQuad
void drawScreenQuad()Draws a quad onto the full screen usingDefaultVertexFormat.POSITION. -
setSampler
Binds a named sampler id. All samplers can be applied withapplySamplers(ShaderProgram)for adding them to shaders.- Parameters:
name- The name of the samplerid- The id of the texture to bind
-
setFramebuffer
Sets a framebuffer to a name. This allows post stages to create new framebuffers that can be accessed later on.- Parameters:
name- The name of the framebufferframebuffer- The framebuffer to set
-
applySamplers
Applies each sampler to the specified shader.- Parameters:
shader- The shader to apply the samplers to
-
getFramebufferOrDraw
Retrieves a framebuffer by id or the main framebuffer if it doesn't exist.- Parameters:
name- The name of the framebuffer to retrieve- Returns:
- The framebuffer with that id or the main framebuffer
-
getDrawFramebuffer
AdvancedFbo getDrawFramebuffer()- Returns:
- The main framebuffer to draw into. This is later copied onto the main framebuffer
-
getTexture
default net.minecraft.client.renderer.texture.AbstractTexture getTexture(net.minecraft.resources.ResourceLocation name) Description copied from interface:ShaderTextureSource.ContextRetrieves a texture by id.- Specified by:
getTexturein interfaceShaderTextureSource.Context- Parameters:
name- The name of the texture to retrieve- Returns:
- The texture with that id or the missing texture if it was not found
-