Jump to content

Cannot read property 'normal' of null


jschatz1
 Share

Recommended Posts

First off BabylonJS is awesome!

I am having a problem with CSG currently. This error I get only seems to happen on Chrome on Windows. Edge on Windows and all Mac works fine. 

I have an app that is creating CSG on the fly. This is for a foam case building app that I am working on. For a gun shape that has two circles for finger notches as seen in the 2d image below. You can also see in the image below the points of the polygon I am rendering. We've added two circles to the render as well. When I run this as a `CSG subtract` in BabylonJS on Chrome on Windows for certain shapes, with an example below. I get the following error: 

Jacob Schatz
 

Uncaught TypeError: Cannot read property 'normal' of null
   at Plane.splitPolygon (eval at globalEval (app.js:1), <anonymous>:48668:68)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48826:28)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)
   at Node.build (eval at globalEval (app.js:1), <anonymous>:48836:27)

 

This error is a little bit beyond my understanding of Babylon. I don't think that I have any complex lines where the lines are over lapping one another and I also don't know how to catch this error. Would be great to be able to catch the error if we can't fix it. 

Again thanks for the great library. 

ss_ 2017-01-02 at 1.06.57 PM.png

ss_ 2017-01-02 at 1.08.20 PM.png

ss_ 2017-01-02 at 1.09.14 PM.png

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...