Small Bug in MTLLoader

Hi,
I guess, there is a small bug in the class MTLLoader. Instead of
[java]if (cmd.equals(“d”) || cmd.equals(“tr”)){
float tempAlpha = scan.nextFloat();
if (tempAlpha != 0){
alpha = tempAlpha;
transparent = true;
}[/java]
it should read
[java]if (cmd.equals(“d”) || cmd.equals(“tr”)){
float tempAlpha = scan.nextFloat();
if (tempAlpha < 1){
alpha = tempAlpha;
transparent = true;
}[/java]
since d=1 means opaque.

Michael

1 Like