Added ImGuizmo.
This commit is contained in:
parent
c0f91f9d1c
commit
055402f78e
2
3rdparty/ocornut-imgui/imgui.cpp
vendored
2
3rdparty/ocornut-imgui/imgui.cpp
vendored
@ -80,7 +80,7 @@
|
||||
- read the FAQ below this section!
|
||||
- your code creates the UI, if your code doesn't run the UI is gone! == very dynamic UI, no construction/destructions steps, less data retention on your side, no state duplication, less sync, less bugs.
|
||||
- call and read ImGui::ShowTestWindow() for demo code demonstrating most features.
|
||||
- see examples/ folder for standalone sample applications. Prefer reading examples/opengl_example/ first as it is the simplest.
|
||||
- see examples/ folder for standalone sample applications. Prefer reading examples/opengl2_example/ first as it is the simplest.
|
||||
you may be able to grab and copy a ready made imgui_impl_*** file from the examples/.
|
||||
- customization: PushStyleColor()/PushStyleVar() or the style editor to tweak the look of the interface (e.g. if you want a more compact UI or a different color scheme).
|
||||
|
||||
|
1
3rdparty/ocornut-imgui/imgui_user.h
vendored
1
3rdparty/ocornut-imgui/imgui_user.h
vendored
@ -44,3 +44,4 @@ namespace ImGui
|
||||
|
||||
#include "widgets/file_list.h"
|
||||
#include "widgets/memory_editor.h"
|
||||
#include "widgets/gizmo.h"
|
||||
|
1
3rdparty/ocornut-imgui/imgui_user.inl
vendored
1
3rdparty/ocornut-imgui/imgui_user.inl
vendored
@ -74,3 +74,4 @@ namespace ImGui
|
||||
|
||||
#include "widgets/file_list.inl"
|
||||
#include "widgets/memory_editor.inl"
|
||||
#include "widgets/gizmo.inl"
|
||||
|
28
3rdparty/ocornut-imgui/widgets/gizmo.h
vendored
Normal file
28
3rdparty/ocornut-imgui/widgets/gizmo.h
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
namespace ImGuizmo
|
||||
{
|
||||
// call BeginFrame right after ImGui_XXXX_NewFrame();
|
||||
void BeginFrame();
|
||||
|
||||
// return true if mouse cursor is over any gizmo control (axis, plan or screen component)
|
||||
bool IsOver();
|
||||
|
||||
// return true if mouse IsOver or if the gizmo is in moving state
|
||||
bool IsUsing();
|
||||
|
||||
// enable/disable the gizmo. Stay in the state until next call to Enable.
|
||||
// gizmo is rendered with gray half transparent color when disabled
|
||||
void Enable(bool enable);
|
||||
|
||||
// call it when you want a gizmo
|
||||
// Needs view and projection matrices.
|
||||
// matrix parameter is the source matrix (where will be gizmo be drawn) and might be transformed by the function. Return deltaMatrix is optional
|
||||
// translation is applied in world space
|
||||
enum MODE
|
||||
{
|
||||
TRANSLATE,
|
||||
ROTATE,
|
||||
SCALE
|
||||
};
|
||||
void Mogwai(const float *view, const float *projection, MODE mode, float *matrix, float *deltaMatrix = 0);
|
||||
|
||||
} // namespace ImGuizmo
|
1163
3rdparty/ocornut-imgui/widgets/gizmo.inl
vendored
Normal file
1163
3rdparty/ocornut-imgui/widgets/gizmo.inl
vendored
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user