6
$\begingroup$

I'm importing .wrl data from matlab that I would like to display. When I'm using the Blender render, I can see the colors as I wanted ( the object already has a material when imported). But when I switch to cycles render (since it produces "nicer" results), my colors disappear. is there is away to use the cycles render with the imported colors? or how can I make the render look like the cycles render, when sing the blender.

$\endgroup$
3
  • $\begingroup$ maybe if you could upload a representative .wrl I could provide a nicer answer. $\endgroup$
    – zeffii
    Aug 12, 2013 at 9:12
  • $\begingroup$ I've tried the answer suggested by @zeffii but I could not get it to work. I'm attaching and example, which could be found here: s000.tinyupload.com/?file_id=03936112909451894934 $\endgroup$
    – Mercury
    Aug 23, 2013 at 16:26
  • $\begingroup$ i've updated my answer. $\endgroup$
    – zeffii
    Aug 23, 2013 at 16:40

1 Answer 1

3
$\begingroup$

The material provided by your importer may need a small adjustment to display the 'vertex_colors' layer when you switch over to Cycles Render engine.

Ideally you should be able to import the .wrl while already in Cycles Render engine and let the importer set up the material correctly -- but at present this is not the case.

A solution is to add an Attribute Node to the Cycles material Node Tree and write Col into the name field. This won't display properly in texture mode, you must set the viewport shading to Rendered, or currently you will only see black.

steps

  1. Import the .wrl as normal

  2. Create a node material for the object,

    2a. With the object selected, open a Node Editor enter image description here
    2b. set the Node Tree view type to Material enter image description here
    2c. Tick the box labelled Use Nodes

  3. Add an attribute node, and write 'Col' (without quotes) into it as in the picture.

  4. Hook up the output of the Attribute node, to the colour input of the Diffuse BSDF node.

enter image description here

$\endgroup$
2
  • $\begingroup$ Can you provide step by step instructions how to do it? $\endgroup$
    – Mercury
    Aug 23, 2013 at 16:44
  • $\begingroup$ sure, give me a few minutes $\endgroup$
    – zeffii
    Aug 23, 2013 at 16:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .