Sorry I missed this. The normalize function just divides or scales a vector so that its magnitude is 1.
I’m pretty sure the ion SDK (which is a commercial add-on to CesiumJS) has an API for this:
Although this isn’t available in the open source CesiumJS. I think you’d have to sample more points around the original point, and then use a cross product to get a vector perpendicular to two vectors that line in the plane.
We are trying to use the surface normal of the picked position to create an algorithm that returns a set of images that are visible around the picked position and that are in the direction of normal. (i.e., a better way to filtering out images that are associated with points that are occluded).
Computes the normal of the plane tangent to the surface of the ellipsoid at the provided position.
So if you need the surface normal of the globe (as opposed to buildings/3d tiles) then yes that’ll give you a vector pointing in the correct direction.