Open g-rodigy opened 2 weeks ago
According the docs https://xeokit.github.io/xeokit-sdk/docs/class/src/viewer/Viewer.js~Viewer.html Viewer param pickSurfacePrecisionEnabled set to true and do pick like this:
pickSurfacePrecisionEnabled
true
const viewer = new Viewer({ canvasId: "myCanvas" }); viewer.pickSurfacePrecisionEnabled = true; viewer.scene.input.on('click', (coords) => { const hit = viewer.scene.pick({ canvasPos: coords, pickSurfacePrecision: true, pickSurface: true, snapToEdge: true, }, new PickResult()) // hit.pickSurfacePrecision is false })
Setting param here https://github.com/xeokit/xeokit-sdk/blob/e842ad84488ae439ef9a987615eff504ff5b5636/src/viewer/Viewer.js#L118 but not used in Scene class or I not found.
Does this param works and/or why pickSurfacePrecision is false?
pickSurfacePrecision
According the docs https://xeokit.github.io/xeokit-sdk/docs/class/src/viewer/Viewer.js~Viewer.html Viewer param
pickSurfacePrecisionEnabled
set totrue
and do pick like this:Setting param here https://github.com/xeokit/xeokit-sdk/blob/e842ad84488ae439ef9a987615eff504ff5b5636/src/viewer/Viewer.js#L118 but not used in Scene class or I not found.
Does this param works and/or why
pickSurfacePrecision
is false?