Jump to content

BABYLON.Material and backFaceCulling. Color problem.


Visam
 Share

Recommended Posts

Hi

First two pictures show the model with backFaceCulling=true

1.jpg.5602eb18f7f835d5995841ea42ca3869.jpg

2.jpg.795575e9da0225dc14af18deba54d659.jpg

Next two pictures show the model with backFaceCulling=false

3.jpg.91e91f03ca4d696ee834379abc4efe69.jpg

4.jpg.af30468074a97faedb6df2440de13843.jpg

 

Why the colors are not correct when I set backFaceCulling=false? The vessel bottom  has to be red. How to fix the problem?

 

The original FBX file looks like this:

5.thumb.jpg.db3451a0caf41e1adef12fe5228bb8e1.jpg

Link to comment
Share on other sites

On 10/23/2017 at 7:50 PM, Deltakosh said:

Hello

it looks like your normals are pointing to the wrong direction.

how does the model look like in Blender?

 

You can also try to call mesh.createNormals() 

 

You can see the picture in blender.

bl.thumb.jpg.ab83be2097b1021564775c4fd95c53e6.jpg

Blender has correct colors.

I used the command line to convert fbx to babylon format file: FbxExporter.exe ship_Binary.fbx . /skipemptynodes.

 

I just try to try mesh.createNormals() , but there is a problem. I will try to fix it:

Cannot read property 'length' of null
    at Function.t.ComputeNormals (babylon.js:15)
    at r.i.createNormals (babylon.js:7)
    at e.callback (visam3d.window.js:1040)

Link to comment
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...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...