Skip to content

Commit

Permalink
doc / add implot3D
Browse files Browse the repository at this point in the history
  • Loading branch information
pthom committed Jan 2, 2025
1 parent a55802f commit e4fa348
Show file tree
Hide file tree
Showing 17 changed files with 120 additions and 66 deletions.
34 changes: 21 additions & 13 deletions bindings/imgui_bundle/Readme_pypi.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,38 +133,46 @@ alt="battery implot" /></p></td>
</tr>
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/brenocq/implot3d">ImPlot3D</a>: Immediate Mode
3D Plotting</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/battery_implot3d.jpg"
alt="battery implot3d" /></p></td>
</tr>
<tr class="even">
<td style="text-align: left;"><p><a
href="https://github.com/CedricGuillemet/ImGuizmo.git">ImGuizmo</a>:
Immediate mode 3D gizmo for scene editing and other controls based on
Dear ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_gizmo.jpg"
alt="demo gizmo" /></p></td>
</tr>
<tr class="even">
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/BalazsJako/ImGuiColorTextEdit">ImGuiColorTextEdit</a>:
Colorizing text editor for ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_editor.jpg"
alt="demo widgets editor" /></p></td>
</tr>
<tr class="odd">
<tr class="even">
<td style="text-align: left;"><p><a
href="https://github.com/thedmd/imgui-node-editor">imgui-node-editor</a>:
Node Editor built using Dear ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_node_editor.jpg"
alt="demo node editor" /></p></td>
</tr>
<tr class="even">
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/mekhontsev/imgui_md.git">imgui_md</a>: Markdown
renderer for Dear ImGui using MD4C parser</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_md.jpg"
alt="demo widgets md" /></p></td>
</tr>
<tr class="odd">
<tr class="even">
<td style="text-align: left;"><p><a
href="https://github.com/pthom/immvision.git">ImmVision</a>: Immediate
image debugger and insights</p></td>
Expand All @@ -174,7 +182,7 @@ alt="demo immvision process 1" /> <img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_immvision_process_2.jpg"
alt="demo immvision process 2" /></p></td>
</tr>
<tr class="even">
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/memononen/nanovg">NanoVG</a>: Antialiased 2D
vector drawing library on top of OpenGL for UI and
Expand All @@ -183,63 +191,63 @@ visualizations</p></td>
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/nanovg_full_demo.jpg"
alt="nanovg full demo" /></p></td>
</tr>
<tr class="odd">
<tr class="even">
<td style="text-align: left;"><p><a
href="https://github.com/andyborrell/imgui_tex_inspect">imgui_tex_inspect</a>:
A texture inspector tool for Dear ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_imgui_tex_inspector.jpg"
alt="demo imgui tex inspector" /></p></td>
</tr>
<tr class="even">
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/pthom/ImFileDialog.git">ImFileDialog</a>: A
file dialog library for Dear ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_imfiledialog.jpg"
alt="demo widgets imfiledialog" /></p></td>
</tr>
<tr class="odd">
<tr class="even">
<td style="text-align: left;"><p><a
href="https://github.com/samhocevar/portable-file-dialogs">portable-file-dialogs</a>
<em>OS native</em> file dialogs library (C++11, single-header)</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_portablefiledialogs.jpg"
alt="demo widgets portablefiledialogs" /></p></td>
</tr>
<tr class="even">
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/altschuler/imgui-knobs">imgui-knobs</a>: Knobs
widgets for ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_knobs.jpg"
alt="demo widgets knobs" /></p></td>
</tr>
<tr class="odd">
<tr class="even">
<td style="text-align: left;"><p><a
href="https://github.com/dalerank/imspinner">imspinner</a>: Set of nice
spinners for imgui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_spinners.jpg"
alt="demo widgets spinners" /></p></td>
</tr>
<tr class="even">
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/cmdwtf/imgui_toggle">imgui_toggle</a>: A toggle
switch widget for Dear ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_toggle.jpg"
alt="demo widgets toggle" /></p></td>
</tr>
<tr class="odd">
<tr class="even">
<td style="text-align: left;"><p><a
href="https://github.com/aiekick/ImCoolBar">ImCoolBar</a>: A Cool bar
for Dear ImGui</p></td>
<td style="text-align: left;"><p><img
src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_widgets_coolbar.jpg"
alt="demo widgets coolbar" /></p></td>
</tr>
<tr class="even">
<tr class="odd">
<td style="text-align: left;"><p><a
href="https://github.com/hnOsmium0001/imgui-command-palette.git">imgui-command-palette</a>:
A Sublime Text or VSCode style command palette in ImGui</p></td>
Expand Down
61 changes: 41 additions & 20 deletions bindings/imgui_bundle/doc/Readme.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,9 @@ Dear ImGui Bundle includes the following libraries, which are available in {cpp}
|https://github.com/epezent/implot[ImPlot]: Immediate Mode Plotting
|image:{url-demo-images}/battery_implot.jpg[width=200]

|https://github.com/brenocq/implot3d[ImPlot3D]: Immediate Mode 3D Plotting
|image:{url-demo-images}/battery_implot3d.jpg[width=200]


|https://github.com/CedricGuillemet/ImGuizmo.git[ImGuizmo]: Immediate mode 3D gizmo for scene editing and other controls based on Dear ImGui
|image:{url-demo-images}/demo_gizmo.jpg[width=200]
Expand Down Expand Up @@ -757,11 +760,9 @@ void LoadFonts(AppState& appState) // This is called by runnerParams.callbacks.L
HelloImGui::ImGuiDefaultSettings::LoadDefaultFont_WithFontAwesomeIcons();
// Load the title font. Also manually merge FontAwesome icons to it
appState.TitleFont = HelloImGui::LoadFont("fonts/DroidSans.ttf", 18.f);
HelloImGui::FontLoadingParams fontLoadingParamsTitleIcons;
fontLoadingParamsTitleIcons.mergeToLastFont = true;
fontLoadingParamsTitleIcons.useFullGlyphRange = true;
appState.TitleFont = HelloImGui::LoadFont("fonts/Font_Awesome_6_Free-Solid-900.otf", 18.f, fontLoadingParamsTitleIcons);
fontLoadingParamsTitleIcons.mergeFontAwesome = true;
appState.TitleFont = HelloImGui::LoadFont("fonts/Roboto/Roboto-BoldItalic.ttf", 18.f, fontLoadingParamsTitleIcons);
// Load an Emoji font
HelloImGui::FontLoadingParams fontLoadingParamsEmoji;
Expand Down Expand Up @@ -1130,7 +1131,7 @@ void DemoAssets(AppState& appState)
void DemoFonts(AppState& appState)
{
ImGui::PushFont(appState.TitleFont); ImGui::Text("Fonts - " ICON_FA_PEN_NIB); ImGui::PopFont();
ImGui::PushFont(appState.TitleFont); ImGui::Text("Fonts - " ICON_FA_ROCKET); ImGui::PopFont();
ImGui::TextWrapped("Mix icons " ICON_FA_FACE_SMILE " and text " ICON_FA_ROCKET "");
if (ImGui::IsItemHovered())
Expand Down Expand Up @@ -1707,12 +1708,10 @@ def load_fonts(app_state: AppState): # This is called by runnerParams.callbacks
hello_imgui.imgui_default_settings.load_default_font_with_font_awesome_icons()
# Load the title font
app_state.title_font = hello_imgui.load_font("fonts/DroidSans.ttf", 18.0)
# app_state.title_font = hello_imgui.load_font("fonts/DroidSans.ttf", 18.0)
font_loading_params_title_icons = hello_imgui.FontLoadingParams()
font_loading_params_title_icons.merge_to_last_font = True
font_loading_params_title_icons.use_full_glyph_range = True
app_state.title_font = hello_imgui.load_font("fonts/Font_Awesome_6_Free-Solid-900.otf",
18.0, font_loading_params_title_icons)
font_loading_params_title_icons.merge_font_awesome = True
app_state.title_font = hello_imgui.load_font("fonts/Roboto/Roboto-BoldItalic.ttf", 18, font_loading_params_title_icons)
# Load the emoji font
font_loading_params_emoji = hello_imgui.FontLoadingParams()
Expand Down Expand Up @@ -2112,7 +2111,7 @@ def demo_assets(app_state: AppState):
def demo_fonts(app_state: AppState):
imgui.push_font(app_state.title_font)
imgui.text("Fonts - " + icons_fontawesome_6.ICON_FA_PEN_NIB)
imgui.text("Fonts - " + icons_fontawesome_6.ICON_FA_ROCKET)
imgui.pop_font()
imgui.text_wrapped("Mix icons " + icons_fontawesome_6.ICON_FA_FACE_SMILE + " and text " + icons_fontawesome_6.ICON_FA_ROCKET)
Expand Down Expand Up @@ -2655,7 +2654,7 @@ NOTE: See link:https://github.com/ocornut/imgui_test_engine/blob/main/imgui_test
{cpp}
[source, cpp]
----
#ifdef IMGUI_BUNDLE_WITH_TEST_ENGINE
#ifdef HELLOIMGUI_WITH_TEST_ENGINE
// A demo app that demonstrates how to use ImGui Test Engine (https://github.com/ocornut/imgui_test_engine)
//
// It demonstrates how to:
Expand Down Expand Up @@ -2901,9 +2900,9 @@ void ApplyApplicationLayout(HelloImGui::RunnerParams* runnerParams)
runnerParams->dockingParams.dockableWindows = CreateDockableWindows();
runnerParams->dockingParams.layoutCondition = HelloImGui::DockingLayoutCondition::ApplicationStart;
}
#else
#else // #ifdef HELLOIMGUI_WITH_TEST_ENGINE
int main(int, const char**) {}
#endif // #ifdef IMGUI_BUNDLE_WITH_TEST_ENGINE
#endif // #ifdef HELLOIMGUI_WITH_TEST_ENGINE
----
====

Expand Down Expand Up @@ -3601,6 +3600,7 @@ link:https://traineq.org/ImGuiBundle/emscripten/bin/demo_widgets.html[Try these
----
// Part of ImGui Bundle - MIT License - Copyright (c) 2022-2024 Pascal Thomet - https://github.com/pthom/imgui_bundle
#include "hello_imgui/hello_imgui.h"
#include "hello_imgui/icons_font_awesome_4.h"
#include "imspinner/imspinner.h"
#include "imgui_toggle/imgui_toggle.h"
#include "imgui_toggle/imgui_toggle_presets.h"
Expand Down Expand Up @@ -3899,9 +3899,18 @@ void DemoImFileDialog()
ImGuiMd::RenderUnindented(R"(
# ImFileDialog
[ImFileDialog](https://github.com/pthom/ImFileDialog.git) provides file dialogs for ImGui, with images preview.
*Not (yet) adapted for High DPI resolution under windows*
[ImFileDialog](https://github.com/pthom/ImFileDialog.git) provides file dialogs for ImGui.
)");
ImGui::SameLine();
ImGui::Text(ICON_FA_EXCLAMATION_TRIANGLE);
ImGui::SetItemTooltip(
"It is advised to use Portable File Dialogs instead, which offer native dialogs on each platform, "
"as well as notifications and messages.\n\n"
"Known limitations of ImFileDialog:\n"
" * Not adapted for High DPI resolution under windows\n"
" * No support for multi-selection\n"
" * Will not work under python with a pure python backend (requires to use `immapp.run()`)"
);
if (ImGui::Button("Open file"))
ifd::FileDialog::Instance().Open(
Expand Down Expand Up @@ -4094,6 +4103,7 @@ from imgui_bundle import (
immapp,
ImVec4,
im_cool_bar,
icons_fontawesome,
)
from imgui_bundle import imgui_command_palette as imcmd
from imgui_bundle import portable_file_dialogs as pfd
Expand Down Expand Up @@ -4355,14 +4365,24 @@ def demo_imfile_dialog():
if not has_submodule("im_file_dialog"):
return
from imgui_bundle import im_file_dialog as ifd
imgui_md.render_unindented(
"""
# ImFileDialog
[ImFileDialog](https://github.com/pthom/ImFileDialog.git) provides file dialogs for ImGui, with images preview.
*Not (yet) adapted for High DPI resolution under windows*
[ImFileDialog](https://github.com/pthom/ImFileDialog.git) provides file dialogs for ImGui.
"""
)
# Warning / low support
imgui.same_line()
imgui.text(icons_fontawesome.ICON_FA_EXCLAMATION_TRIANGLE)
imgui.set_item_tooltip("""
It is advised to use Portable File Dialogs instead, which offer native dialogs on each platform,
as well as notifications and messages.
Known limitations of ImFileDialog:
* Not adapted for High DPI resolution under windows
* No support for multi-selection
* Will not work under python with a pure python backend (requires to use `immapp.run()`)
""")
if imgui.button("Open file"):
ifd.FileDialog.instance().open(
Expand Down Expand Up @@ -6162,9 +6182,10 @@ if __name__ == "__main__":
from imgui_bundle.python_backends.glfw_backend import GlfwRenderer
import OpenGL.GL as gl # type: ignore
# When using a pure python backend, prefer to import glfw before imgui_bundle (so that you end up using the standard glfw, not the one provided by imgui_bundle)
import glfw # type: ignore
from imgui_bundle import imgui, imgui_ctx
from imgui_bundle import imgui_md
import glfw # type: ignore
import sys
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ Dear ImGui Bundle includes the following libraries, which are available in {cpp}
|https://github.com/epezent/implot[ImPlot]: Immediate Mode Plotting
|image:{url-demo-images}/battery_implot.jpg[width=200]

|https://github.com/brenocq/implot3d[ImPlot3D]: Immediate Mode 3D Plotting
|image:{url-demo-images}/battery_implot3d.jpg[width=200]


|https://github.com/CedricGuillemet/ImGuizmo.git[ImGuizmo]: Immediate mode 3D gizmo for scene editing and other controls based on Dear ImGui
|image:{url-demo-images}/demo_gizmo.jpg[width=200]
Expand Down
2 changes: 1 addition & 1 deletion docs/assets_about.html
Original file line number Diff line number Diff line change
Expand Up @@ -1274,7 +1274,7 @@ <h4 id="_app_settings">App settings</h4>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/cpp_specific.html
Original file line number Diff line number Diff line change
Expand Up @@ -539,7 +539,7 @@ <h3 id="_debug_native_c_in_python_scripts">Debug native C&#43;&#43; in python sc
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/devel_docs.html
Original file line number Diff line number Diff line change
Expand Up @@ -674,7 +674,7 @@ <h3 id="folders">Repository folders structure</h3>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/faq.html
Original file line number Diff line number Diff line change
Expand Up @@ -819,7 +819,7 @@ <h4 id="_windows_linux_adapting_windows_and_font_size_when_application_is_moved_
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -695,7 +695,7 @@ <h1>Dear ImGui Bundle</h1>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/install_cpp.html
Original file line number Diff line number Diff line change
Expand Up @@ -638,7 +638,7 @@ <h3 id="_run_the_c_demo">Run the C&#43;&#43; demo</h3>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion docs/install_python.html
Original file line number Diff line number Diff line change
Expand Up @@ -646,7 +646,7 @@ <h3 id="_run_the_python_demo">Run the python demo</h3>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
6 changes: 5 additions & 1 deletion docs/introduction.html
Original file line number Diff line number Diff line change
Expand Up @@ -505,6 +505,10 @@ <h2 id="introduction">What&#8217;s in the pack?</h2>
<td class="tableblock halign-left valign-top"><p class="tableblock"><span class="image"><img src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/battery_implot.jpg" alt="battery implot" width="200"></span></p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><a href="https://github.com/brenocq/implot3d">ImPlot3D</a>: Immediate Mode 3D Plotting</p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><span class="image"><img src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/battery_implot3d.jpg" alt="battery implot3d" width="200"></span></p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><a href="https://github.com/CedricGuillemet/ImGuizmo.git">ImGuizmo</a>: Immediate mode 3D gizmo for scene editing and other controls based on Dear ImGui</p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><span class="image"><img src="https://raw.githubusercontent.com/pthom/imgui_bundle/main/bindings/imgui_bundle/doc/doc_images/demo_gizmo.jpg" alt="demo gizmo" width="200"></span></p></td>
</tr>
Expand Down Expand Up @@ -574,7 +578,7 @@ <h2 id="introduction">What&#8217;s in the pack?</h2>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2024-11-24 13:30:59 +0100
Last updated 2025-01-02 15:11:02 +0100
</div>
</div>
</body>
Expand Down
Loading

0 comments on commit e4fa348

Please sign in to comment.