Sign in to follow this  
royibernthal

Set material to mesh parent

Recommended Posts

I have a mesh (container) that contains another mesh (sphere).

I'd like to set a material to the container mesh, in a way that it is applied to all the meshes it's parenting. (sphere in this case)

I created a PG showing that it doesn't work:

http://www.babylonjs-playground.com/#L69M2#1

 

Is such a thing not supposed to work?

My main reason for doing it is adding a material on top of a mesh that already has a material without overriding the previous material. (stacking materials)

e.g. adding a material that adds a 50% transparent black tint to a mesh that already has a material, without touching that mesh's material (sort of adding a material on top of it).

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.