aboutsummaryrefslogtreecommitdiff
path: root/path/builder.mli
blob: d99e0b2cb49c99e4c2338695c15b631169a05ce0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
(** Signature for points *)
module type P = sig
  type t

  val get_coord : t -> Gg.v2
end


module Make(P:P) : sig

  type t

  (** Create an empty path *)
  val empty: t

  val add_point
    : P.t -> t -> t

  (** Replace the last alement in the path by the one given in parameter *)
  val replace_last
    : P.t -> t -> t

  (** Retrieve the last element, if any *)
  val peek 
    : t -> P.t option

  (** Retrieve the last element, if any *)
  val peek2
    : t -> (P.t * P.t) option

  val get
    : t -> P.t list * Shapes.Bezier.t list
end