Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Viewer param pickSurfacePrecisionEnabled #1530

Open
g-rodigy opened this issue Jun 11, 2024 · 0 comments
Open

Viewer param pickSurfacePrecisionEnabled #1530

g-rodigy opened this issue Jun 11, 2024 · 0 comments
Labels
question Further information is requested

Comments

@g-rodigy
Copy link
Contributor

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:

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

pickSurfacePrecisionEnabled: (!!cfg.pickSurfacePrecisionEnabled),

but not used in Scene class or I not found.

Does this param works and/or why pickSurfacePrecision is false?

@g-rodigy g-rodigy added the question Further information is requested label Jun 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant