Hey All,
Can somebody give me a hint on how to select the house primitives facing the road curve here? (The houses and the roads are two separate objects)
Select primitives facing curve
987 1 1- stinzen
- Member
- 36 posts
- Joined: March 2014
- Offline
- Aizatulin
- Member
- 475 posts
- Joined: July 2005
- Offline
Hi,
As an idea:
For each primitive calculate the closest point on the road geoemtry (xyzdist() can be used).
Use the direction (from the center of the primitive to the closest point) to calculate the angle between the direction and the primitive normal.
If the roads are on a plane, the direction should be projected onto this plane/surface (probably the plane is the xz-plane).
Now a threshold can be used to detect, if the angle is higher/smaller than this threshold to set an id.
As an idea:
For each primitive calculate the closest point on the road geoemtry (xyzdist() can be used).
Use the direction (from the center of the primitive to the closest point) to calculate the angle between the direction and the primitive normal.
If the roads are on a plane, the direction should be projected onto this plane/surface (probably the plane is the xz-plane).
Now a threshold can be used to detect, if the angle is higher/smaller than this threshold to set an id.
-
- Quick Links