# NetImgui / extension-netimgui

**URL:** <https://forum.defold.com/t/netimgui-extension-netimgui/74781>\
**Category:** The Defoldmine\
**Created:** [November 2, 2023, 11:17am UTC](https://forum.defold.com/t/netimgui-extension-netimgui/74781 "2023-11-02T11:17:41Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![AarrrBee](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/aarrrbee/32/24978_2.png) [@AarrrBee](https://forum.defold.com/u/AarrrBee)\
**Post date:** [November 2, 2023, 11:17am UTC](https://forum.defold.com/t/netimgui-extension-netimgui/74781/1 "2023-11-02T11:17:41Z")

</div>

We’ve been using [extension-imgui](https://github.com/britzl/extension-imgui) / Dear ImGUI for some time, but interacting with debug menus on a phone is fiddly - they obscure the game, and it’s easy to click the wrong thing.

I recently became aware of [NetImgui](https://github.com/sammyfreg/netImgui) which magically intercepts Dear ImGUI function calls and allows the content to be displayed and controlled from a separate window or on a different machine ( this is called the Server app). Any interactions you make still take effect within your game.

This is now available through [extension-netimgui](https://github.com/DreamRealityInteractive/extension-netimgui)

Setup is pretty straightforward. Use extension-imgui as normal, but with a couple of calls, you can either connect to a Server app at a specified IP, or allow incoming connections, and the content will move to the Server app.

The Server app needs to be built from source - see instructions in the Netimgui repository.

To illustrate: this is the extension-imgui example:

 ![image](https://forum-defold-uploads.b-cdn.net/original/3X/3/e/3e92dbd830ad69477fd1f74e068e952bce65c997.jpeg)

and this is the NetImgui server window after a network connection is established:

 ![image](https://forum-defold-uploads.b-cdn.net/original/3X/a/f/af6c47223f51c100baad7fd759b140bbf6aef751.png)

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [November 2, 2023, 1:13pm UTC](https://forum.defold.com/t/netimgui-extension-netimgui/74781/2 "2023-11-02T13:13:35Z")

</div>

This is really powerful stuff! I think there’s a lot of potential in building debug and dev tools using the imgui extension, and with netimgui it also becomes useful on mobile!

---

<div class="post-metadata">

**Author:** ![AarrrBee](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/aarrrbee/32/24978_2.png) [@AarrrBee](https://forum.defold.com/u/AarrrBee)\
**Post date:** [November 2, 2023, 2:31pm UTC](https://forum.defold.com/t/netimgui-extension-netimgui/74781/3 "2023-11-02T14:31:10Z")

</div>

One example I’ve been working on is a tool to inspect & modify GUI hierarchies. You pass it a node id, and it iterates over the hierarchy using gui.get\_tree(). You can change the position, size and text of any node. I’ll share the code when I’ve developed it further (I need to improve my imgui layout skills!)

 ![image](https://forum-defold-uploads.b-cdn.net/original/3X/4/a/4ac67dd55b5993421a24030a476bdc3f739364ab.jpeg)  
 ![image](https://forum-defold-uploads.b-cdn.net/original/3X/d/7/d756760294ed18d64e497079b6abad6dbf44eea5.png)

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [November 2, 2023, 2:53pm UTC](https://forum.defold.com/t/netimgui-extension-netimgui/74781/4 "2023-11-02T14:53:20Z")

</div>

> [@AarrrBee](#):
>
> One example I’ve been working on is a tool to inspect & modify GUI hierarchies

That’s interesting! And will it generate an updated .gui file or how does it work?

---

<div class="post-metadata">

**Author:** ![AarrrBee](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/aarrrbee/32/24978_2.png) [@AarrrBee](https://forum.defold.com/u/AarrrBee)\
**Post date:** [November 2, 2023, 3:02pm UTC](https://forum.defold.com/t/netimgui-extension-netimgui/74781/5 "2023-11-02T15:02:10Z")

</div>

No, I wish it could do that! It’s just a toy really right now, but a lot of our GUIs look very different at runtime compared to in the editor, because we instantiate a lot of items programatically / from templates, so it’s useful to be able to see the true hierarchy.

---

<div class="post-metadata">

**Author:** ![AarrrBee](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/aarrrbee/32/24978_2.png) [@AarrrBee](https://forum.defold.com/u/AarrrBee)\
**Post date:** [November 15, 2023, 4:53pm UTC](https://forum.defold.com/t/netimgui-extension-netimgui/74781/6 "2023-11-15T16:53:38Z")

</div>

When I first posted this, the [Netimgui](https://github.com/sammyfreg/netImgui) server app only came with instructions for building on Windows, but yesterday I opened a PR for generating an Xcode project, which has now been accepted, so take a look if you’re a Mac user.
