ozRocker Posted April 30, 2017 Share Posted April 30, 2017 (edited) Does anyone know why this house is flickering around the windows? http://www.babylonjs-playground.com/#28YUR5#212 You can download the ZIP file of the house here if that helps http://preview.punkoffice.com/obj/building3.zip I've looked at it in Blender and can't see double faces or incorrect facing normals. Edited April 30, 2017 by ozRocker Fixed link Quote Link to comment Share on other sites More sharing options...
gryff Posted April 30, 2017 Share Posted April 30, 2017 @ozRocker: The link to the zip file does not get me a zip file - just a page promoting your scanning services cheers, gryff Quote Link to comment Share on other sites More sharing options...
ozRocker Posted April 30, 2017 Author Share Posted April 30, 2017 5 minutes ago, gryff said: @ozRocker: The link to the zip file does not get me a zip file - just a page promoting your scanning services cheers, gryff Whoops! I fixed the link. 404 gets directed to my homepage automatically http://preview.punkoffice.com/obj/building3.zip Quote Link to comment Share on other sites More sharing options...
gryff Posted April 30, 2017 Share Posted April 30, 2017 @ozRocker: I had no problem (almost) loading the .obj file into Blender and then exporting. Maybe it has something to do with the .obj importer you like to use ? If you can load it into Blender, why not export it from Blender? The one issue I had - model size. It is equivalent to 130 BJS basic 1 unit boxes high - I had to move my standard camera way out But no flashing! cheers, gryff Quote Link to comment Share on other sites More sharing options...
ozRocker Posted April 30, 2017 Author Share Posted April 30, 2017 5 minutes ago, gryff said: @ozRocker: I had no problem (almost) loading the .obj file into Blender and then exporting. Maybe it has something to do with the .obj importer you like to use ? If you can load it into Blender, why not export it from Blender? The one issue I had - model size. It is equivalent to 130 BJS basic 1 unit boxes high - I had to move my standard camera way out But no flashing! cheers, gryff Interesting. So in the playground, when you move the camera around the object you don't see any flashing around the windows, like Z competition affect? I need to import as OBJs because random users will be uploading OBJs. I don't want them to have to download Blender and plugins to convert to .babylon Quote Link to comment Share on other sites More sharing options...
Wingnut Posted April 30, 2017 Share Posted April 30, 2017 Sorry to butt-in, guys. http://www.babylonjs-playground.com/#28YUR5#214 I see z-fighting around the pea green 4-pack windows on the first floor. Almost like an extra set of windows is super-imposed atop. One set of green windows... a little z-jaggies. The other, a BUNCH. hmm. Just passing-on what I see. Be well, guys. Oh wait... I see some jittering on the top floor windows, too. Extra hmm! Quote Link to comment Share on other sites More sharing options...
gryff Posted April 30, 2017 Share Posted April 30, 2017 @ozRocker and @Wingnut: Here is the exort as a .babylon file from Blender: The Shop Now there are some differences between it and oz's original PG - the textures. Note the name of the shop "Carpet Barn" - it is a mirror image in the PG. Also looking at the model in Blender - there are a lot of edges marked as sharp. How does the BJS obj importer handle these? cheers, gryff Edit : the textures are huge - 4096px by 4096px - 4+MB each Wingnut 1 Quote Link to comment Share on other sites More sharing options...
ozRocker Posted May 1, 2017 Author Share Posted May 1, 2017 Is there something I can do in Blender to make it not flicker when imported as an OBJ? I know about the inverted Z axis with OBJs. If I switch to right-handed system using scene.useRightHandedSystem = true the problem is still there. Quote Link to comment Share on other sites More sharing options...
aWeirdo Posted May 1, 2017 Share Posted May 1, 2017 @ozRocker I'd say mostlikely, as wingnut was also talking about, it's two areas "overlapping" like there's two planes in exactly the same place; http://playground.babylonjs.com/#A6MPJ6 Wingnut 1 Quote Link to comment Share on other sites More sharing options...
ozRocker Posted May 1, 2017 Author Share Posted May 1, 2017 Yes, there's definitely z overlapping, but there are no overlapping polygons. However, @gryff put an idea into my head. Exporting to .babylon turns it into tris. I had a look at the .OBJ file in Blender and there are some n-gons in there. I used the "triangulate" modifier to remove the n-gons and now there's no z-fighting You can see it here http://www.babylonjs-playground.com/#28YUR5#215 What kind of lazy-ass puts up n-gon models on TurboSquid?? GameMonetize and Wingnut 2 Quote Link to comment Share on other sites More sharing options...
gryff Posted May 1, 2017 Share Posted May 1, 2017 @ozRocker; Glad you found a fix Funny, looking at the type of mesh it is - a simple building with doors and windows - I would never have modeled it with n-gons. But it maybe that the modeler used a "knife" tool to do certain things - can create n-gons fast As for getting 3d models of the internet for use with web3d - some are good, some are poor. And in my experience, price is no indicator of quality!. I still think the model scale and texture size are going to be issues. But good luck with your project. cheers, gryff Quote Link to comment Share on other sites More sharing options...
ozRocker Posted May 2, 2017 Author Share Posted May 2, 2017 ok, I increased compression on textures to drop the filesize down by half. I'm considering using GPU texture compression but in my experience that makes the filesize bigger. So there's a trade-off between faster downloads and saving RAM. Not so important on desktop computers but mobile devices have shared RAM and its easy to crash the browser if you have too much going on. Something I need to experiment with. You can see the house being used in my virtual world http://threedium.com When I upload an OBJ it automatically scales to a reasonable size. I use bounding box size to find absolute size then resize it before displaying. 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.