Show / Hide Table of Contents

Class MeshGrid

Represents a 2d grid, where each cell corresponds to a face in a given mesh.

Inheritance
System.Object
DataDrivenGrid
MeshGrid
MeshPrismGrid
MobiusSquareGrid
VoronoiGrid
Implements
IGrid
Inherited Members
DataDrivenGrid.GetCellTypes()
DataDrivenGrid.GetCells()
DataDrivenGrid.GetCellType(Cell)
DataDrivenGrid.IsCellInGrid(Cell)
DataDrivenGrid.TryMove(Cell, CellDir, Cell, CellDir, Connection)
DataDrivenGrid.TryMoveByOffset(Cell, Vector3Int, Vector3Int, CellRotation, Cell, CellRotation)
DataDrivenGrid.ParallelTransport(IGrid, Cell, Cell, Cell, CellRotation, Cell, CellRotation)
DataDrivenGrid.GetCellDirs(Cell)
DataDrivenGrid.GetCellCorners(Cell)
DataDrivenGrid.FindBasicPath(Cell, Cell)
DataDrivenGrid.GetIndex(Cell)
DataDrivenGrid.GetCellByIndex(Int32)
DataDrivenGrid.GetBound()
DataDrivenGrid.GetBound(IEnumerable<Cell>)
DataDrivenGrid.BoundBy(IBound)
DataDrivenGrid.IntersectBounds(IBound, IBound)
DataDrivenGrid.UnionBounds(IBound, IBound)
DataDrivenGrid.GetCellsInBounds(IBound)
DataDrivenGrid.IsCellInBound(Cell, IBound)
DataDrivenGrid.GetCellCenter(Cell)
DataDrivenGrid.GetTRS(Cell)
DataDrivenGrid.GetDeformation(Cell)
DataDrivenGrid.FindGridSymmetry(ISet<Cell>, ISet<Cell>, Cell, CellRotation)
DataDrivenGrid.TryApplySymmetry(GridSymmetry, IBound, IBound)
DataDrivenGrid.TryApplySymmetry(GridSymmetry, Cell, Cell, CellRotation)
DataDrivenGrid.Moves
DataDrivenGrid.CellData
DataDrivenGrid.IsRepeating
DataDrivenGrid.IsOrientable
DataDrivenGrid.IsFinite
DataDrivenGrid.IsSingleCellType
DataDrivenGrid.Unbounded
DataDrivenGrid.Unwrapped
DataDrivenGrid.IndexCount
Namespace: Sylves
Assembly: Sylves.dll
Syntax
public class MeshGrid : DataDrivenGrid, IGrid

Constructors

MeshGrid(MeshData, MeshGridOptions)

Declaration
public MeshGrid(MeshData meshData, MeshGridOptions meshGridOptions = null)
Parameters
Type Name Description
MeshData meshData
MeshGridOptions meshGridOptions

Fields

is2d

Declaration
protected bool is2d
Field Value
Type Description
System.Boolean

meshData

Declaration
protected readonly MeshData meshData
Field Value
Type Description
MeshData

Properties

CoordinateDimension

Declaration
public override int CoordinateDimension { get; }
Property Value
Type Description
System.Int32
Overrides
DataDrivenGrid.CoordinateDimension

Is2d

Declaration
public override bool Is2d { get; }
Property Value
Type Description
System.Boolean
Overrides
DataDrivenGrid.Is2d

Is3d

Declaration
public override bool Is3d { get; }
Property Value
Type Description
System.Boolean
Overrides
DataDrivenGrid.Is3d

IsPlanar

Declaration
public override bool IsPlanar { get; }
Property Value
Type Description
System.Boolean
Overrides
DataDrivenGrid.IsPlanar

Methods

ComputeBounds(Cell)

Declaration
protected virtual (Vector3, Vector3) ComputeBounds(Cell cell)
Parameters
Type Name Description
Cell cell
Returns
Type Description
System.ValueTuple<Vector3, Vector3>

FindCell(Matrix4x4, out Cell, out CellRotation)

Declaration
public override bool FindCell(Matrix4x4 matrix, out Cell cell, out CellRotation rotation)
Parameters
Type Name Description
Matrix4x4 matrix
Cell cell
CellRotation rotation
Returns
Type Description
System.Boolean
Overrides
DataDrivenGrid.FindCell(Matrix4x4, out Cell, out CellRotation)

FindCell(Vector3, out Cell)

Declaration
public override bool FindCell(Vector3 position, out Cell cell)
Parameters
Type Name Description
Vector3 position
Cell cell
Returns
Type Description
System.Boolean
Overrides
DataDrivenGrid.FindCell(Vector3, out Cell)

GetCellCorner(Cell, CellCorner)

Declaration
public override Vector3 GetCellCorner(Cell cell, CellCorner corner)
Parameters
Type Name Description
Cell cell
CellCorner corner
Returns
Type Description
Vector3
Overrides
DataDrivenGrid.GetCellCorner(Cell, CellCorner)

GetCellsIntersectsApprox(Vector3, Vector3)

Declaration
public override IEnumerable<Cell> GetCellsIntersectsApprox(Vector3 min, Vector3 max)
Parameters
Type Name Description
Vector3 min
Vector3 max
Returns
Type Description
System.Collections.Generic.IEnumerable<Cell>
Overrides
DataDrivenGrid.GetCellsIntersectsApprox(Vector3, Vector3)

GetDual()

Declaration
public override IDualMapping GetDual()
Returns
Type Description
IDualMapping
Overrides
DataDrivenGrid.GetDual()

GetFaceIndices(Cell)

Declaration
public IReadOnlyList<int> GetFaceIndices(Cell cell)
Parameters
Type Name Description
Cell cell
Returns
Type Description
System.Collections.Generic.IReadOnlyList<System.Int32>

GetMeshData(Cell, out MeshData, out Matrix4x4)

Declaration
public override void GetMeshData(Cell cell, out MeshData meshData, out Matrix4x4 transform)
Parameters
Type Name Description
Cell cell
MeshData meshData
Matrix4x4 transform
Overrides
DataDrivenGrid.GetMeshData(Cell, out MeshData, out Matrix4x4)

GetPolygon(Cell, out Vector3[], out Matrix4x4)

Declaration
public override void GetPolygon(Cell cell, out Vector3[] vertices, out Matrix4x4 transform)
Parameters
Type Name Description
Cell cell
Vector3[] vertices
Matrix4x4 transform
Overrides
DataDrivenGrid.GetPolygon(Cell, out Vector3[], out Matrix4x4)

GetTriangleMesh(Cell)

Declaration
public override IEnumerable<(Vector3, Vector3, Vector3, CellDir)> GetTriangleMesh(Cell cell)
Parameters
Type Name Description
Cell cell
Returns
Type Description
System.Collections.Generic.IEnumerable<System.ValueTuple<Vector3, Vector3, Vector3, CellDir>>
Overrides
DataDrivenGrid.GetTriangleMesh(Cell)

IsPointInCell(Vector3, Cell)

Declaration
protected virtual bool IsPointInCell(Vector3 position, Cell cell)
Parameters
Type Name Description
Vector3 position
Cell cell
Returns
Type Description
System.Boolean

Raycast(Vector3, Vector3, Single)

Declaration
public override IEnumerable<RaycastInfo> Raycast(Vector3 origin, Vector3 direction, float maxDistance = InfinityF)
Parameters
Type Name Description
Vector3 origin
Vector3 direction
System.Single maxDistance
Returns
Type Description
System.Collections.Generic.IEnumerable<RaycastInfo>
Overrides
DataDrivenGrid.Raycast(Vector3, Vector3, Single)

RaycastCell(Cell, Vector3, Vector3)

Declaration
protected virtual Nullable<RaycastInfo> RaycastCell(Cell cell, Vector3 rayOrigin, Vector3 direction)
Parameters
Type Name Description
Cell cell
Vector3 rayOrigin
Vector3 direction
Returns
Type Description
System.Nullable<RaycastInfo>

Implements

IGrid
In This Article
Back to top Generated by DocFX