Commits

bergsoe committed 08359e1

SE2.make_angle constructor.

Comments (0)

Files changed (2)

src/PaplTransform.ml

     in (x', y', z')
 
   let interpolate q0 q1 =
-    let lerp q0 q1 s =
-      unit (map2 (PaplInterpolate.Float.flip_interpolate s) q0 q1) in
+    let lerp q0 q1 s = unit
+      (map2
+         (fun a b -> PaplInterpolate.Float.interpolate a b s)
+         q0 q1)
+    in
     let slerp ca q0 q1 =
       let eps = 1e-7 in
         if is_zero (1.0 -. ca) eps then lerp q0 q1
 
   let make_pos_angle pos angle = make pos (SO2.rotate angle)
 
+  let make_angle angle = make_rotate (SO2.rotate angle)
+
   module Sampler = struct
     type box_t = vec * vec
 

src/PaplTransform.mli

   include SE with type vec = SO2.vec and type rot = SO2.t
 
   val make_pos_angle : vec -> float -> t
+  val make_angle : float -> t
 
   val pos_angle : t -> vec * float
   val pos_complex : t -> vec * Complex.t