ASE loader parsing error

Hi,

The ASE loader gives me this error and I really have no clue what is means.

[java] java.lang.Error: Sub-Material index does not match material list
[java] at com.xith3d.loaders.ase.AseMaterial.parse(AseMaterial.java:279)
[java] at com.xith3d.loaders.ase.AseFile.parse(AseFile.java:488)

I loaded the model in viewers like Bitrun and it loads it correctly. Anybody has a clue on how to solve this problem?

Thanks

looks like a bug in the ASE loader. You seem to be the first with this kind of problem. If you think this problem is not because of version incompabilities - you could try to take a look into the ASE-Loader code.

Mmh … Could it be, that the ASE loader doesn’t support Sub-Materials?

Arne

[quote]Mmh … Could it be, that the ASE loader doesn’t support Sub-Materials?
[/quote]
After reading this conversation
http://192.18.37.44/forums/index.php?topic=5651.0

[quote]Materials are 3DS MAX specific. While the loader might be able to support colours (one component of a “Material”) - it doesn’t.

The answer? use textures.
[/quote]
I thought it was the case.

But after following the code in a debugger, it throws the error on one of the sub materials. It let the others passed. Since it’s a graphic artist that creates the model for me, I really have no knowledge of the matter. And he doesn’t understand why it’s not working.

Can you edit the file (it’s just text) and remove the offending nodes?

Sorry for the short answer, got a test in an hour :slight_smile:

Will.

Actually, my graphic artist thinks he knows why it’s not working. Apparently he did something called “collapse” or whatever in 3DS Max and that gave the faulty behavior. He repaired the model without the “collapsing” and now it works fine.

Yeah - that’s the problem with 3dsmax and probably with other 3d modeling programs, too - they have so many different functionalities (materials, your collapsing, …) and they want to save also these special information in their exported files. So they might call it .ASE file and it looks pretty similar to the original ASE spec and works also for most cases, but then there are small differences (also called version incompabilities) and these differences might create errors. + If the spec is not fully open, you can’t even know, when coding the loader, all the functionalities you might have to respect and so on.

Glad it works now :wink: