Edit

Share via


Matrix4x4.WithElement(Int32, Int32, Single) Method

Definition

Creates a new Matrix4x4 with the element at the specified row and column set to the given value and the remaining elements set to the same value as that in the current matrix.

public:
 System::Numerics::Matrix4x4 WithElement(int row, int column, float value);
public readonly System.Numerics.Matrix4x4 WithElement(int row, int column, float value);
member this.WithElement : int * int * single -> System.Numerics.Matrix4x4
Public Function WithElement (row As Integer, column As Integer, value As Single) As Matrix4x4

Parameters

row
Int32

The index of the row containing the element to replace.

column
Int32

The index of the column containing the element to replace.

value
Single

The value to assign to the element at index: [row, column].

Returns

A Matrix4x4 with the value of the element at index: [row, column] set to value and the remaining elements set to the same value as that in the current matrix.

Exceptions

row was less than zero or greater than or equal to the number of rows (4).

-or-

column was less than zero or greater than or equal to the number of columns (4).

Applies to