A MaterialCreator is a function that takes a name, a list of words from the current Mtl line, and maybe the material that was already in the material library under the name. It outputs a material if successfully created from the given information, but it can also decide to not return a material even though it could, leaving the library unchanged.
This is subject to change as the rationale for it is not entirely clear, suspecting the mechanism can be simpler.
A library of materials, a dictionary mapping names to materials.
Decode an mtl data string into a material library. This can fail so a Result is returned which can hold an error message if parsing fails.