- Home /
Align 2 objets edge to edge
Hi,
I need help to align properly 2 objets (imported from 3DS via fbx) edge vs edge.
These are complex shapes (buildings), and I need to align them along the road (another fbx from 3ds), and my problem is : they need to be rotated to align perfectly, but I don't know the angle.
I can use snapping to make vertices join perfectly, but my models are still not aligned (I tried to set manually the angle, but that's still not perfect).
Thanks for any help.
Can you set their alignment in 3ds then import them in Unity?
Thanks for the tip, but that's unmanageable. Each building is more than 500k polygons, and we had to split them into separate 3DS scene so that the import in unity takes less than 10 hours.
@++
Addendum : the whole scene is 22 buildings modeled in detail, plus the road and environnement.
We're talking about millions of polygons in total (probably 5$$anonymous$$), and that's why we had to split it in many separated objects.
Thanks
I don't have a clear picture of the problem. A complex 3D scene must be re-constructed in Unity, but you can't edit the models such that their rotations and origins make reconstruction easy? Why not, exactly? Finding a "perfect" arbitrary rotation to achieve a seamless reconstruction is so impractical, I wouldn't wish that job on anyone.
Hi,
I'll try to make it simple :)
On the one hand, I got my different buildings. Each building is a separate 3DS scene. They are always designed with their walls for$$anonymous$$g 90° angles with the screen (don't know how to explain).
On the other hand, I got the road and the environnement, which is another 3DS scene. The road is not perfectly straight, it makes a sort of "S".
If I want to put the buildings along the road, each building must be slightly rotated so that its outside walls match the edge of the road and there is no gaps between the road and the entry of the building.
And that's my issue. I can rotate each building by hand, but the matching is never perfect. I snapped on corner of my building to the road, and I try to adjust the rotation by after, but it's very complicated to get it perfect.
Thanks for your contribution.
Answer by MrSoad · Nov 11, 2014 at 11:56 AM
Have you still got your original scene. If so place a marker at the root of each building in the anchor position with correct rotation(now delete everything from this scene except for these markers and save as a new file). Now import this simple marker scene into Unity. Now parent your Buildings onto their respective marker positions and set their local position and rotation to (0,0,0). They should all be in exactly the right place with exactly the right rotation if you do this.
Thanks for the tip.
What sort of marker should I use in 3DS ?
Anything you want from a std cube to an appropriate type of empty. As long at the marker has a position and rotation attribute then it will do the job required. Do a small test first to make sure you have everything right, then when you know it's working correctly do it for your full scene.
Your answer
![](https://koobas.hobune.stream/wayback/20220613171232im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
align y axis of a gameobject to z axis of another gameobject ??? 1 Answer
Aligning Y-Axis rotation of stretched gameobject to specific angles while retaining initial position 0 Answers
How can I obtain the overall rotation of multiple selected gameobjects in the unity editor? 2 Answers
How to handler rotation of a Gameobject while aligning it with normals 1 Answer
Aligning to a specific axis (6 DOF Descent-like movement) 1 Answer