Hello,
-
what is the size of the plane created with
http://unity3d.com/support/documentation/ScriptReference/Plane.Plane.html ? -
How can I make it visible in my code for debigging?
Hello,
what is the size of the plane created with
http://unity3d.com/support/documentation/ScriptReference/Plane.Plane.html ?
How can I make it visible in my code for debigging?
The plane ‘created’ by that is a geometric plane and is infinite in size.
I don’t quite follow; what way do you want it to be displayed?
ah ok, because it was not clear from the scripting manual. If it is infinite then the second question is not needed
thanks!
It’s clear. A plane is an unbounded surface with infinite extent, so there’s really no ambiguity regarding its size.
But, if you need to visualize the plane for some reason or other, it can certainly be done. A typical solution is to draw a 2-d grid of some finite size. You’ll want the grid to lie in the plane of course, but otherwise the position and orientation can be more or less arbitrary.
Building the basis for the grid is essentially a billboarding problem (that is, building an orientation given only a direction vector). As for drawing the grid itself, you can use Debug.DrawLine() or Gizmos.DrawLine().
ok, thanks. Somehow in my mind I was confusing plane with polygon. This is where the question about size came from