anchor.diff:                                            :element-type '(unsigned-byte 1))))
                        (dotimes (i (array-total-size array))
                          (setf (row-major-aref new i) (row-major-aref array i)))
  -                     new)))))
  +                     new))
  +                  (:argb64f
  +                   (check-type array (array short-float (* * 4)))
  +                   (let ((pixels (make-array (array-dimensions array)
  +                                             :element-type 'short-float)))
  +                     ;; Fill pixels with premultiplied colour.
  +                     (cond (premultiplied
  +                            (dotimes (i (array-total-size array))
  +                              (setf (row-major-aref pixels i) (row-major-aref array i))))
  +                           (t
  +                            (dotimes (y (array-dimension array 0))
  +                              (dotimes (x (array-dimension array 1))
  +                                (let* ((alpha (aref array y x 3))
  +                                       (red   (aref array y x 2))
  +                                       (green (aref array y x 1))
  +                                       (blue  (aref array y x 0)))
  +                                  (setf (aref pixels y x 3) alpha
  +                                        (aref pixels y x 2) (* red alpha)
  +                                        (aref pixels y x 1) (* green alpha)
  +                                        (aref pixels y x 0) (* blue alpha)))))))
  +                     pixels)))))
       (%make-surface :pixels pixels
                      :format format)))
  +
  +(defun copy-surface (surface)
  +  (%make-surface :pixels (make-array (array-dimensions (surface-pixels surface))
  +                                     :element-type (array-element-type (surface-pixels surface))
  +                                     :initial-contents (surface-pixels surface))
  +                 :format (surface-format surface)))
   
   (defun surface-width (surface)
     "Return the width of SURFACE in pixels."
  
positive.code: 
  (defun surface-pixel (surface x y)
    "Get the pixel in SURFACE at (X,Y)."
    (aref (surface-pixels surface) y x))
  
  (defun (setf surface-pixel) (value surface x y)
    "Set the pixel in SURFACE at (X,Y)."
    (setf (aref (surface-pixels surface) y x) value))
  
  (defun bitblt (mode width height source-surface source-x source-y dest-surface dest-x dest-y)
    "Copy a WIDTHxHEIGHT rectangle of pixels from SOURCE-SURFACE to DEST-SURFACE.
  
negative.code: (in-package :mezzano.gui)
  
  (defstruct (surface
               (:constructor %make-surface)
               (:copier nil))
    (pixels (error "Pixel data not specified."))
    (format (error "Format not specified.")))
  
  