Background and motivation
Matrix4x4 recently added APIs for left handed creation of Matrix4x4. Replacing another matrix implementation led me to nice the billboard APIs did not get left handed equivalents. In order to not confuse people about which functions are actually expecting a right handed system, we should add left handed versions for the billboard APIs.
API Proposal
namespaceSystem.Numerics;publicpartialstructMatrix4x4{publicstaticMatrix4x4CreateBillboardLeftHanded(Vector3objectPosition,Vector3cameraPosition,Vector3cameraUpVector,Vector3cameraForwardVector)publicstaticMatrix4x4CreateConstrainedBillboardLeftHanded(Vector3objectPosition,Vector3cameraPosition,Vector3rotateAxis,Vector3cameraForwardVector,Vector3objectForwardVector)}API Usage
varbillboardLeftHanded=Matrix4x4.CreateBillboardLeftHanded(objectPosition,cameraPosition,cameraUpVector,cameraForwardVector);
...var billboardConstrainedLeftHanded =Matrix4x4.CreateConstrainedBillboardLeftHanded(objectPosition,cameraPosition,rotateAxis,cameraForwardVector,objectForwardVector);
Background and motivation
Matrix4x4 recently added APIs for left handed creation of Matrix4x4. Replacing another matrix implementation led me to nice the billboard APIs did not get left handed equivalents. In order to not confuse people about which functions are actually expecting a right handed system, we should add left handed versions for the billboard APIs.
API Proposal
API Usage