Class MtlParser

java.lang.Object
com.hypixel.hytale.builtin.buildertools.objimport.MtlParser

public final class MtlParser extends Object
Parser for Wavefront MTL material files. Extracts diffuse colors (Kd) and texture paths (map_Kd) for each material.
  • Method Details

    • parse

      @Nonnull public static Map<String, MtlParser.MtlMaterial> parse(@Nonnull Path path) throws IOException
      Parses an MTL file and returns material definitions.
      Parameters:
      path - absolute path to the MTL file
      Returns:
      map of material name to material data
      Throws:
      IOException - if the file cannot be read