martyj Posted August 15, 2016 Share Posted August 15, 2016 In the latest Leadwerks beta branch the Context::GetWidth and Context::GetHeight no longer return values that are expected. I get 0 as the width for my context and something like 190k as the height. The code: HWND desktop = GetDesktopWindow(); RECT size; GetWindowRect(desktop, &size); this->windowWidth = WFConfig::GetConfig()->GetIntValue("screen_width", size.right * 0.95); this->windowHeight = WFConfig::GetConfig()->GetIntValue("screen_height", size.bottom * 0.95); // TODO: Check default size this->windowMode = Window::Titlebar; this->window = Leadwerks::Window::Create("World Factions - Pre Alpha", 0, 0, this->windowWidth, this->windowHeight); this->context = Context::Create(window); int width = context->GetWidth(); int height = context->GetHeight(); I also noticed that when you call Context::GetWindow() after creating it, it returns NULL. this->context = Context::Create(window); Window* contextWindow = this->context->GetWindow(); if (this->window != contextWindow) { System::Print("**** hit the fan"); } 2 Link to comment Share on other sites More sharing options...
tjheldna Posted August 16, 2016 Share Posted August 16, 2016 Just did a post about this one with a debug project, It's the same issue. Link to comment Share on other sites More sharing options...
reepblue Posted August 16, 2016 Share Posted August 16, 2016 This might be why my project crashes. I thought it was a linker problem since I saw the project file changed. 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...
martyj Posted August 16, 2016 Author Share Posted August 16, 2016 Any update to when this would be fixed? 2 Link to comment Share on other sites More sharing options...
Josh Posted August 17, 2016 Share Posted August 17, 2016 I believe this is fixed. 1 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