Skip to content

Instantly share code, notes, and snippets.

/ConvertTo.cpp Secret

Created September 18, 2016 21:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/39664aeb444ee0f2eef314b15467964c to your computer and use it in GitHub Desktop.
Save anonymous/39664aeb444ee0f2eef314b15467964c to your computer and use it in GitHub Desktop.
using Microsoft.Xna.Framework;
namespace Physics
{
public static class ConvertTo
{
public static Matrix XNAMatrix(BEPUutilities.Matrix bepuMatrix)
{
Matrix xnaMatrix = new Matrix();
xnaMatrix.M11 = bepuMatrix.M11;
xnaMatrix.M12 = bepuMatrix.M12;
xnaMatrix.M13 = bepuMatrix.M13;
xnaMatrix.M14 = bepuMatrix.M14;
xnaMatrix.M21 = bepuMatrix.M21;
xnaMatrix.M22 = bepuMatrix.M22;
xnaMatrix.M23 = bepuMatrix.M23;
xnaMatrix.M24 = bepuMatrix.M24;
xnaMatrix.M31 = bepuMatrix.M31;
xnaMatrix.M32 = bepuMatrix.M32;
xnaMatrix.M33 = bepuMatrix.M33;
xnaMatrix.M34 = bepuMatrix.M34;
xnaMatrix.M41 = bepuMatrix.M41;
xnaMatrix.M42 = bepuMatrix.M42;
xnaMatrix.M43 = bepuMatrix.M43;
xnaMatrix.M44 = bepuMatrix.M44;
return xnaMatrix;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment