You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, when querying getActiveColorSpace, the code goes through the element's parents and calls hasColorSpace() on them.
An empty string set anywhere in the hierarchy is interpreted as having a color space and prevents further traversal.
This leads to the situation where getting the color space of an element with no color space and setting it back to the same element changes behavior.
There is also no removeColorSpace() method, so the only way to undo this is to call removeAttribute(COLOR_SPACE_ATTRIBUTE); directly.
Attaching a diff with a unit test that illustrates the issue.
This concerns MaterialXCore/Element.h:
Currently, when querying getActiveColorSpace, the code goes through the element's parents and calls hasColorSpace() on them.
An empty string set anywhere in the hierarchy is interpreted as having a color space and prevents further traversal.
This leads to the situation where getting the color space of an element with no color space and setting it back to the same element changes behavior.
There is also no removeColorSpace() method, so the only way to undo this is to call
removeAttribute(COLOR_SPACE_ATTRIBUTE);
directly.Attaching a diff with a unit test that illustrates the issue.
mx_element_test.patch
The text was updated successfully, but these errors were encountered: