Forum Discussion
evb7928
2 years agoHonored Guest
How to geometrically align a 3D model to real furniture?
For my video-see-through AR application I want a model to automatically be placed on the biggest found table surface. I achieved the first step: The model is correctly positioned at the table center....
4vit
2 years agoExplorer
May be you can try the below ones
- Attach the script to an empty GameObject in your scene
- Assign your model prefab in the Inspector
- Adjust the alignment settings as needed
- Use the events to respond to alignment success/failure
- evb79282 years agoHonored Guest
Hello 4vit , thank you for reaching out.
Your first two suggestions are a given. I thought mentioning that my script works at positioning implies that I already attached the script to an Empty in my Scene and assigned the Model Prefab.
Your advice to "Adjust the alignment settings as needed" is not helpful for me, as that is literally my question how to.
I have already tried different lines of code to do that but didn't succeed (it didn't align the model to the table). I had hoped for any links to similar cases (that I haven't found) with code examples, or lines of code I could try out.
I have already tried things like ...modelInstance.transform.rotation = largestTableSurface.transform.rotation;However that didn't work.
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 3 months ago