// returns first two boundary edges, and count of total boundary edges public int vertex_boundary_edges(int vID, ref int e0, ref int e1) { int count = 0; foreach (int eid in Mesh.VtxEdgesItr(vID)) { if (edge_is_boundary(eid)) { if (count == 0) { e0 = eid; } else if (count == 1) { e1 = eid; } count++; } } return(count); }