Maniphest T26475

<instance_material> wrong in Collada export.
Closed, Archived

Assigned To
Nathan Letwory (jesterking)
Authored By
Juan Linietsky (reduz)
Mar 12 2011, 4:56 PM
Tags
  • BF Blender
Subscribers
Gaia Clary (gaiaclary)
Imran Syed (freakabcd)
Juan Linietsky (reduz)
Nathan Letwory (jesterking)

Description

Relates to: T31362

The symbol="" in <instance_material> is wrong, it must match the corresponding material="" in <triangles>,<polygons> or <poly_list>.
It is, instead, pointing to the material ID, so objects loaded have no material.

Event Timeline

Juan Linietsky (reduz) edited a custom field.Mar 12 2011, 4:56 PM
Imran Syed (freakabcd) added a comment.Mar 22 2011, 12:45 PM

Yo jester..

I made a couple of changes that seem to fix this issue. The bug reporter was 'goruka' on irc and I checked the collada spec and it is supposed to be as he says.

I am attaching the patch here. goruka reported that he does not build by himself so is unable to test export his own models/scenes for now. Maybe I'll get someone to make a build with the patch so he can test it (if necessary).

Imran Syed (freakabcd) added a comment.Mar 22 2011, 12:47 PM

Added attachment?

Imran Syed (freakabcd) attached 1 file(s): F15358: instance_material.patch.Mar 22 2011, 12:48 PM
Nathan Letwory (jesterking) added a comment.Mar 22 2011, 9:45 PM

Thanks! I'll be looking into the patch now.

Nathan Letwory (jesterking) added a comment.Mar 22 2011, 11:51 PM

Thanks for the report and patch. I've applied the patch and commited it in r35711.

Gaia Clary (gaiaclary) added a comment.May 7 2012, 8:39 PM

This fix breaks the Second Life Collada importer.

The reason is that different objects get different material symbols for the same material.
Although this seems to not violate the Collada specification, the Second LIfe importer
relies on the fact that identical materials use identical symbol names.

I have tested that the sequence number which was intriduced with commit 35711 is not needed.
I have added a patch for this a few days ago ( i just now found that this bug report causes the
problem). my patch is here:

http://projects.blender.org/tracker/index.php?func=detail&aid=31335&group_id=9&atid=127

I have already verified that materials keep intact after reimport of the exported dae files to blender.
Please can someone approve that my patch really creates collada conform output ?
Then my patch would fix the issues with Second Life as well.

thanks
Gaia

Gaia Clary (gaiaclary) added a comment.May 8 2012, 1:00 AM

I closed this again and opened a new bug report.
that is probably cleaner than to reopen an old report.

Gaia Clary (gaiaclary) changed the task status from Unknown Status to Archived.May 8 2012, 1:00 AM