All Activity
- Past hour
-
Josh started following Bottom border line of widgets is one pixel offseted , Setting brush texels per meter does not seem to work properly , WString Split bugs and 7 others
-
Setting brush texels per meter does not seem to work properly
Josh replied to Lupin's topic in Bug Reports
You are correct. This was recently moved from general options into a per-project setting, but some code was still looking for the setting in the old location. -
Working as it should..
-
I am a little bit wary of modifying the way this works, but we can try it.
- Today
-
#2 This is fixed in the build that will go up later today Closing this for now. Please upload the scene file if you would like me to investigate. The brush might be scaled, which could cause the effect you are seeing, but I cannot tell without seeing the scene file.
-
igotlonglegs joined the community
-
Is this still happening? Is there any example I can run that will produce the error?
-
This will be fixed in the build that goes up later today. Updated code. #include "UltraEngine.h" using namespace UltraEngine; int main(int argc, const char* argv[]) { //Get the displays auto displays = GetDisplays(); //Create window auto window = CreateWindow("Ultra Engine", 0, 0, 1280, 720, displays[0]); //Create framebuffer auto framebuffer = CreateFramebuffer(window); //Create world auto world = CreateWorld(); //Create main camera auto camera = CreateCamera(world); camera->SetPosition(0, 0, -3); //Create a model auto box = CreateBox(world); //Create a light auto light = CreateBoxLight(world); light->SetRange(-5, 5); light->SetRotation(34, 45, 0); //Load a font auto font = LoadFont("Fonts/arial.ttf"); //Create user interface with a semi-transparent background auto ui = CreateInterface(camera, font, framebuffer->size); ui->background->SetColor(0, 0, 0, 0.5); //Create widget iVec2 sz = ui->background->ClientSize(); auto button = CreateButton("Button", sz.x / 2 - 75, sz.y / 2 - 15, 150, 30, ui->background); while (true) { box->Turn(0, 1, 0); while (PeekEvent()) { const Event ev = WaitEvent(); switch (ev.id) { case EVENT_WINDOWCLOSE: if (ev.source == window) { return 0; } break; default: ui->ProcessEvent(ev); break; } } if (window->KeyHit(KEY_F2)) { framebuffer->Capture(); } auto captures = framebuffer->GetCaptures(); for (auto c : captures) { auto path = GetPath(PATH_DESKTOP) + "/screenshot.jpg"; c->Save(path); RunFile(path); } world->Update(); world->Render(framebuffer); } return 0; }
-
I believe this is fixed, in the build that will go up later today... #include "UltraEngine.h" using namespace UltraEngine; #define GUIMODE 1 int main(int argc, const char* argv[]) { //Get the displays auto displays = GetDisplays(); //Create a window auto window = CreateWindow("Ultra Engine", 0, 0, 800, 600, displays[0], WINDOW_TITLEBAR); #if GUIMODE == 1 auto framebuffer = CreateFramebuffer(window); auto world = CreateWorld(); auto font = LoadFont("Fonts/segoeui.ttf"); auto camera = CreateCamera(world); auto ui = CreateInterface(camera, font, framebuffer->size); #else auto ui = CreateInterface(window); #endif //Create widget auto sz = ui->root->ClientSize(); auto widget = CreateTextArea(10, 10, sz.x - 20, sz.y - 20, ui->root, TEXTAREA_WORDWRAP); for (int n = 0; n < 3; ++n) { if (not widget->text.empty()) widget->AddText("\n\n"); widget->AddText("Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."); } widget->SetFontScale(4); while (not window->KeyHit(KEY_ESCAPE)) { #if GUIMODE == 1 while (PeekEvent()) { const auto event = WaitEvent(); if (event.id == EVENT_WINDOWCLOSE) return 0; ui->ProcessEvent(event); } world->Update(); world->Render(framebuffer); #else const auto event = WaitEvent(); if (event.id == EVENT_WINDOWCLOSE) return 0; #endif } return 0; }
-
2D revisions are in. If there are any continuing problems please post some code I can run.
-
New component dialog's group combobox showing class files
Josh replied to Dreikblack's topic in Bug Reports
Fixed -
Fixed in the next build that goes up on the dev/beta branch.
-
Does your map have a camera or player in it? Can you please upload the map file so we can try it?
-
Set and GetDecalLayers are added in Lua now.
- 1 reply
-
- 1
-
-
One final test in 0.9.9 shows this working. Make sure you call collectgarbage() in Lua after setting the variable to nil. #include "UltraEngine.h" using namespace UltraEngine; int main(int argc, const char* argv[]) { //Get the displays auto displays = GetDisplays(); //Create window auto window = CreateWindow("Ultra Engine", 0, 0, 1280, 720, displays[0]); //Create framebuffer auto framebuffer = CreateFramebuffer(window); //Create world auto world = CreateWorld(); //Create main camera auto camera = CreateCamera(world); camera->SetPosition(0, 0, -3); //Create a model auto box = CreateBox(world); //Create a light auto light = CreateBoxLight(world); light->SetRange(-5, 5); light->SetRotation(34, 45, 0); //Load a font auto font = LoadFont("Fonts/arial.ttf"); //Create user interface with a semi-transparent background auto ui = CreateInterface(camera, font, framebuffer->size); ui->background->SetColor(0, 0, 0, 0.5); //Create widget iVec2 sz = ui->background->ClientSize(); auto button = CreateButton("Button", sz.x / 2 - 75, sz.y / 2 - 15, 150, 30, ui->background); while (true) { box->Turn(0, 1, 0); while (PeekEvent()) { const Event ev = WaitEvent(); switch (ev.id) { case EVENT_WINDOWCLOSE: if (ev.source == window) { return 0; } break; default: if (ui) ui->ProcessEvent(ev); break; } } if (window->KeyHit(KEY_SPACE)) ui = nullptr; world->Update(); world->Render(framebuffer); } return 0; }
-
Bottom border line of widgets is one pixel offseted
Josh replied to Dreikblack's topic in Bug Reports
Seems fine now? #include "UltraEngine.h" using namespace UltraEngine; shared_ptr<Window> window; shared_ptr<Framebuffer> framebuffer; shared_ptr<World> menuWold; shared_ptr<Interface> ui; shared_ptr<Camera> uiCamera; void initGui() { uiCamera = CreateCamera(menuWold, PROJECTION_ORTHOGRAPHIC); auto default_font = LoadFont("Fonts\\arial.ttf"); ui = CreateInterface(uiCamera, default_font, framebuffer->GetSize()); ui->SetRenderLayers(2); ui->root->SetColor(0.5f, 0.5f, 0.5f, 1.0f); uiCamera->SetPosition((float)framebuffer->GetSize().x * 0.5f, (float)framebuffer->GetSize().y * 0.5f, 0); uiCamera->SetRenderLayers(2); uiCamera->SetClearMode(CLEAR_DEPTH); } int main(int argc, const char* argv[]) { auto displays = GetDisplays(); window = CreateWindow("Ultra Engine", 0, 0, 100, 100, displays[0], WINDOW_DEFAULT); menuWold = CreateWorld(); framebuffer = CreateFramebuffer(window); initGui(); auto btn = CreateButton("", 10, 10, 32, 32, ui->root); while (window->Closed() == false and window->KeyDown(KEY_ESCAPE) == false) { menuWold->Update(); menuWold->Render(framebuffer); } return 0; } -
This was fixed by adding some checks for NAN in the bloom shader.
-
Report is being closed since there is no file I can test to produce this behavior and it is probably fixed.
-
Text added in real time in widget makes text go out of widget borders
Josh replied to Dreikblack's topic in Bug Reports
Works correctly in the latest builds #include "UltraEngine.h" using namespace UltraEngine; int main(int argc, const char* argv[]) { //Get the displays auto displays = GetDisplays(); //Create window auto window = CreateWindow("Ultra Engine", 0, 0, 1280, 720, displays[0]); //Create framebuffer auto framebuffer = CreateFramebuffer(window); //Create world auto world = CreateWorld(); //Create main camera auto camera = CreateCamera(world); camera->SetPosition(0, 0, -3); //Load a font auto font = LoadFont("Fonts/arial.ttf"); //Create user interface with a semi-transparent background auto ui = CreateInterface(camera, font, framebuffer->size); ui->background->SetColor(0, 0, 0, 0.5); //Create widget iVec2 sz = ui->background->ClientSize(); auto button = CreateButton("Button", 100, 200, 150, 30, ui->background); auto button2 = CreateButton("Button2", 500, 200, 150, 30, ui->background); for (int i = 0; i < 5; i++) { button2->AddText("\ntest"); } //Create camera auto orthocamera = CreateCamera(world, PROJECTION_ORTHOGRAPHIC); orthocamera->SetClearMode(CLEAR_DEPTH); orthocamera->SetPosition(float(framebuffer->size.x) * 0.5f, float(framebuffer->size.y) * 0.5f, 0); //UI will only appear in orthographic camera orthocamera->SetRenderLayers(2); ui->SetRenderLayers(2); while (true) { if (window->KeyHit(KEY_SPACE)) { button->AddText("\ntest"); } while (PeekEvent()) { const Event ev = WaitEvent(); switch (ev.id) { case EVENT_WINDOWCLOSE: if (ev.source == window) { return 0; } break; default: ui->ProcessEvent(ev); break; } } world->Update(); world->Render(framebuffer); } return 0; } -
This is fixed with the new 2D drawing system.
-
Fixed in next build
-
Mipafiwi joined the community
-
material:SetBackFaceCullMode(boolean)
- 1 reply
-
- 1
-
-
0.9.9 Added Camera::EnablePostEffect(int index) and Camera::DisablePostEffect(). The return type of CreateMenu will now be cast to a Widget, making it more consistent with the rest of the API. If you need to cast it to a menu, you can add ->As<Menu>() at the end of the CreateMenu() command. Lua binding of Camera::AddPostEffect will now return 1 for the first effect added instead of zero. Variious bug fixes.