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

Can I get marker's 3d position data? #27

Open
kezmanh opened this issue Oct 19, 2021 · 1 comment
Open

Can I get marker's 3d position data? #27

kezmanh opened this issue Oct 19, 2021 · 1 comment
Assignees
Labels
question Further information is requested

Comments

@kezmanh
Copy link

kezmanh commented Oct 19, 2021

I want to display a 3d model after scanned an image marker. I tried the example one but I want to try update the model with my own code.

May I know if it is possible for me to build my own three js 3d world and hide the models. Then I use the callback from ARnft to display the object and update its position to the marker?

@kalwalt kalwalt self-assigned this Nov 4, 2021
@kalwalt kalwalt added the question Further information is requested label Nov 4, 2021
@kalwalt
Copy link
Member

kalwalt commented Nov 4, 2021

If i understood right you want to hide and unhide your model. At the moment it is possible only to decide to hide or not at the creation, when you add the model/mesh. See the objVisilbility option

public add(mesh: Object3D, name: string, objVisibility: boolean) {

used inside the event listener
this.target.addEventListener("nftTrackingLost-" + this.uuid + "-" + name, (ev: any) => {
root.visible = objVisibility;
mesh.visible = objVisibility;
});

so you can decide if it visible or not after tracking is lost.
But you can't change this after, at least for now. But i think we can add this feature.

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

2 participants