Skip to content

Commit

Permalink
fixup! doc: Add imgui to changelog and index
Browse files Browse the repository at this point in the history
Signed-off-by: Squareys <squareys@googlemail.com>
  • Loading branch information
Squareys committed Dec 8, 2018
1 parent 5fef2ae commit 309e84c
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 10 deletions.
6 changes: 3 additions & 3 deletions doc/imgui.dox
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ namespace Magnum {
The ImGui demo and two example windows which demonstrate rendering of ImGui UI
using the @ref ImGuiIntegration library,

@image html imgui.png
@image html imgui.png width=400px

@m_div{m-button m-primary} <a href="https://magnum.graphics/showcase/imgui/">@m_div{m-big} Live web demo @m_enddiv @m_div{m-small} uses WebAssembly & WebGL @m_enddiv </a> @m_enddiv

Expand All @@ -47,11 +47,11 @@ using the @ref ImGuiIntegration library,

This example originated from community projects by

- ["ShaddyAQN"](https://github.com/ShaddyAQN),
- [\@ShaddyAQN](https://github.com/ShaddyAQN),
- [Tomáš Skřivan](https://github.com/lecopivo),
- [Natesh Narain](https://github.com/nnarain),
- [Guillaume Jacquemin](https://github.com/williamjcm) and
- ["Denesik"](https://github.com/denesik)
- [\@denesik](https://github.com/denesik),

which where integrated by [Jonathan Hale](https://github.com/Squareys).

Expand Down
2 changes: 1 addition & 1 deletion package/ci/appveyor-desktop-gles.bat
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ cmake .. ^
-DWITH_BOX2D_EXAMPLE=OFF ^
-DWITH_BULLET_EXAMPLE=ON ^
-DWITH_CUBEMAP_EXAMPLE=OFF ^
-DWITH_IMGUI_EXAMPLE=OFF ^
-DWITH_IMGUI_EXAMPLE=ON ^
-DWITH_MOTIONBLUR_EXAMPLE=OFF ^
-DWITH_MOUSEINTERACTION_EXAMPLE=OFF ^
-DWITH_OVR_EXAMPLE=OFF ^
Expand Down
1 change: 1 addition & 0 deletions package/ci/travis-desktop-gles.sh
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ cmake .. \
-DWITH_BOX2D_EXAMPLE=ON \
-DWITH_BULLET_EXAMPLE=ON \
-DWITH_CUBEMAP_EXAMPLE=OFF \
-DWITH_IMGUI_EXAMPLE=ON \
-DWITH_MOTIONBLUR_EXAMPLE=OFF \
-DWITH_MOUSEINTERACTION_EXAMPLE=OFF \
-DWITH_OVR_EXAMPLE=OFF \
Expand Down
1 change: 1 addition & 0 deletions package/ci/travis-emscripten.sh
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ cmake .. \
-DWITH_BOX2D_EXAMPLE=OFF \
-DWITH_BULLET_EXAMPLE=OFF \
-DWITH_CUBEMAP_EXAMPLE=OFF \
-DWITH_IMGUI_EXAMPLE=ON \
-DWITH_MOTIONBLUR_EXAMPLE=OFF \
-DWITH_MOUSEINTERACTION_EXAMPLE=OFF \
-DWITH_OVR_EXAMPLE=OFF \
Expand Down
1 change: 1 addition & 0 deletions package/ci/travis-ios-simulator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ cmake .. \
-DWITH_BOX2D_EXAMPLE=OFF \
-DWITH_BULLET_EXAMPLE=OFF \
-DWITH_CUBEMAP_EXAMPLE=OFF \
-DWITH_IMGUI_EXAMPLE=ON \
-DWITH_MOTIONBLUR_EXAMPLE=OFF \
-DWITH_MOUSEINTERACTION_EXAMPLE=OFF \
-DWITH_OVR_EXAMPLE=OFF \
Expand Down
3 changes: 3 additions & 0 deletions src/imgui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@
#
# 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018 —
# Vladimír Vondruš <mosra@centrum.cz>
# 2018 — ShaddyAQN <ShaddyAQN@gmail.com>
# 2018 — Jonathan Hale <squareys@googlemail.com>
# 2018 — Thomas Skrivan <skrivantomas@seznam.cz>
# 2018 — Natesh Narain <nnaraindev@gmail.com>
#
# This is free and unencumbered software released into the public domain.
#
Expand Down
16 changes: 10 additions & 6 deletions src/imgui/ImGuiExample.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
Vladimír Vondruš <mosra@centrum.cz>
2018 — ShaddyAQN <ShaddyAQN@gmail.com>
2018 — Jonathan Hale <squareys@googlemail.com>
2018 — Thomas Skrivan <skrivantomas@seznam.cz>
2018 — Tomáš Skřivan <skrivantomas@seznam.cz>
2018 — Natesh Narain <nnaraindev@gmail.com>
This is free and unencumbered software released into the public domain.
Expand Down Expand Up @@ -35,7 +35,11 @@
#include <Magnum/GL/Renderer.h>
#include <Magnum/GL/Version.h>

#ifdef CORRADE_TARGET_ANDROID
#include <Magnum/Platform/AndroidApplication.h>
#else
#include <Magnum/Platform/Sdl2Application.h>
#endif
#include <Magnum/GL/DefaultFramebuffer.h>

#include <Magnum/ImGuiIntegration/Integration.h>
Expand Down Expand Up @@ -99,11 +103,11 @@ void ImGuiExample::drawEvent() {
if(ImGui::ColorEdit3("Clear Color", _clearColor.data()))
GL::Renderer::setClearColor(_clearColor);
if(ImGui::Button("Test Window"))
_showTestWindow ^= 1;
_showTestWindow ^= true;
if(ImGui::Button("Another Window"))
_showAnotherWindow ^= 1;
_showAnotherWindow ^= true;
ImGui::Text("Application average %.3f ms/frame (%.1f FPS)",
1000.0f/ImGui::GetIO().Framerate, ImGui::GetIO().Framerate);
1000.0f/ImGui::GetIO().Framerate, ImGui::GetIO().Framerate);
}

/* 2. Show another simple window, this time using an explicit Begin/End pair */
Expand All @@ -125,9 +129,9 @@ void ImGuiExample::drawEvent() {
to do this once in the constructor. */
GL::Renderer::enable(GL::Renderer::Feature::Blending);
GL::Renderer::setBlendEquation(GL::Renderer::BlendEquation::Add,
GL::Renderer::BlendEquation::Add);
GL::Renderer::BlendEquation::Add);
GL::Renderer::setBlendFunction(GL::Renderer::BlendFunction::SourceAlpha,
GL::Renderer::BlendFunction::OneMinusSourceAlpha);
GL::Renderer::BlendFunction::OneMinusSourceAlpha);

GL::Renderer::disable(GL::Renderer::Feature::FaceCulling);
GL::Renderer::disable(GL::Renderer::Feature::DepthTest);
Expand Down

0 comments on commit 309e84c

Please sign in to comment.