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

Public Member Functions

 Vector2d (java.lang.foreign.MemorySegment segment, java.lang.Object owner)
Vector2d copy ()
void set (Vector2d other)
double x ()
void setX (double value)
double y ()
void setY (double value)
 Vector2d ()
 Vector2d (meshlib.NoInit _1)
 Vector2d (double x, double y)
double index (int e)
java.lang.foreign.MemorySegment index_mut (int e)
double lengthSq ()
double length ()
meshlib.Vector2d normalized ()
meshlib.Vector2d furthestBasisVector ()
meshlib.Vector2d perpendicular ()
boolean isFinite ()
Public Member Functions inherited from meshlib.CppStruct
final java.lang.foreign.MemorySegment rawPointer ()

Static Public Member Functions

static meshlib.Vector2d diagonal (double a)
static meshlib.Vector2d plusX ()
static meshlib.Vector2d plusY ()
static meshlib.Vector2d minusX ()
static meshlib.Vector2d minusY ()
static int elements ()

Static Public Attributes

static final java.lang.foreign.StructLayout LAYOUT = meshlib.Ffi.structLayout(new java.lang.String[]{"x", "y"}, new java.lang.foreign.MemoryLayout[]{java.lang.foreign.ValueLayout.JAVA_DOUBLE, java.lang.foreign.ValueLayout.JAVA_DOUBLE})
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

Generated from class MR::Vector2d.

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

Constructor & Destructor Documentation

◆ Vector2d() [1/4]

meshlib.Vector2d.Vector2d ( 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.

◆ Vector2d() [2/4]

meshlib.Vector2d.Vector2d ( )

Constructs an empty (default-constructed) instance.

Calls MR_Vector2d_DefaultConstruct().

◆ Vector2d() [3/4]

meshlib.Vector2d.Vector2d ( meshlib.NoInit _1)

Generated from constructor MR::Vector2d::Vector2d. The reference to the parameter _1 might be preserved in the constructed object.

Calls MR_Vector2d_Construct_1().

◆ Vector2d() [4/4]

meshlib.Vector2d.Vector2d ( double x,
double y )

Generated from constructor MR::Vector2d::Vector2d.

Calls MR_Vector2d_Construct_2().

Member Function Documentation

◆ copy()

Vector2d meshlib.Vector2d.copy ( )

A copy of the struct, in its own memory.

◆ diagonal()

meshlib.Vector2d meshlib.Vector2d.diagonal ( double a)
static

Generated from method MR::Vector2d::diagonal.

Calls MR_Vector2d_diagonal().

◆ elements()

int meshlib.Vector2d.elements ( )
static

Returns a pointer to a member variable of class MR::Vector2d named elements.

Calls MR_Vector2d_Get_elements().

◆ furthestBasisVector()

meshlib.Vector2d meshlib.Vector2d.furthestBasisVector ( )

Generated from method MR::Vector2d::furthestBasisVector.

Calls MR_Vector2d_furthestBasisVector().

◆ index()

double meshlib.Vector2d.index ( int e)

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

Calls MR_Vector2d_index().

◆ index_mut()

java.lang.foreign.MemorySegment meshlib.Vector2d.index_mut ( int e)

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

Calls MR_Vector2d_index_mut(). Some types are raw C types, see the C bindings for the details.

◆ isFinite()

boolean meshlib.Vector2d.isFinite ( )

Generated from method MR::Vector2d::isFinite.

Calls MR_Vector2d_isFinite().

◆ length()

double meshlib.Vector2d.length ( )

Generated from method MR::Vector2d::length.

Calls MR_Vector2d_length().

◆ lengthSq()

double meshlib.Vector2d.lengthSq ( )

Generated from method MR::Vector2d::lengthSq.

Calls MR_Vector2d_lengthSq().

◆ minusX()

meshlib.Vector2d meshlib.Vector2d.minusX ( )
static

Generated from method MR::Vector2d::minusX.

Calls MR_Vector2d_minusX().

◆ minusY()

meshlib.Vector2d meshlib.Vector2d.minusY ( )
static

Generated from method MR::Vector2d::minusY.

Calls MR_Vector2d_minusY().

◆ normalized()

meshlib.Vector2d meshlib.Vector2d.normalized ( )

Generated from method MR::Vector2d::normalized.

Calls MR_Vector2d_normalized().

◆ perpendicular()

meshlib.Vector2d meshlib.Vector2d.perpendicular ( )

returns same length vector orthogonal to this (rotated 90 degrees counter-clockwise) Generated from method MR::Vector2d::perpendicular.

Calls MR_Vector2d_perpendicular().

◆ plusX()

meshlib.Vector2d meshlib.Vector2d.plusX ( )
static

Generated from method MR::Vector2d::plusX.

Calls MR_Vector2d_plusX().

◆ plusY()

meshlib.Vector2d meshlib.Vector2d.plusY ( )
static

Generated from method MR::Vector2d::plusY.

Calls MR_Vector2d_plusY().

◆ set()

void meshlib.Vector2d.set ( Vector2d other)

Overwrites the contents with those of another struct.

◆ setX()

void meshlib.Vector2d.setX ( double value)

◆ setY()

void meshlib.Vector2d.setY ( double value)

◆ x()

double meshlib.Vector2d.x ( )

◆ y()

double meshlib.Vector2d.y ( )

Member Data Documentation

◆ LAYOUT

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

The native layout of the struct.

◆ OFF_x

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

◆ OFF_y

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

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