Skip to content

reference_models + #913

Description

@zxterProxy

Detailed description of your suggestion

Hi developer,

Recently, I needed to work with reference models. The plugin works great, but I found the workflow a bit limiting in some areas. I did some duct-tape coding with the help of an AI and added a few features that might be useful to others. If you find any of the following valuable, I'd be very happy.

Added functionality:

Scale Gizmo (Resize tool)

Fixed resize() — correct signature with 5 parameters (matching Cube)

Corrected formula for negative handles (-X) and bidirectional (Alt) scaling

Added NaN protection

Rotation Gizmo (E key)

Added mesh.rotation.order = Format.euler_order in setup() — ensures correct Euler angle order

Drag-and-drop .gltf/.glb

Added support for GLB (binary read type)

Added error callback in GLTFLoader

Added undo support when dropping multiple files

Group movement

ReferenceModel.prototype.transferOrigin — syncs child reference positions when moving a group

Blockbench.on('update_view') — updates child transforms (position + rotation + scale) when group changes

addTo override — explicitly binds a child Three.js mesh to the parent group's mesh

Pivot control

Added X, Y, Z fields in the Edit Panel to edit the reference model's origin point

Frustum culling

gltf.scene.traverse(... child.frustumCulled = false) — models no longer disappear when rotated

Click-to-select

Raycaster on Canvas — select reference models with a mouse click

Thanks for considering!

reference_models.js

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions