-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathgui_imgui.h
37 lines (30 loc) · 986 Bytes
/
gui_imgui.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#pragma once
#include "imgui/imgui.h"
#include "implot/implot.h"
/*
item.def
ITEM_DEF(string, REMOTE_GUI_IP, "127.0.0.1")
ITEM_DEF(bool, ENABLE_REMOTE_GUI, false)
ITEM_DEF(bool, ENABLE_LOCAL_GUI, true)
setup():
createConfigImgui(getWindow(), false, false);
createRemoteImgui(REMOTE_GUI_IP.c_str());
getSignalUpdate().connect([&] {
updateRemoteImgui(ENABLE_REMOTE_GUI);
ImGui_ImplCinder_NewFrameGuard(getWindow());
vnm::drawMinicofigImgui(true);
});
getWindow()->getSignalDraw().connect([&] {
gl::clear();
ImGui_ImplCinder_PostDraw(ENABLE_REMOTE_GUI, ENABLE_LOCAL_GUI);
});
*/
bool createRemoteImgui(const char* address = "127.0.0.1", int port = 7003);
void updateRemoteImgui();
void ImGui_ImplCinder_NewFrameGuard();
void ImGui_ImplCinder_PostDraw();
bool createImgui();
bool updateImgui();
void ImGui_SDL_BeginDraw();
void ImGui_SDL_EndDraw();
void destroyImgui();