Kesshi Posted April 12, 2017 Share Posted April 12, 2017 It seems that IE doesn't reset the polygon offset correctly. I created a playground to demonstrate the issue:http://www.babylonjs-playground.com/#25N9HL The red plane in the PG has a zOffset. For some reason the offset is also applied to the knot under IE (see attached images). I was able to workaround this issue by modifying this code:https://github.com/BabylonJS/Babylon.js/blob/master/src/States/babylon.depthCullingState.ts#L173 I added "gl.polygonOffset(0, 0);" before "gl.disable(gl.POLYGON_OFFSET_FILL);" like this: // zOffset if (this._isZOffsetDirty) { if (this.zOffset) { gl.enable(gl.POLYGON_OFFSET_FILL); gl.polygonOffset(this.zOffset, 0); } else { gl.polygonOffset(0, 0); gl.disable(gl.POLYGON_OFFSET_FILL); } this._isZOffsetDirty = false; } How should we fix that issue? Is there a better place to add this workaround? I'm not sure if its a general IE bug. I tested it only on two systems. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted April 12, 2017 Share Posted April 12, 2017 Does it work on chrome/ff and edge? Quote Link to comment Share on other sites More sharing options...
Kesshi Posted April 13, 2017 Author Share Posted April 13, 2017 14 hours ago, Deltakosh said: Does it work on chrome/ff and edge? I tested it in Chrome, Firefox, Edge and IOS. There it works with and without my added line. Only in IE my added line is necessary. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted April 13, 2017 Share Posted April 13, 2017 I'm not sure we want to add hack just for IE in the mainstream Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.