MeshroomMaya
MeshroomMaya copied to clipboard
Add color on PC
Color is not correctly set in ABC. Should be V3dArray named rgbPP
Ok, so we need to change the attribute type but we will keep the name as "color" sounds more standard than "rgbPP" and nuke recognize it.
So we need to copy the values from color to rgbPP during the load in mayaMVG.
They use OC3fArrayProperty in the PointsTest: https://github.com/alembic/alembic/blob/master/lib/Alembic/AbcGeom/Tests/PointsTest.cpp#L254 https://github.com/alembic/alembic/blob/c8b92e656a5fcd4373c7a613b8f4e1069446f492/lib/Alembic/AbcGeom/Tests/SubDTest.cpp#L124
As we do in openMVG: https://github.com/poparteu/openMVG/blob/popart_develop/src/openMVG/sfm/AlembicExporter.cpp#L62
Or maybe "rgb": https://github.com/alembic/alembic/blob/c8b92e656a5fcd4373c7a613b8f4e1069446f492/maya/AbcImport/NodeIteratorVisitorHelper.cpp#L577
Alembic importer in Maya set all colors to (0, 0, 0) (with attribute of type V3dArray named rgbPP, rgb or color)
Per particle attributes are reinitialized on alembic import in Maya.