X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=convert.lisp;h=bb5094264a051365e1573a41e413931cc9e49ded;hb=7ba9d73cc35ce3fa0b2fc9e1145f6cafd4b73d0d;hp=f663cf8fc98e1651357ea99a0cc8edb70b8ded8f;hpb=afb52c66a55ede18c0dc3b9ca8ee4cf0e7570937;p=cl-photo.git diff --git a/convert.lisp b/convert.lisp old mode 100755 new mode 100644 index f663cf8..bb50942 --- a/convert.lisp +++ b/convert.lisp @@ -55,8 +55,8 @@ (ecase units (:mm d) (:inches (inches->mm d)) - (:feet (* 12 (inches->mm d))) - (:yards (* 36 (inches->mm d))) + (:feet (inches->mm (* d 12))) + (:yards (inches->mm (* d 36))) (:meters (* 1000 d)))) (defun mm->length (d units) @@ -68,26 +68,4 @@ (:yards (/ (mm->inches d) 36)) (:meters (/ d 1000)))) -(defun format-dimensions (format) - "Returns format dimensions in mm." - (ecase format - (:aps-c (cons 22.7 15.1)) - ((:aps :dx) (cons 24 16)) - ((:35 :35mm) (cons 36 24)) - ((:645 :6x4.5cm) (cons 60 45)) - ((:6x6 :6x6cm) (cons 60 60)) - ((:6x7 :6x7cm) (cons 60 70)) - ((:6x9 :6x9cm) (cons 60 90)) - ((:4x5 :4x5in) (cons (* 4 +inches->mm+) (* 5 +inches->mm+))) - ((:5x7 :5x7in) (cons (* 5 +inches->mm+) (* 7 +inches->mm+))) - ((:8x10 :8x10in) (cons (* 8 +inches->mm+) (* 10 +inches->mm+))) - (:11x13.75in (cons (* 11 +inches->mm+) (* 13.75 +inches->mm+))) - (:11x16.5in (cons (* 11 +inches->mm+) (* 16.5 +inches->mm+))) - (:13x19in (cons (* 13 +inches->mm+) (* 19 +inches->mm+))) - (:16x20in (cons (* 13 +inches->mm+) (* 19 +inches->mm+))) - (:16x24in (cons (* 13 +inches->mm+) (* 19 +inches->mm+))) - (:18x22.5in (cons (* 13 +inches->mm+) (* 19 +inches->mm+))) - (:18x24in (cons (* 13 +inches->mm+) (* 19 +inches->mm+))) - (:24x30in (cons (* 13 +inches->mm+) (* 19 +inches->mm+))) - (:24x36in (cons (* 13 +inches->mm+) (* 19 +inches->mm+))) - )) +