Generate a uniform distribution of orientations

146 Views Asked by At

I am rendering images of a 3D object and am trying to generate a uniform distribution of orientations for this object. I am unsure of how to do this, and considerations that are necessary to take into account.

  1. Is a uniform distribution of orientations equivalent to a uniform distribution of rotations as apparent to a rendering camera? That is, if I generate uniform orientations, will it look uniform to the camera?
  2. How do I generate a uniform distribution of orientations? Is it possible to generate uniform points on a d-sphere to get a set of rotations? If so, would this mean generating points on a 3D sphere or a 4D hypersphere?
2

There are 2 best solutions below

3
On

Simple in Mathematica:

Graphics3D[
   {Opacity[0.5], Yellow, Sphere[], 
    Black, PointSize[0.02], 
    Point /@ SpherePoints[200]}]

Sphere with uniform points

0
On

One good way to generate a uniformly distributed point on the unit sphere in $\mathbb R^n$ is to take $(Z_1,\ldots,Z_n)$ independent with standard normal distribution, and divide by the norm $\sqrt{Z_1^2 + \ldots + Z_n^2}$. To get a uniformly distributed orthogonal $n \times n$ matrix, take $n^2$ independent standard normal $Z_{ij}$ and orthonormalize by Gram-Schmidt.