1 ;;;; -*- Mode: LISP; Syntax: ANSI-Common-Lisp; Base: 10; Package: photo -*-
2 ;;;; *************************************************************************
3 ;;;; FILE IDENTIFICATION
5 ;;;; Name: convert.lisp
6 ;;;; Purpose: Conversions functions for cl-photo
7 ;;;; Programmer: Kevin M. Rosenberg
8 ;;;; Date Started: April 2005
10 ;;;; $Id: package.lisp 8596 2004-02-03 18:32:50Z kevin $
12 ;;;; This file, part of cl-photo, is Copyright (c) 2005 by Kevin Rosenberg.
13 ;;;; Rights of modification and redistribution are in the LICENSE file.
15 ;;;; *************************************************************************
19 (defconstant +radian->degrees+ (/ 360d0 pi 2))
20 (defconstant +inches->mm+ 25.4)
23 (sqrt (+ (* x x) (* y y))))
25 (defun radians->degrees (r)
26 (* +radian->degrees+ r))
29 (/ d +inches->mm+ 12))
32 (* d 12 +inches->mm+))