API reference Obsidian.API.Client
IBlockEntityRenderBuffer interface
What an IBlockEntityRenderer draws into for one block entity in a frame. Transforms are in blocks, from the block's lowest corner, like vanilla's pose stack at the block entity; the light is the block's.
public interface IBlockEntityRenderBuffer
In Obsidian.API.Client.
Methods
Face(BlockModelFace, Matrix4x4)
void Face(BlockModelFace face, Matrix4x4 transform);Draws a face, a quad with a block texture, with a transform. Its cull face and tint index are ignored.
Parameters
face- The face, in sixteenths of a block like model data's.
transform- Where the face's block space goes, in blocks from the block's lowest corner.
Item(ItemStack, Matrix4x4, ItemDisplayContext)
void Item(ItemStack stack, Matrix4x4 transform, ItemDisplayContext display = 7);Draws an item stack as vanilla's item renderer does: its item model, with the model's transform for display, about the transform's origin, like a dropped item (ItemDisplayContext.Ground) or one in an item frame (ItemDisplayContext.Fixed). An item a block entity shows, like a machine's input.
Parameters
stack- The stack; an empty one draws nothing.
transform- Where the item's origin goes, in blocks from the block's lowest corner.
display- The model's display transform: ground or fixed.
Model(BlockModelPart, Matrix4x4)
void Model(BlockModelPart model, Matrix4x4 transform);Draws a declared model with a transform.
Parameters
model- One of
BlockEntityRendererProperties.Models, turned in quarter turns like a blockstate file's model beforetransform. transform- Where the model's block space goes, in blocks from the block's lowest corner.