ID 430563 - Imported MNG and MMAs silently change Colorspace on Color Attributes.

Follow

Problem summary
Imported MNG and MMAs silently change Colorspace on Color Attributes.

 

Customer reported version
mari.4.6v3

 

Customer reported platform
windows10

 

Steps to reproduce

1) Open Mari, select any project and download the attached node.
2) Open the Python Console , then paste the following snippet and select evaluate: 


mari.gl_render.registerCustomNodeFromXMLFile("ColorNode","path/to/downloaded/Jens_color.xml")

3) Create any shader type material by pressing TAB in the Node Graph and typing Material.
4) Go inside of the Material node by CTRL+double-clicking the material.
5) Press TAB and start typing ColorNode and create the node 
6) Double click it to open the Node Properties 
7) Press the tri-color button to make it black/white to represent that the node is scalar: 


8) Go in the Main Node Graph and export the material via it's Node Properties.
9) Close Mari all together 
10) Open the Jens_color.xml file in a Text Editor and change: 


  <Inputs><Input Name="Alpha" PrettyName="Mask"></Input></Inputs>

to be: 


  <Inputs><Input Name="Alpha" PrettyName="Alpha"></Input></Inputs>

and save the file.
11) Open Mari and a brand new project.
12) Re-register the node by opening the Python Console and pasting the following once more: 


mari.gl_render.registerCustomNodeFromXMLFile("ColorNode","path/to/downloaded/Jens_color.xml")

13) Re-import the exported material in step 8 by right clicking in the NG>File>Import Material 
14) Go inside of the Material and open the Node Properties of the color node. 

 

Expected behavior
The nodes should remain with the same attributes.

 

Actual behavior
The port has been changed from Mask to Alpha but the node has changed to a color node and not scalar (Notice the tri-color button is color and not black/white even though we have exported the material with the node set to scalar and not color)

 

Workaround
There is no available workaround at this time.

 

Reproduced by Support in

Mari 4.6v1 - Windows 10

Mari 4.5v2 - Windows 10

Mari 4.5v1 - Windows 10

 

Earliest version tested
Mari 4.5v1 - This feature did not exist before this version

    We're sorry to hear that

    Please tell us why