[SOLVED] Colour missing importing FBX

I want to import scientific visualizations produced with ParaView into my PlayCanvas project, but I’m having trouble reproducing the colours.

Here’s my workflow:

  1. from ParaView (v5.1.0, 64bit), export visualization using File → Export Scene … → to a X3D file
  2. using Blender (v2.78), import X3D file, then export to FBX 7.4 binary format
  3. import FBX file into PlayCanvas

The geometry is there, but all colours are gone.

See for example https://playcanvas.com/editor/scene/551256
which should look something like:

If I import the FBX file into Unity, the colours don’t show up either, but there I can make them appear by changing the shader type to “Sprites/Diffuse”.

Any help is greatly appreciated,
thanks,
– Rob

Do you have any textures for your model? I’m not sure if we import vertex colors from FBX files - I think we do but need to ask @will or @Mr_F.

If you have separate mesh instances for the different parts of your mesh that have colors you can assign a different material with the desired color on each mesh instance through the Editor.

Yes, Is that a problem?

ParaView colours the mesh through the vertices, so no; I don’t have textures. I would imagine that colouring by vertex is pretty common if you want the 3D models to be small. Are you suggesting that this is rare in FBX files?

I suppose that assigning a different material to each mesh only works if each mesh is of the same colour, right? That is not the case: the mesh has many different colours.

Waiting for a response from @Mr_F or @will on this who are more knowledgable on our FBX importer :slight_smile:

You do, I use Vertex Colours. You need to turn the option on in the material though.

Indeed, I’ve never used that yet! Here is the option on the material:

1 Like

Brilliant. Got it. Thanks all!