Feature Request: Ability to render Polyscope viewer in multiple ImGui windows
還沒有人認領這個 Issue。
評估
- 難度
- 5/5
- 預估耗時
- 一週以上
- 新手友好度
- 25/100
- Issue 類型
- 功能
- 描述清晰度
- 需要釐清
- 活躍度
- 停滯
- 技術堆疊
- cpp
研究方向
先從 issue 中的 main.cpp ImGui、GLFW 和 OpenGL3 範例開始,接著檢查 Polyscope 目前如何管理其視窗和事件迴圈。確定在多個 ImGui 視窗中渲染個別視覺化所需的架構進入點;當所要求的多視窗渲染 API 能在單一 GUI 中運作時,即表示完成。
由索引模型根據 Issue 內容生成。
描述
Hello Polyscope maintainers and community,
I'm using Polyscope to visualize point cloud data within a GUI application.
Currently, Polyscope encapsulates its own window and event loop and doesn't provide an API to render into multiple ImGui windows. In my case, I would like to show the 3D data in one window alongside 2 other windows to show the two 2D cameras windows. Specifically, I'm looking to render different Polyscope visualizations in separate ImGui windows within the same GUI.
I understand that this feature might involve significant changes to Polyscope's architecture, but I believe the added flexibility would benefit many users and use cases. I look forward to hearing your thoughts on this suggestion.
Thank you for your time and the excellent work on Polyscope!
This is the implementation of two different windows in the same GUI using ImGUI, GLFW and OpenGL3:
// main.cpp
#include "imgui.h"
#include "imgui_impl_glfw.h"
#include "imgui_impl_opengl3.h"
#include <GLFW/glfw3.h>
int main() {
// Set up window
glfwInit();
GLFWwindow* window = glfwCreateWindow(1280, 720, "Hello", NULL, NULL);
glfwMakeContextCurrent(window);
glfwSwapInterval(1); // Enable vsync
// Set up Dear ImGui context
IMGUI_CHECKVERSION();
ImGui::CreateContext();
ImGuiIO& io = ImGui::GetIO();
// Set up Platform/Renderer bindings
ImGui_ImplGlfw_InitForOpenGL(window, true);
ImGui_ImplOpenGL3_Init("#version 130");
while (!glfwWindowShouldClose(window)) {
glfwPollEvents();
// Start ImGui frame
ImGui_ImplOpenGL3_NewFrame();
ImGui_ImplGlfw_NewFrame();
ImGui::NewFrame();
// Here we construct our GUI
ImGui::SetNextWindowPos(ImVec2(0, 0));
ImGui::SetNextWindowSize(ImVec2(640, 720));
ImGui::Begin("Window 1");
ImGui::Text("This is window 1");
ImGui::End();
ImGui::SetNextWindowPos(ImVec2(640, 0));
ImGui::SetNextWindowSize(ImVec2(640, 720));
ImGui::Begin("Window 2");
ImGui::Text("This is window 2");
ImGui::End();
// Render ImGui frame
ImGui::Render();
int display_w, display_h;
glfwGetFramebufferSize(window, &display_w, &display_h);
glViewport(0, 0, display_w, display_h);
glClearColor(0.45f, 0.55f, 0.60f, 1.00f);
glClear(GL_COLOR_BUFFER_BIT);
ImGui_ImplOpenGL3_RenderDrawData(ImGui::GetDrawData());
glfwSwapBuffers(window);
}
// Cleanup
ImGui_ImplOpenGL3_Shutdown();
ImGui_ImplGlfw_Shutdown();
ImGui::DestroyContext();
glfwDestroyWindow(window);
glfwTerminate();
return 0;
}
- 主要語言
- C++
- 星號
- 2.2k
- 分支
- 242
- 平均合併
- 11 分鐘
- 30 天內合併 PR
- 1
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
nmwsharp/polyscope 的其他 Issue
-
難度 5/5 一週以上 新手友好度 35/100
-
難度 3/5 1-2 天 新手友好度 48/100
-
難度 5/5 一週以上 新手友好度 30/100
-
Rust Version 未關閉
難度 5/5 一週以上 新手友好度 15/100
-
enhancement
難度 5/5 一週以上 新手友好度 20/100
查看 nmwsharp/polyscope 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 75/100
flutter-webrtc/flutter-webrtc#2206 ·
-
難度 2/5 1-3 小時 新手友好度 70/100
google-ai-edge/LiteRT-LM#3739 ·
-
Component: GLib
難度 2/5 1-3 小時 新手友好度 70/100
-
難度 2/5 1-3 小時 新手友好度 65/100
brave/brave-browser#59300 ·
-
Mute ydb/tests/functional/dstool/test_canonical_requests.py.Test.test_group_take_snapshot in main 未關閉ai_reviewed
難度 2/5 1-3 小時 新手友好度 70/100
ydb-platform/ydb#53974 · 3 則留言 ·