Skip to content

New to ImGUI. How can I switch rendering engines? #529

Open

Description

@wolfieboy09

Hi! I started C# recently to learn, and I wanted to make something with ImGui.

I'm using ClickableTransparentOverlay because that's the only thing working right now. I it works (mostly)
it just gets cut off at halfway on my screen.
Image

Anyways, I have the following code:

using ImGuiNET;
using ClickableTransparentOverlay;

namespace  ImGUISandbox;

class ImGUISandbox
{
    class Program : Overlay
    {
        protected override void Render()
        {
            ImGui.Begin("The Window");
            ImGui.Text("Some Text Here");
            ImGui.End();
        }
    }

    public static void Main(string[] args)
    {
        Program program = new Program();
        program.Start().Wait();
    }
}

I do have these packages installed:

Image

How can I change to using Veldrid instead? I want it to act as a normal window.
Using NET 9.0 as well
Any help is greatly appreciated

Activity

  1. QuinnCG commented on Sep 19, 2025

    @QuinnCG

    Hi,

    I'm actually new to this, too, and wasn't originally planning to reply, but I noticed the sample project had references to Veldrid. You may want to start there?

    https://github.com/ImGuiNET/ImGui.NET/blob/master/src/ImGui.NET.SampleProgram/ImGuiController.cs

    The comments suggest this is an implementation for Veldrid.

    Sorry, I couldn't be more help.

  2. ReifStanfield commented on Dec 13, 2025

    @ReifStanfield

    @wolfieboy09 Sorry to keep you waiting so long on this issue. If you want to continue to use ClickableTransparentOverlay, the solution is to pass your screen size when you inherit from Overlay.

    Using your example, and my screen size of 2560x1440 this looks like this:

    using ImGuiNET;
    using ClickableTransparentOverlay;
    
    namespace  ImGUISandbox;
    
    class ImGUISandbox
    {
        class Program : Overlay(2560,1440)
        {
            protected override void Render()
            {
                ImGui.Begin("The Window");
                ImGui.Text("Some Text Here");
                ImGui.End();
            }
        }
    
        public static void Main(string[] args)
        {
            Program program = new Program();
            program.Start().Wait();
        }
    }

    I have not delved into the internals of Overlay, but it seems to either incorrectly get the screen size by default, or it defaults to something like 1920x1080, which is a lower resolution than my current screen.

    Hope this helps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions