anchor.diff:                  for cx fixnum = (minus xd dx)
                   for cy fixnum = (minus yd dy) do
                   (loop for i fixnum from 0 below ncomp do
  -                      (setf (dbref (svref outbuf i) cx cy)
  -                            (minus (svref inbuf (plus pos i)) 128)))))
  +                      (setf (dbref (aref outbuf i) cx cy)
  +                            (minus (aref inbuf (plus pos i)) 128)))))
       (values xend yend)))
   
   ;;; Direct color mapping
  
positive.code:          (nxbase (mul xbase ncomp))
           (nybase (mul ybase nwidth)))
      (declare #.*optimize*
               (type (simple-vector *) block buffer)
               (type fixnum x y H V ncomp xbase ybase nwidth nx dend nxbase nybase offset)
               (dynamic-extent ncomp xbase ybase nxbase nybase))
      (loop for row across block
  
negative.code: 
  ;;; Default quantization tables
  (define-constant +q-luminance+
    (2d-uint8-array '(16 11 10 16 24 40 51 61)
                    '(12 12 14 19 26 58 60 55)
                    '(14 13 16 24 40 57 69 56)
                    '(14 17 22 29 51 87 80 62)
                    '(18 22 37 56 68 109 103 77)
                    '(24 35 55 64 81 104 113 92)
                    '(49 64 78 87 103 121 120 101)
                    '(72 92 95 98 112 100 103 99)))
  
  (define-constant +q-chrominance+
    (2d-uint8-array '(17 18 24 47 99 99 99 99)
                    '(18 21 26 66 99 99 99 99)
                    '(24 26 56 99 99 99 99 99)
                    '(47 66 99 99 99 99 99 99)
                    '(99 99 99 99 99 99 99 99)
                    '(99 99 99 99 99 99 99 99)
                    '(99 99 99 99 99 99 99 99)
                    '(99 99 99 99 99 99 99 99)))
  
  (define-constant +q-luminance-hi+
    (2d-uint8-array '(10 7 6 10 15 25 32 38)
                    '(8 8 9 12 16 36 38 34)
                    '(9 8 10 15 25 36 43 35)
                    '(9 11 14 18 32 54 50 39)
                    '(11 14 23 35 42 68 64 48)
                    '(15 22 34 40 51 65 71 58)
                    '(31 40 49 54 64 76 75 63)
                    '(45 58 59 61 70 62 64 62)))
  
  (define-constant +q-chrominance-hi+
    (2d-uint8-array '(11 11 15 29 62 62 62 62)
                    '(11 13 16 41 62 62 62 62)
                    '(15 16 35 62 62 62 62 62)
                    '(29 41 62 62 62 62 62 62)
                    '(62 62 62 62 62 62 62 62)
                    '(62 62 62 62 62 62 62 62)
                    '(62 62 62 62 62 62 62 62)
                    '(62 62 62 62 62 62 62 62)))
  
  )
  
  