Table of Contents

Class Triangle3D

Namespace
SearchAThing.Sci
Assembly
netcore-sci.dll

helper class to hold triangle info, used in conjunction with LibTessDotNet methods.

public class Triangle3D
Inheritance
Triangle3D
Inherited Members

Constructors

Triangle3D(Vector3D, Vector3D, Vector3D)

public Triangle3D(Vector3D v1, Vector3D v2, Vector3D v3)

Parameters

v1 Vector3D
v2 Vector3D
v3 Vector3D

Properties

CS

(cached) on demand coordinate system with origin V1.

public CoordinateSystem3D CS { get; }

Property Value

CoordinateSystem3D

Segments

Retrieve (v1,v2), (v2,v3), (v3,v1) triangle segments.

public IEnumerable<Line3D> Segments { get; }

Property Value

IEnumerable<Line3D>

V1

public Vector3D V1 { get; }

Property Value

Vector3D

V2

public Vector3D V2 { get; }

Property Value

Vector3D

V3

public Vector3D V3 { get; }

Property Value

Vector3D

Methods

Contains(Vector3D)

States if a point is in this triangle.

public bool Contains(Vector3D point)

Parameters

point Vector3D

Returns

bool

Intersect(double, Triangle3D)

intersect this triangle with given other, returning intersection line ( eventyally a point line ) or null if no intersects at all.

public Line3D? Intersect(double tol, Triangle3D other)

Parameters

tol double
other Triangle3D

Returns

Line3D

IsParallelTo(double, Triangle3D)

states if this triangle parallel to other given.

public bool IsParallelTo(double tol, Triangle3D other)

Parameters

tol double
other Triangle3D

Returns

bool

RestrictTo(double, Line3D)

Restrict given this triangle coplanar line to be enclosed in the triangle shape.

public Line3D? RestrictTo(double tol, Line3D line)

Parameters

tol double

Length comparision tolerance.

line Line3D

This triangle coplanar line.

Returns

Line3D

Segment of line enclosed in this triangle.