MeshLib Java Docs
Loading...
Searching...
No Matches
Inheritance diagram for meshlib.Matrix2b:

Public Member Functions

 Matrix2b (java.lang.foreign.MemorySegment segment, java.lang.Object owner)
Matrix2b copy ()
void set (Matrix2b other)
meshlib.Vector2b x ()
void setX (meshlib.Vector2b value)
meshlib.Vector2b y ()
void setY (meshlib.Vector2b value)
 Matrix2b ()
 Matrix2b (meshlib.Vector2b x, meshlib.Vector2b y)
meshlib.Vector2b index (int row)
meshlib.Vector2b index_mut (int row)
meshlib.Vector2b col (int i)
boolean trace ()
boolean normSq ()
double norm ()
boolean det ()
meshlib.Matrix2b transposed ()
Public Member Functions inherited from meshlib.CppStruct
final java.lang.foreign.MemorySegment rawPointer ()

Static Public Member Functions

static meshlib.Matrix2b zero ()
static meshlib.Matrix2b identity ()
static meshlib.Matrix2b scale (boolean s)
static meshlib.Matrix2b scale (boolean sx, boolean sy)
static meshlib.Matrix2b scale (meshlib.Vector2b s)
static meshlib.Matrix2b fromRows (meshlib.Vector2b x, meshlib.Vector2b y)
static meshlib.Matrix2b fromColumns (meshlib.Vector2b x, meshlib.Vector2b y)

Static Public Attributes

static final java.lang.foreign.StructLayout LAYOUT = meshlib.Ffi.structLayout(new java.lang.String[]{"x", "y"}, new java.lang.foreign.MemoryLayout[]{meshlib.Vector2b.LAYOUT, meshlib.Vector2b.LAYOUT})
static final long OFF_x = LAYOUT.byteOffset(java.lang.foreign.MemoryLayout.PathElement.groupElement("x"))
static final long OFF_y = LAYOUT.byteOffset(java.lang.foreign.MemoryLayout.PathElement.groupElement("y"))

Additional Inherited Members

Protected Member Functions inherited from meshlib.CppStruct
 CppStruct (java.lang.foreign.MemorySegment segment, java.lang.Object owner)
Protected Attributes inherited from meshlib.CppStruct
final java.lang.foreign.MemorySegment segment

Detailed Description

arbitrary 2x2 matrix Generated from class MR::Matrix2b.

Has the same layout as the C++ struct, the fields are accessed in place in native memory.

Constructor & Destructor Documentation

◆ Matrix2b() [1/3]

meshlib.Matrix2b.Matrix2b ( java.lang.foreign.MemorySegment segment,
java.lang.Object owner )

Wraps a segment holding the struct. owner is kept alive as long as this wrapper is. Not for normal use.

◆ Matrix2b() [2/3]

meshlib.Matrix2b.Matrix2b ( )

Constructs an empty (default-constructed) instance.

Calls MR_Matrix2b_DefaultConstruct().

◆ Matrix2b() [3/3]

meshlib.Matrix2b.Matrix2b ( meshlib.Vector2b x,
meshlib.Vector2b y )

initializes matrix from its 2 rows Generated from constructor MR::Matrix2b::Matrix2b. The reference to the parameter x might be preserved in the constructed object. The reference to the parameter y might be preserved in the constructed object.

Calls MR_Matrix2b_Construct().

Member Function Documentation

◆ col()

meshlib.Vector2b meshlib.Matrix2b.col ( int i)

column access Generated from method MR::Matrix2b::col.

Calls MR_Matrix2b_col().

◆ copy()

Matrix2b meshlib.Matrix2b.copy ( )

A copy of the struct, in its own memory.

◆ det()

boolean meshlib.Matrix2b.det ( )

computes determinant of the matrix Generated from method MR::Matrix2b::det.

Calls MR_Matrix2b_det().

◆ fromColumns()

meshlib.Matrix2b meshlib.Matrix2b.fromColumns ( meshlib.Vector2b x,
meshlib.Vector2b y )
static

constructs a matrix from its 2 columns; use this method to get the matrix that transforms basis vectors ( plusX, plusY ) into vectors ( x, y ) respectively Generated from method MR::Matrix2b::fromColumns.

Calls MR_Matrix2b_fromColumns().

◆ fromRows()

meshlib.Matrix2b meshlib.Matrix2b.fromRows ( meshlib.Vector2b x,
meshlib.Vector2b y )
static

constructs a matrix from its 2 rows Generated from method MR::Matrix2b::fromRows.

Calls MR_Matrix2b_fromRows().

◆ identity()

meshlib.Matrix2b meshlib.Matrix2b.identity ( )
static

Generated from method MR::Matrix2b::identity.

Calls MR_Matrix2b_identity().

◆ index()

meshlib.Vector2b meshlib.Matrix2b.index ( int row)

row access Generated from method MR::Matrix2b::operator[].

Calls MR_Matrix2b_index().

◆ index_mut()

meshlib.Vector2b meshlib.Matrix2b.index_mut ( int row)

Generated from method MR::Matrix2b::operator[].

Calls MR_Matrix2b_index_mut().

◆ norm()

double meshlib.Matrix2b.norm ( )

Generated from method MR::Matrix2b::norm.

Calls MR_Matrix2b_norm().

◆ normSq()

boolean meshlib.Matrix2b.normSq ( )

compute sum of squared matrix elements Generated from method MR::Matrix2b::normSq.

Calls MR_Matrix2b_normSq().

◆ scale() [1/3]

meshlib.Matrix2b meshlib.Matrix2b.scale ( boolean s)
static

returns a matrix that scales uniformly Generated from method MR::Matrix2b::scale.

Calls MR_Matrix2b_scale_1_bool().

◆ scale() [2/3]

meshlib.Matrix2b meshlib.Matrix2b.scale ( boolean sx,
boolean sy )
static

returns a matrix that has its own scale along each axis Generated from method MR::Matrix2b::scale.

Calls MR_Matrix2b_scale_2().

◆ scale() [3/3]

meshlib.Matrix2b meshlib.Matrix2b.scale ( meshlib.Vector2b s)
static

Generated from method MR::Matrix2b::scale.

Calls MR_Matrix2b_scale_1_MR_Vector2b().

◆ set()

void meshlib.Matrix2b.set ( Matrix2b other)

Overwrites the contents with those of another struct.

◆ setX()

void meshlib.Matrix2b.setX ( meshlib.Vector2b value)

◆ setY()

void meshlib.Matrix2b.setY ( meshlib.Vector2b value)

◆ trace()

boolean meshlib.Matrix2b.trace ( )

computes trace of the matrix Generated from method MR::Matrix2b::trace.

Calls MR_Matrix2b_trace().

◆ transposed()

meshlib.Matrix2b meshlib.Matrix2b.transposed ( )

computes transposed matrix Generated from method MR::Matrix2b::transposed.

Calls MR_Matrix2b_transposed().

◆ x()

meshlib.Vector2b meshlib.Matrix2b.x ( )

rows, identity matrix by default

◆ y()

meshlib.Vector2b meshlib.Matrix2b.y ( )

◆ zero()

meshlib.Matrix2b meshlib.Matrix2b.zero ( )
static

Generated from method MR::Matrix2b::zero.

Calls MR_Matrix2b_zero().

Member Data Documentation

◆ LAYOUT

final java.lang.foreign.StructLayout meshlib.Matrix2b.LAYOUT = meshlib.Ffi.structLayout(new java.lang.String[]{"x", "y"}, new java.lang.foreign.MemoryLayout[]{meshlib.Vector2b.LAYOUT, meshlib.Vector2b.LAYOUT})
static

The native layout of the struct.

◆ OFF_x

final long meshlib.Matrix2b.OFF_x = LAYOUT.byteOffset(java.lang.foreign.MemoryLayout.PathElement.groupElement("x"))
static

◆ OFF_y

final long meshlib.Matrix2b.OFF_y = LAYOUT.byteOffset(java.lang.foreign.MemoryLayout.PathElement.groupElement("y"))
static

The documentation for this class was generated from the following file: