Skip to content

Proposal: Rendering Window API for Custom Gizmos and Model Interaction #620

Description

@Isaina

Hello,

I would like to propose adding or exposing a Rendering Window API in Coin3D that would allow external developers to create custom interactive tools inside the 3D viewport.

The main goal would be to enable plugins or external modules to add:

  • custom viewport gizmos,
  • small floating command windows,
  • interactive buttons inside the 3D view,
  • object manipulation tools,
  • keyboard-based movement and rotation,
  • visual annotations,
  • simple CAD-style interaction overlays.

For example, when a user selects a 3D object, a plugin could display a small custom interaction panel near the object or inside the viewport, with commands such as:

Move / Copy / Edit / Rotate - / Rotate + / OK / Cancel

This would make it possible to build more advanced CAD/BIM-style workflows on top of Coin 3D without modifying the core application.

Requested API capabilities

It would be very useful if Coin 3D exposed an API for:

  1. Drawing custom 2D UI elements over the 3D viewport
  2. Anchoring UI elements to selected 3D objects or screen positions
  3. Receiving mouse click events on custom viewport buttons
  4. Receiving keyboard events for object manipulation
  5. Moving, rotating, or editing selected objects programmatically
  6. Adding temporary measurement lines, labels, arrows, and annotations
  7. Creating plugin-defined interaction modes
  8. Refreshing or invalidating the viewport after external changes

Use case

One possible use case is a CAD/BIM plugin where the user selects a duct, pipe, wall, or mechanical component and then receives a small contextual gizmo directly inside the 3D view.

This would allow the user to move the object, rotate it, edit parameters, confirm the operation, or cancel it without opening separate dialogs.

The interaction could look similar to lightweight CAD viewport controls or Blender-style gizmos, but adapted to Coin 3D.

Why this would be useful

Such an API would make Coin 3D more extensible and allow developers to build:

  • CAD tools,
  • BIM tools,
  • HVAC routing tools,
  • object editing tools,
  • measurement tools,
  • annotation tools,
  • visual scripting helpers,
  • interactive engineering workflows.

This would also help keep the Coin 3D core clean, while allowing advanced functionality to be developed as plugins or external modules.

Suggested direction

A minimal first version could include:

  • viewport overlay drawing,
  • mouse event callbacks,
  • keyboard event callbacks,
  • selected object access,
  • transform API for move/rotate/scale,
  • simple text/rectangle/button drawing,
  • viewport refresh function.

Later, this could evolve into a more complete plugin API for interactive 3D tools.

Thank you for considering this proposal.

Image Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions