Class DGraph
Base class for Arbitrary-Topology Graphs. Similar structure to topology parts of DMesh3.
Each vertex can be connected to an arbitrary number of edges.
Each edge can have an integer GroupID.
See DGraph2 and DGraph3 for 3d implementations.
Use DGraphN if you would like a topology-only graph.
You cannot instantiate DGraph directly.
Namespace: g3
Assembly: cs.temp.dll.dll
Syntax
public abstract class DGraph
Constructors
DGraph()
Declaration
Fields
DuplicateEdgeID
Declaration
public const int DuplicateEdgeID = -2
Field Value
edges
Declaration
protected DVector<int> edges
Field Value
edges_refcount
Declaration
protected RefCountVector edges_refcount
Field Value
InvalidEdge3
Declaration
public static readonly Index3i InvalidEdge3
Field Value
InvalidEdgeV
Declaration
public static readonly Index2i InvalidEdgeV
Field Value
InvalidID
Declaration
public const int InvalidID = -1
Field Value
max_group_id
Declaration
protected int max_group_id
Field Value
shape_timestamp
Declaration
protected int shape_timestamp
Field Value
timestamp
Declaration
Field Value
vertex_edges
Declaration
protected DVector<List<int>> vertex_edges
Field Value
vertices_refcount
Declaration
protected RefCountVector vertices_refcount
Field Value
Properties
EdgeCount
Declaration
public int EdgeCount { get; }
Property Value
IsCompact
Declaration
public bool IsCompact { get; }
Property Value
IsCompactV
Declaration
public bool IsCompactV { get; }
Property Value
MaxEdgeID
Declaration
public int MaxEdgeID { get; }
Property Value
MaxGroupID
Declaration
public int MaxGroupID { get; }
Property Value
MaxVertexID
Declaration
public int MaxVertexID { get; }
Property Value
ShapeTimestamp
Declaration
public int ShapeTimestamp { get; }
Property Value
Timestamp
Declaration
public int Timestamp { get; }
Property Value
VertexCount
Declaration
public int VertexCount { get; }
Property Value
Methods
add_edge(Int32, Int32, Int32)
Declaration
protected int add_edge(int a, int b, int gid)
Parameters
Returns
AllocateEdgeGroup()
Declaration
public int AllocateEdgeGroup()
Returns
append_new_split_vertex(Int32, Int32)
Declaration
protected virtual int append_new_split_vertex(int a, int b)
Parameters
Returns
append_vertex_internal()
Declaration
protected int append_vertex_internal()
Returns
AppendEdge(Index2i, Int32)
Declaration
public int AppendEdge(Index2i ev, int gid = -1)
Parameters
Returns
AppendEdge(Int32, Int32, Int32)
Declaration
public int AppendEdge(int v0, int v1, int gid = -1)
Parameters
Returns
CheckValidity(DGraph.FailMode)
Declaration
public virtual bool CheckValidity(DGraph.FailMode eFailMode = DGraph.FailMode.Throw)
Parameters
Returns
CollapseEdge(Int32, Int32, out DGraph.EdgeCollapseInfo)
Declaration
public MeshResult CollapseEdge(int vKeep, int vRemove, out DGraph.EdgeCollapseInfo collapse)
Parameters
Returns
debug_check_is_edge(Int32)
Declaration
public void debug_check_is_edge(int e)
Parameters
Type |
Name |
Description |
Int32 |
e |
|
debug_check_is_vertex(Int32)
Declaration
public void debug_check_is_vertex(int v)
Parameters
Type |
Name |
Description |
Int32 |
v |
|
edge_has_v(Int32, Int32)
Declaration
protected bool edge_has_v(int eid, int vid)
Parameters
Returns
edge_other_v(Int32, Int32)
Declaration
protected int edge_other_v(int eID, int vID)
Parameters
Returns
EdgeIndices()
Declaration
public IEnumerable<int> EdgeIndices()
Returns
Edges()
Declaration
public IEnumerable<Index3i> Edges()
Returns
FindEdge(Int32, Int32)
Declaration
public int FindEdge(int vA, int vB)
Parameters
Returns
GetEdge(Int32)
Declaration
public Index3i GetEdge(int eID)
Parameters
Type |
Name |
Description |
Int32 |
eID |
|
Returns
GetEdgeGroup(Int32)
Declaration
public int GetEdgeGroup(int eid)
Parameters
Type |
Name |
Description |
Int32 |
eid |
|
Returns
GetEdgeV(Int32)
Declaration
public Index2i GetEdgeV(int eID)
Parameters
Type |
Name |
Description |
Int32 |
eID |
|
Returns
GetMaxVtxEdgeCount()
Declaration
public int GetMaxVtxEdgeCount()
Returns
GetVtxEdgeCount(Int32)
Declaration
public int GetVtxEdgeCount(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns
GetVtxEdges(Int32)
Declaration
public ReadOnlyCollection<int> GetVtxEdges(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns
Type |
Description |
ReadOnlyCollection<Int32> |
|
IsBoundaryVertex(Int32)
Declaration
public bool IsBoundaryVertex(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns
IsEdge(Int32)
Declaration
public bool IsEdge(int eID)
Parameters
Type |
Name |
Description |
Int32 |
eID |
|
Returns
IsJunctionVertex(Int32)
Declaration
public bool IsJunctionVertex(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns
IsRegularVertex(Int32)
Declaration
public bool IsRegularVertex(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns
IsVertex(Int32)
Declaration
public bool IsVertex(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns
RemoveEdge(Int32, Boolean)
Declaration
public MeshResult RemoveEdge(int eID, bool bRemoveIsolatedVertices)
Parameters
Type |
Name |
Description |
Int32 |
eID |
|
Boolean |
bRemoveIsolatedVertices |
|
Returns
RemoveVertex(Int32, Boolean)
Declaration
public MeshResult RemoveVertex(int vid, bool bRemoveIsolatedVertices)
Parameters
Type |
Name |
Description |
Int32 |
vid |
|
Boolean |
bRemoveIsolatedVertices |
|
Returns
replace_edge_vertex(Int32, Int32, Int32)
Declaration
protected int replace_edge_vertex(int eID, int vOld, int vNew)
Parameters
Returns
SetEdgeGroup(Int32, Int32)
Declaration
public void SetEdgeGroup(int eid, int group_id)
Parameters
SplitEdge(Int32, out DGraph.EdgeSplitInfo)
Declaration
public MeshResult SplitEdge(int eab, out DGraph.EdgeSplitInfo split)
Parameters
Returns
SplitEdge(Int32, Int32, out DGraph.EdgeSplitInfo)
Declaration
public MeshResult SplitEdge(int vA, int vB, out DGraph.EdgeSplitInfo split)
Parameters
Returns
subclass_validity_checks(Action<Boolean>)
Declaration
protected virtual void subclass_validity_checks(Action<bool> CheckOrFailF)
Parameters
updateTimeStamp(Boolean)
Declaration
protected void updateTimeStamp(bool bShapeChange)
Parameters
Type |
Name |
Description |
Boolean |
bShapeChange |
|
VertexIndices()
Declaration
public IEnumerable<int> VertexIndices()
Returns
VtxEdgesItr(Int32)
Declaration
public IEnumerable<int> VtxEdgesItr(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns
VtxVerticesItr(Int32)
Declaration
public IEnumerable<int> VtxVerticesItr(int vID)
Parameters
Type |
Name |
Description |
Int32 |
vID |
|
Returns