Download

FMatrix construct

Hi! I want to translate this code to C++ UE code using FMatrix

	const Matrix4x4 CoordinateSystemTransformationMatrix = 
	{
		Vector4(-1,0,0,0) ,
		Vector4(0,0,-1,0) ,
		Vector4(0,-1,0,0) ,
		Vector4(0,0,0,1)
	};

how should I define the same in UE?

i’ve never had opportunity to use it, but it looks like there’s an FMatrix Constructor that takes an X/Y/Z/W FPlane, and FPlane is a 4-point Vector with X/Y/Z/W … so something like

FMatrix CoordinateSystemTransformationMatrix = FMatrix(
    FPlane(-1, 0, 0, 0),
    FPlane(0,0,-1,0),
    FPlane(0, -1, 0, 0),
    FPlane(0, 0, 0, 1)
);

THANKS!!!