Skip to content

InfoEditor - #63

Open
alemuntoni wants to merge 55 commits into
cnr-isti-vclab:mainfrom
alemuntoni:draw_element_id
Open

InfoEditor#63
alemuntoni wants to merge 55 commits into
cnr-isti-vclab:mainfrom
alemuntoni:draw_element_id

Conversation

@alemuntoni

Copy link
Copy Markdown
Member

This pull request introduces the InfoEditor tool to the render module, providing a visual way to inspect mesh elements (vertices, faces, edges) directly in the viewport. It also includes UI integrations (Qt and ImGui), improvements to the underlying ID rendering logic, and associated test coverage.

Key Changes

  • InfoEditor Tool: Added InfoEditor to allow users to visually query and inspect mesh elements, drawing text overlays with element data (e.g., Vertex ID, Face ID, etc.).
  • UI Integration: Included new InfoEditor toolbar frames and settings panels for both Qt and ImGui (info_editor_frame, info_editor_settings_frame).
  • Enhanced ID Rendering (drawId): Upgraded ID rendering to write 64-bit values into the GPU buffer, encoding Object ID (16-bit), Element Type (16-bit), and Element ID (32-bit). Now correctly writes face IDs instead of triangle IDs for polygonal meshes.
  • Text Rendering Improvements: Handled DPI scaling for text rendering and fixed a crash in TextManager at exit. Added support to customize font color and size for the InfoEditor.
  • Testing: Added headless tests (007-info-editor-headless) to validate the new info extraction on both triangular and polygonal meshes. Fixed a Vulkan-specific bug for these tests on Linux.
  • Refactoring & Cleanups: Various minor cleanups, documentation updates.

# Conflicts:
#	vclib/render/include/vclib/bgfx/drawable/drawable_mesh_bgfx.h
# Conflicts:
#	vclib/render/include/vclib/bgfx/drawable/drawable_mesh_bgfx.h
# Conflicts:
#	vclib/render/include/vclib/qt/gui/toolbar_frames.h
# Conflicts:
#	vclib/render/include/vclib/render/headless_mesh_viewer.h
# Conflicts:
#	vclib/render/include/vclib/bgfx/drawable/drawable_mesh_bgfx.h
#	vclib/render/include/vclib/render/drawers/abstract_viewer_drawer.h
# Conflicts:
#	vclib/render/include/vclib/bgfx/drawable/mesh/mesh_poly_mapping_buffers.h
#	vclib/render/include/vclib/bgfx/drawable/mesh/mesh_render_buffers.h
#	vclib/render/include/vclib/bgfx/drawable/mesh/mesh_selection_buffers.h
# Conflicts:
#	vclib/render/include/vclib/bgfx/drawable/drawable_mesh_bgfx.h
# Conflicts:
#	vclib/render/shaders/vclib/bgfx/primitives/lines/fs_lines_id_in.sh
#	vclib/render/shaders/vclib/bgfx/primitives/lines/fs_lines_in.sh
#	vclib/render/shaders/vclib/bgfx/primitives/lines/varying.def.sc
#	vclib/render/shaders/vclib/bgfx/primitives/lines/vs_lines_in.sh
# Conflicts:
#	vclib/render/include/vclib/qt/gui/editor_settings_frames/info_editor_settings_frame.h
#	vclib/render/src/vclib/qt/gui/editor_settings_frames/info_editor_settings_frame.cpp
#	vclib/render/src/vclib/qt/gui/editor_settings_frames/info_editor_settings_frame.ui
# Conflicts:
#	vclib/render/src/vclib/bgfx/read_from_gpu_buffer.cpp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant