Dreikblack Posted November 25 Share Posted November 25 Bottom border line is pixel lower than should be #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() { auto default_font = LoadFont("Fonts\\arial.ttf"); ui = CreateInterface(menuWold, default_font, framebuffer->GetSize()); ui->SetRenderLayers(2); ui->root->SetColor(0.5f, 0.5f, 0.5f, 1.0f); uiCamera = CreateCamera(menuWold, PROJECTION_ORTHOGRAPHIC); 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; } 1 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.