Josh Posted October 4, 2023 Share Posted October 4, 2023 I think the overdraw problem was caused by my use of WS_EX_TRANSPARENT in every created window. I still have a problem with the 3D viewport rendering black, but I think this fixes the background overdraw problem. 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...
klepto2 Posted October 4, 2023 Share Posted October 4, 2023 @Josh: My issue was caused by a windows update which corrupted the nvidia driver. A reinstall of the nvidia drivers fixed it. The rendering looks much smoother now and nearly no artifacts are there. Only when resizing the viewport, then the viewports are not updated, otherwise a great enhancement. Quote Windows 10 Pro 64-Bit-Version NVIDIA Geforce 1080 TI Link to comment Share on other sites More sharing options...
Josh Posted October 4, 2023 Share Posted October 4, 2023 The black screen is being caused by one of the post-processing effects, so probably some syncing thing when a new texture buffer is created. It's definitely a Vulkan problem. 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...
Josh Posted October 4, 2023 Share Posted October 4, 2023 I have temporarily disabled post-processing effects in the editor. Please confirm that this solves all your rendering problems. 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...
reepblue Posted October 4, 2023 Author Share Posted October 4, 2023 4 hours ago, Josh said: I have temporarily disabled post-processing effects in the editor. Please confirm that this solves all your rendering problems. Much better. I can now make things without being easily interrupted. This also fixes the asset browser too. Quote Cyclone - Ultra Game System - Component Preprocessor - Tex2TGA - Darkness Awaits Template (Leadwerks) If you like my work, consider supporting me on Patreon! Link to comment Share on other sites More sharing options...
Josh Posted October 4, 2023 Share Posted October 4, 2023 This simple example shows the problem. I have to hit the space key three times after each window resize before the screen renders again. Without the post effect it works fine: #include "UltraEngine.h" using namespace UltraEngine; int main(int argc, const char* argv[]) { EngineSettings settings; settings.asyncrender = false; Initialize(settings); //Get the displays auto displays = GetDisplays(); //Create window auto window = CreateWindow("Ultra Engine", 0, 0, 1280, 720, displays[0], WINDOW_RESIZABLE | WINDOW_CENTER | WINDOW_TITLEBAR); //Create world auto world = CreateWorld(); //Create framebuffer auto framebuffer = CreateFramebuffer(window); //Create a camera auto camera = CreateCamera(world, PROJECTION_ORTHOGRAPHIC); camera->SetClearColor(0,0,1,1); camera->SetDepthPrepass(false); auto fx = LoadPostEffect("Shaders/FXAA.fx"); camera->AddPostEffect(fx); while (window->Closed() == false and window->KeyDown(KEY_ESCAPE) == false) { auto e = WaitEvent(); if (e.id == EVENT_KEYDOWN and e.data == KEY_SPACE) { world->Update(); world->Render(framebuffer); } } return 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...
Solution Josh Posted October 5, 2023 Solution Share Posted October 5, 2023 I found I can avoid this bug by drawing the viewport three times when a change of size is detected. The bug still exists in the engine, and should be fixed in the future, but it only happens in a non-realtime app and is a very specific problem. For now I am just going to avoid triggering it in the editor and that should be sufficient for our current needs. Continued here: 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...
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.