This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
=============================================================================== | |
Public Domain (www.unlicense.org) | |
=============================================================================== | |
This is free and unencumbered software released into the public domain. | |
Anyone is free to copy, modify, publish, use, compile, sell, or distribute this | |
software, either in source code form or as a compiled binary, for any purpose, | |
commercial or non-commercial, and by any means. | |
In jurisdictions that recognize copyright laws, the author or authors of this | |
software dedicate any and all copyright interest in the software to the public |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
=============================================================================== | |
Public Domain (www.unlicense.org) | |
=============================================================================== | |
This is free and unencumbered software released into the public domain. | |
Anyone is free to copy, modify, publish, use, compile, sell, or distribute this | |
software, either in source code form or as a compiled binary, for any purpose, | |
commercial or non-commercial, and by any means. | |
In jurisdictions that recognize copyright laws, the author or authors of this | |
software dedicate any and all copyright interest in the software to the public |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Original code: https://gist.github.com/syzdek/eba233ca33e1b5a45a99 | |
// Original code license: | |
/* | |
* TOTP: Time-Based One-Time Password Algorithm | |
* Copyright (c) 2015, David M. Syzdek <david@syzdek.net> | |
* All rights reserved. | |
* | |
* Redistribution and use in source and binary forms, with or without | |
* modification, are permitted provided that the following conditions are | |
* met: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* This code is an extension of the 'keyboard section' present in 'imgui_demo.cpp'. | |
License is the same (MIT License AFAIK) | |
*/ | |
#include <imgui_virtual_keyboard.h> | |
namespace ImGui { | |
// VirtualKeyboard Implementation | |
const char** GetKeyboardLogicalLayoutNames() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// gist made after this issue: https://github.com/mackron/dr_libs/issues/142 | |
/* | |
The license refers to this single file. | |
Every included or linked library comes with its own license | |
=============================================================================== | |
Public Domain (www.unlicense.org) | |
=============================================================================== | |
This is free and unencumbered software released into the public domain. | |
Anyone is free to copy, modify, publish, use, compile, sell, or distribute this | |
software, either in source code form or as a compiled binary, for any purpose, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// EXPERIMENTAL (ALMOST UNTESTED) InputTextMultiline(...) for std::strings. | |
// USE IT AT YOUR OWN RISK! | |
// Example usage: | |
/* | |
static std::string text = "Dear ImGui lacks InputTextMultiline(...) for std::string."; | |
static bool isTextBoxActive = false; // A better implementation should remove this | |
ImGui::InputTextMultiline("###ADummyLabelForMe",text,isTextBoxActive); | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// On Ubuntu, I can compile it with the following command line (provided that imgui.h is two folders up, and that I want to use glfw): | |
// gcc -o basicExample mainBasic.cpp -I"../../" ../../imgui.cpp ../../imgui_draw.cpp -D"IMGUI_INCLUDE_IMGUI_USER_H" -D"IMGUI_INCLUDE_IMGUI_USER_INL" -I"/usr/include/GLFW" -D"IMGUI_USE_GLFW_BINDING" -L"/usr/lib/x86_64-linux-gnu" -lglfw -lX11 -lm -lGL -lstdc++ -s | |
// This file is intended to test/answer to https://github.com/Flix01/imgui/issues/15 | |
// RESULT: | |
// Dynamic enum works! | |
// And if you can use dynamic_cast<>() making new Node types that use it is easier (non-intrusive) | |
// Otherwise you must modify the code of CustomEnumEditorNode::render(...) for every new user class you add. | |
// | |
// Added also some code to serialize/deserialize the enum names ("TestEnumNames") together |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* edtaa3() | |
* | |
* Sweep-and-update Euclidean distance transform of an | |
* image. Positive pixels are treated as object pixels, | |
* zero or negative pixels are treated as background. | |
* An attempt is made to treat antialiased edges correctly. | |
* The input image must have pixels in the range [0,1], | |
* and the antialiased image should be a box-filter | |
* sampling of the ideal, crisp edge. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#include <imgui.h> | |
#include <imgui_internal.h> | |
// ImDrawList methods to display vertical text | |
/* | |
// TEST: inside a window: | |
ImGuiWindow* window = ImGui::GetCurrentWindow(); | |
ImDrawList* dl = window->DrawList; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "imguitabwindow.h" | |
#include <imgui_internal.h> | |
#include <imgui.h> // intellisense | |
// TODO: Clean this code, it's a mess! | |
namespace ImGui { |
NewerOlder