コード例 #1
0
        /// <summary>
        /// Converts a <see cref="EvergineMatrix4x4"/> into a remote <see cref="ARRMatrix4x4"/>.
        /// </summary>
        /// <param name="input">The matrix to be converted.</param>
        /// <param name="output">The converted matrix.</param>
        public static void ToRemote(this EvergineMatrix4x4 input, out ARRMatrix4x4 output)
        {
            var col0 = new Float4(input.M11, input.M12, input.M13, input.M14);
            var col1 = new Float4(input.M21, input.M22, input.M23, input.M24);
            var col2 = new Float4(input.M31, input.M32, input.M33, input.M34);
            var col3 = new Float4(input.M41, input.M42, input.M43, input.M44);

            output = new ARRMatrix4x4(col0, col1, col2, col3);
        }
コード例 #2
0
        /// <summary>
        /// Converts a remote <see cref="ARRMatrix4x4"/> into a <see cref="EvergineMatrix4x4"/>.
        /// </summary>
        /// <param name="input">The matrix to be converted.</param>
        /// <param name="output">The converted matrix.</param>
        public static void ToEvergine(this ARRMatrix4x4 input, out EvergineMatrix4x4 output)
        {
            output.M11 = input.Column0.X;
            output.M12 = input.Column0.Y;
            output.M13 = input.Column0.Z;
            output.M14 = input.Column0.W;

            output.M21 = input.Column1.X;
            output.M22 = input.Column1.Y;
            output.M23 = input.Column1.Z;
            output.M24 = input.Column1.W;

            output.M31 = input.Column2.X;
            output.M32 = input.Column2.Y;
            output.M33 = input.Column2.Z;
            output.M34 = input.Column2.W;

            output.M41 = input.Column3.X;
            output.M42 = input.Column3.Y;
            output.M43 = input.Column3.Z;
            output.M44 = input.Column3.W;
        }
コード例 #3
0
 public static extern arr.Result RemoteRendering_fov_to_projection_matrix([MarshalAs(UnmanagedType.Struct)] ref arr.CameraFov fov, float nearPlane, float farPlane, arr.DepthConvention depthConvention, [MarshalAs(UnmanagedType.Struct)] out arr.Matrix4x4 projection);
コード例 #4
0
 public static extern arr.Result RemoteRendering_fov_from_projection_matrix([MarshalAs(UnmanagedType.Struct)] ref arr.Matrix4x4 projection, [MarshalAs(UnmanagedType.Struct)] out arr.CameraFov fov);
コード例 #5
0
 /// <summary>
 /// Converts a remote <see cref="ARRMatrix4x4"/> into a <see cref="EvergineMatrix4x4"/>.
 /// </summary>
 /// <param name="input">The matrix to be converted.</param>
 /// <returns>The converted matrix.</returns>
 public static EvergineMatrix4x4 ToEvergine(this ARRMatrix4x4 input)
 {
     input.ToEvergine(out EvergineMatrix4x4 output);
     return(output);
 }