You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// And finally unregister the add-on from ReShade (this will automatically clean up any events registered by this add-on as well).
37
36
reshade::unregister_addon(hinstDLL);
38
37
break;
39
38
}
@@ -46,12 +45,16 @@ For more complex examples, see also the built-in add-ons in [source/addon](../so
46
45
## Overlays
47
46
48
47
It is also supported to add an overlay, which can e.g. be used to display debug information or interact with the user in-application.
49
-
Overlays are created with the use of [Dear ImGui](https://github.com/ocornut/imgui/). Including the [`reshade.hpp`](reshade.hpp) header after `imgui.h` will automatically overwrite all Dear ImGui functions to use the instance created and managed by ReShade. This means all you have to do is include these two headers and use Dear ImGui as usual (without actually having to build its source code files, only the header files are needed):
48
+
Overlays are created with the use of [Dear ImGui](https://github.com/ocornut/imgui/). Including the [`reshade.hpp`](reshade.hpp) header after `imgui.h` will automatically overwrite all Dear ImGui functions to use the instance created and managed by ReShade. This means all you have to do is include these two headers, define the function table variable in one of your source code file and use Dear ImGui as usual (without actually having to build its source code files, only the header files are needed):
50
49
51
50
```cpp
52
51
#include <imgui.h>
53
52
#include <reshade.hpp>
54
53
54
+
// Define this variable in exactly one of your source code files.
55
+
// The function table is automatically populated in the call to 'reshade::register_addon' and overwrites all Dear ImGui functions.
/// Registers a callback for the specified event (via template) with ReShade.
92
116
/// <para>The callback function is then called whenever the application performs a task associated with this event (see also the <see cref="addon_event"/> enumeration).</para>
93
117
/// </summary>
118
+
/// <param name="callback">Pointer to the callback function.</param>
0 commit comments