Marcousik Posted July 30, 2022 Share Posted July 30, 2022 I want to build a road with the decals, but then the road is trembling each time the camera moves: I'm on terrain 4096*4096 Any idea why this occurs ? 1 Quote Link to comment Share on other sites More sharing options...
Marcousik Posted July 30, 2022 Author Share Posted July 30, 2022 Update: Tested on 512 map, no bug so occurs only on 4096 terrain, but can't tell why Update 2: It seems it is trembling only at the begin and at the end of a camera move. While the camera is moving it is ok. Quote Link to comment Share on other sites More sharing options...
Josh Posted July 30, 2022 Share Posted July 30, 2022 How far away are you from the center point? (0,0,0) Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Marcousik Posted July 30, 2022 Author Share Posted July 30, 2022 Quote Link to comment Share on other sites More sharing options...
Josh Posted July 30, 2022 Share Posted July 30, 2022 If it doesn't happen with decals that are close to the center of the scene, then I think this is just 32-bit floating point precision in action. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Marcousik Posted July 30, 2022 Author Share Posted July 30, 2022 3 minutes ago, Josh said: I think this is just 32-bit floating point precision in action. Right it is not tembling in the middle of the map, ok. But do you know how to fix this? Or that would mean for my game design no roads after range (x,y) ? Quote Link to comment Share on other sites More sharing options...
Josh Posted July 30, 2022 Share Posted July 30, 2022 Use 64-bit floats: www.ultraengine.com 1 1 Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Marcousik Posted July 30, 2022 Author Share Posted July 30, 2022 One thing I don't understand if why does the trembing not appear in the preview editor? Quote Link to comment Share on other sites More sharing options...
Josh Posted July 30, 2022 Share Posted July 30, 2022 Try turning real-time render on in the editor. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Marcousik Posted July 30, 2022 Author Share Posted July 30, 2022 It does not appear, I tried, no problem, only ingame And the bug appears even on 1024 map at the edge. Quote Link to comment Share on other sites More sharing options...
Marcousik Posted July 30, 2022 Author Share Posted July 30, 2022 Could it not be a shader bug Quote Link to comment Share on other sites More sharing options...
Yue Posted July 30, 2022 Share Posted July 30, 2022 5 hours ago, Marcousik said: One thing I don't understand if why does the trembing not appear in the preview editor? I think it has to do with the Occlusion Culling system that is disabled in the editor. Quote Link to comment Share on other sites More sharing options...
Marcousik Posted July 30, 2022 Author Share Posted July 30, 2022 Ok maybe? But is that not strange that everything goes ok at the edges of a map... except decals? I mean shadows, models, cng, emitters all work fine ,but decals are trembling. I m bit disappointed, it would have built good roads effects. Quote Link to comment Share on other sites More sharing options...
Genebris Posted July 30, 2022 Share Posted July 30, 2022 Have you tried lowering camera far clip / increasing near clip? Just in case this is due to depth buffer precision somehow. 1 Quote Link to comment Share on other sites More sharing options...
Marcousik Posted July 31, 2022 Author Share Posted July 31, 2022 6 hours ago, Genebris said: Have you tried lowering camera far clip / increasing near clip? Just in case this is due to depth buffer precision somehow. I don't know about that. Could you give me details, where/how? Function? 1 Quote Link to comment Share on other sites More sharing options...
Solution Genebris Posted July 31, 2022 Solution Share Posted July 31, 2022 https://www.leadwerks.com/learn?page=API-Reference_Object_Entity_Camera_SetRange No idea what default numbers are, so use GetRange first https://www.leadwerks.com/learn?page=API-Reference_Object_Entity_Camera_GetRange 1 1 Quote Link to comment Share on other sites More sharing options...
Josh Posted July 31, 2022 Share Posted July 31, 2022 Defaults are 0.1-1000 1 Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Marcousik Posted July 31, 2022 Author Share Posted July 31, 2022 @Genebris Dude 1000 Thx that made it, set the range to 0.5-600 fixed the tremblng I will credits your name for saving this idea if my project ever get finished! 1 1 Quote Link to comment Share on other sites More sharing options...
Yue Posted July 31, 2022 Share Posted July 31, 2022 NIce!! 1 Quote Link to comment Share on other sites More sharing options...
Marcousik Posted July 31, 2022 Author Share Posted July 31, 2022 How performant are decals? Did anyone have an idea how much of them a map will support (approximativly) I hope decal isn't that heavy because it has no shadow, no physics, no shape. Quote Link to comment Share on other sites More sharing options...
Yue Posted July 31, 2022 Share Posted July 31, 2022 This will largely depend on the hardware power of the computer, so it is then up to me to implement a menu of drawing distance options for these objects, and for the end user to change these parameters to optimize performance. Decals have draw distance parameters Quote Link to comment Share on other sites More sharing options...
Marcousik Posted July 31, 2022 Author Share Posted July 31, 2022 Ok thx Quote Link to comment Share on other sites More sharing options...
Yue Posted July 31, 2022 Share Posted July 31, 2022 Something I was thinking is that decal textures trigger mipmaps that far away degrades the quality of the texture, all this helps the performance of the decal that when far away does not show in high quality. Quote Link to comment Share on other sites More sharing options...
Marcousik Posted August 1, 2022 Author Share Posted August 1, 2022 Yeah everything depending on the PC configuration, but overall I did a quick performance test and the results are incredible good: That means more than 1600 decals be rendered at max view setting, tracing 6 roads over a 4096 map by 55-60 FPS Video Card GTX 1660 - 6Gb 1 1 Quote Link to comment Share on other sites More sharing options...
Genebris Posted August 1, 2022 Share Posted August 1, 2022 Did you have vsync enabled? Also it's possible that amount of them doesn't matter as much as coverage of pixels on the screen. Josh knows if it's true. 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.