using System.Collections.Generic; using OpenTK; using OpenTK.Graphics.OpenGL4; using SM.OGL.Mesh; namespace SM2D.Object { /// /// Allows different type of lines. /// public enum PolyLineType { /// /// Those lines are not connected to each other. /// Every two points starts a new line. /// NotConnected = 1, /// /// Those lines are connected with each other, but don't connect the start and the end. /// Connected = 3, /// /// Those lines are connected and they connect start and end. /// ConnectedLoop = 2 } /// /// Creates new poly line. /// public class PolyLine : Polygon, ILineMesh { /// /// Creates a new polyline by using . /// /// /// public PolyLine(ICollection vertices, PolyLineType lineType = PolyLineType.NotConnected) : base(vertices) { UVs.Active = false; PrimitiveType = (PrimitiveType)lineType; } /// /// Creates a new polyline by using . /// /// /// public PolyLine(ICollection vertices, PolyLineType lineType = PolyLineType.NotConnected) : base(vertices) { UVs.Active = false; PrimitiveType = (PrimitiveType)lineType; } } }