Files
Triangle.NET/Triangle.NET/Triangle/Geometry/ITriangle.cs
T
SND\wo80_cp c19681b2dd Removed support for triangle attributes,
Added triangle region marker

git-svn-id: https://triangle.svn.codeplex.com/svn@71645 0e2699bc-83d4-4a8f-98e7-55e24ab8c7a5
2013-01-21 14:59:13 +00:00

88 lines
2.5 KiB
C#

// -----------------------------------------------------------------------
// <copyright file="ITriangle.cs" company="">
// Triangle.NET code by Christian Woltering, http://triangle.codeplex.com/
// </copyright>
// -----------------------------------------------------------------------
namespace TriangleNet.Geometry
{
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using TriangleNet.Data;
/// <summary>
/// Triangle interface.
/// </summary>
public interface ITriangle
{
/// <summary>
/// The triangle id.
/// </summary>
int ID { get; }
/// <summary>
/// First vertex id of the triangle.
/// </summary>
int P0 { get; }
/// <summary>
/// Second vertex id of the triangle.
/// </summary>
int P1 { get; }
/// <summary>
/// Third vertex id of the triangle.
/// </summary>
int P2 { get; }
/// <summary>
/// Gets a triangles vertex.
/// </summary>
/// <param name="index">The vertex index (0, 1 or 2).</param>
/// <returns>The vertex of the specified corner index.</returns>
Vertex GetVertex(int index);
/// <summary>
/// True if the triangle implementation contains neighbor information.
/// </summary>
bool SupportsNeighbors { get; }
/// <summary>
/// First neighbor.
/// </summary>
int N0 { get; }
/// <summary>
/// Second neighbor.
/// </summary>
int N1 { get; }
/// <summary>
/// Third neighbor.
/// </summary>
int N2 { get; }
/// <summary>
/// Gets a triangles neighbor.
/// </summary>
/// <param name="index">The vertex index (0, 1 or 2).</param>
/// <returns>The neigbbor opposite of vertex with given index.</returns>
ITriangle GetNeighbor(int index);
/// <summary>
/// Gets a triangles segment.
/// </summary>
/// <param name="index">The vertex index (0, 1 or 2).</param>
/// <returns>The segment opposite of vertex with given index.</returns>
Segment GetSegment(int index);
/// <summary>
/// Triangle area constraint.
/// </summary>
double Area { get; }
/// <summary>
/// Region ID the triangle belongs to.
/// </summary>
int Region { get; }
}
}