接口 IGeometryBakingContext

所有已知实现类:
BlockGeometryBakingContext, StandaloneGeometryBakingContext

public interface IGeometryBakingContext
The context in which a geometry is being baked, providing information such as lighting and transforms, and allowing the user to create materials and query render types.
另请参阅:
  • 方法详细资料

    • getModelName

      String getModelName()
      返回 the name of the model being baked for logging and caching purposes.。
      返回:
      the name of the model being baked for logging and caching purposes.
    • hasMaterial

      boolean hasMaterial(String name)
      Checks if a material is present in the model.
      参数:
      name - The name of the material
      返回:
      true if the material is present, false otherwise
    • getMaterial

      Material getMaterial(String name)
      Resolves the final texture name, taking into account texture aliases and replacements.
      参数:
      name - The name of the material
      返回:
      The material, or the missing texture if not found
    • isGui3d

      boolean isGui3d()
      返回 true if this model should render in 3D in a GUI, false otherwise。
      返回:
      true if this model should render in 3D in a GUI, false otherwise
    • useBlockLight

      boolean useBlockLight()
      返回 true if block lighting should be used for this model, false otherwise。
      返回:
      true if block lighting should be used for this model, false otherwise
    • useAmbientOcclusion

      boolean useAmbientOcclusion()
      返回 true if per-vertex ambient occlusion should be used for this model, false otherwise。
      返回:
      true if per-vertex ambient occlusion should be used for this model, false otherwise
    • getTransforms

      ItemTransforms getTransforms()
      返回 the transforms for display in item form.。
      返回:
      the transforms for display in item form.
    • getRootTransform

      Transformation getRootTransform()
      返回 the root transformation to be applied to all variants of this model, regardless of item transforms.。
      返回:
      the root transformation to be applied to all variants of this model, regardless of item transforms.
    • getRenderTypeHint

      @Nullable @Nullable ResourceLocation getRenderTypeHint()
      返回 a hint of the render type this model should use. Custom loaders may ignore this.。
      返回:
      a hint of the render type this model should use. Custom loaders may ignore this.
    • isComponentVisible

      boolean isComponentVisible(String component, boolean fallback)
      Queries the visibility of a component of this model.
      参数:
      component - The component for which to query visibility
      fallback - The default visibility if an override isn't found
      返回:
      The visibility of the component
    • getRenderType

      default RenderTypeGroup getRenderType(ResourceLocation name)
      返回 a RenderTypeGroup with the given name, or the empty group if not found.。
      返回:
      a RenderTypeGroup with the given name, or the empty group if not found.