コード例 #1
0
 public LdrBuilder Line(string name, Colour32 colour, float width, bool smooth, IEnumerable <v4> points)
 {
     if (!points.Any())
     {
         return(this);
     }
     return(Append("*LineStrip ", name, " ", colour, " {", Ldr.Width(width), Ldr.Smooth(smooth), points.Select(x => Ldr.Vec3(x)), "}\n"));
 }
コード例 #2
0
        public LdrBuilder Arrow(string name, Colour32 colour, Ldr.EArrowType type, float width, bool smooth, Func <int, v4?> points)
        {
            int idx = 0;

            Append("*Arrow ", name, " ", colour, " {");
            for (v4?pt; (pt = points(idx++)) != null;)
            {
                Append(Ldr.Vec3(pt.Value));
            }
            Append(Ldr.Width(width), Ldr.Smooth(smooth), type.ToString(), "}\n");
            return(this);
        }
コード例 #3
0
        public LdrBuilder Line(string name, Colour32 colour, float width, bool smooth, Func <int, v4?> points)
        {
            int idx = 0;

            Append("*LineStrip ", name, " ", colour, " {", Ldr.Width(width), Ldr.Smooth(smooth));
            for (v4?pt; (pt = points(idx++)) != null;)
            {
                Append(Ldr.Vec3(pt.Value));
            }
            Append("}\n");
            return(this);
        }
コード例 #4
0
 public LdrBuilder Ribbon(string name, Colour32 colour, IEnumerable <v4> points, AxisId axis_id, float width, bool smooth, m4x4?o2w = null)
 {
     return(Append("*Ribbon ", name, " ", colour, " {", points, " ", axis_id, Ldr.Width(width), Ldr.Smooth(smooth), Ldr.Transform(o2w), "}\n"));
 }
コード例 #5
0
 public LdrBuilder Arrow(string name, Colour32 colour, Ldr.EArrowType type, float width, bool smooth, IEnumerable <v4> points)
 {
     if (!points.Any())
     {
         return(this);
     }
     return(Append("*Arrow ", name, " ", colour, " {", type.ToString(), points.Select(x => Ldr.Vec3(x)), Ldr.Width(width), Ldr.Smooth(smooth), "}\n"));
 }