[cello-cvs] CVS cello/cl-magick
ktilton
ktilton at common-lisp.net
Thu Jul 6 22:09:11 UTC 2006
Update of /project/cello/cvsroot/cello/cl-magick
In directory clnet:/tmp/cvs-serv9972/cl-magick
Modified Files:
cl-magick.asd cl-magick.lisp cl-magick.lpr mgk-utils.lisp
wand-image.lisp
Log Message:
--- /project/cello/cvsroot/cello/cl-magick/cl-magick.asd 2006/05/17 16:14:29 1.1
+++ /project/cello/cvsroot/cello/cl-magick/cl-magick.asd 2006/07/06 22:09:11 1.2
@@ -16,6 +16,7 @@
:licence "MIT"
:description "Bindings for ImageMagick"
:long-description "Poorly implemented bindings to half of ImageMagick"
+ :depends-on (gui-geometry)
:components ((:file "cl-magick")
(:file "magick-wand" :depends-on ("cl-magick"))
(:file "drawing-wand" :depends-on ("magick-wand"))
@@ -23,5 +24,4 @@
(:file "mgk-utils" :depends-on ("pixel-wand"))
(:file "wand-image" :depends-on ("mgk-utils"))
(:file "wand-texture" :depends-on ("wand-image"))
- (:file "wand-pixels" :depends-on ("wand-texture"))
- (:file "mgk-test" :depends-on ("wand-pixels"))))
+ (:file "wand-pixels" :depends-on ("wand-texture"))))
--- /project/cello/cvsroot/cello/cl-magick/cl-magick.lisp 2006/06/26 17:05:22 1.4
+++ /project/cello/cvsroot/cello/cl-magick/cl-magick.lisp 2006/07/06 22:09:11 1.5
@@ -25,7 +25,7 @@
(:use
#:common-lisp
#:gui-geometry
- #-(or cormanlisp ccl) #:clos
+ #-(or cormanlisp ccl sbcl) #:clos
#:cffi
#:cffi-extender
#+kt-opengl
@@ -58,7 +58,7 @@
(defparameter *mgk-version* (fgn-alloc :unsigned-long 1))
(cffi:define-foreign-library Magick
- (:darwin (:framework "GraphicsMagick"))
+ (:darwin (:or (:framework "GraphicsMagick") "libGraphicsMagick.dylib"))
(:windows (:or #+not "C:\\Program Files\\ImageMagick-6.2.7-Q8\\CORE_RL_wand_.dll"
"C:\\Program Files\\GraphicsMagick-1.1.7-Q8\\CORE_RL_wand_.dll")))
@@ -103,7 +103,7 @@
(let ((wi (apply 'make-instance wand-type
:file-path$ file-path$
iargs)))
- (print `(wand-ensure-typed forced to load ,wand-type ,file-path$))
+ ;;(print `(wand-ensure-typed forced to load ,wand-type ,file-path$))
(push (cons key wi) (wands-loaded))
wi)
(error "Unable to load image file ~a" file-path$)))))
--- /project/cello/cvsroot/cello/cl-magick/cl-magick.lpr 2006/07/03 00:35:13 1.4
+++ /project/cello/cvsroot/cello/cl-magick/cl-magick.lpr 2006/07/06 22:09:11 1.5
@@ -1,4 +1,4 @@
-;; -*- lisp-version: "8.0 [Windows] (Jun 28, 2006 10:53)"; cg: "1.81"; -*-
+;; -*- lisp-version: "8.0 [Windows] (Jul 5, 2006 12:21)"; cg: "1.81"; -*-
(in-package :cg-user)
--- /project/cello/cvsroot/cello/cl-magick/mgk-utils.lisp 2006/05/17 16:14:29 1.1
+++ /project/cello/cvsroot/cello/cl-magick/mgk-utils.lisp 2006/07/06 22:09:11 1.2
@@ -22,7 +22,7 @@
(in-package :cl-magick)
-(eval-when (compile load eval)
+(eval-when (:compile-toplevel :load-toplevel :execute)
(export '(pixels-to-file wand-image-pixels-set
make-recording record-frame recording-write recording-destroy)))
--- /project/cello/cvsroot/cello/cl-magick/wand-image.lisp 2006/05/17 16:14:29 1.1
+++ /project/cello/cvsroot/cello/cl-magick/wand-image.lisp 2006/07/06 22:09:11 1.2
@@ -69,7 +69,7 @@
(let ((stat (magick-read-image wand p)))
(if (zerop stat)
(format t "~&magick-read jpeg failed on ~a" p)
- (format t "~&magick-read-OK ~a" p)))
+ #+shhh (format t "~&magick-read-OK ~a" p)))
wand))
(defparameter *mgk-columns*
@@ -90,7 +90,7 @@
(if (zerop (* last-col last-row))
(let* ((columns 64)(rows 64)
(pixels (fgn-alloc :unsigned-char (* 3 columns rows) :wand-image)))
- (print "wand-get-image-pixels > wand has zero pixels; did the load fail?")
+ ;(print "wand-get-image-pixels > wand has zero pixels; did the load fail?")
(dotimes (pn (* columns rows))
(setf (elti pixels pn) -1))
(values pixels columns rows))
@@ -98,7 +98,9 @@
(let* ((columns (- last-col first-col))
(rows (- last-row first-row))
(pixels (fgn-alloc :unsigned-char (* 3 columns rows) :wand-image)))
- (print (list "wand-get-image-pixels got" wand (* 3 columns rows) pixels))
+ (ukt:trc "wand pixels has colrowa" columns rows)
+
+ ;(print (list "wand-get-image-pixels got" wand (* 3 columns rows) pixels))
(magick-get-image-pixels wand first-col first-row columns rows "RGB" 0 pixels )
#+testing (progn
(incf testn)
@@ -106,5 +108,11 @@
(print `(writeimage ,(magick-write-image wand (format nil "C:\\TEST~a.GIF" testn))))
#+not (print `(writeimage ,(magick-write-image wand "C:\\TEST.BMP"))))
+ (loop for row below 16 do
+ (loop for col below 16 by 1
+ for offset = (+ (* row columns 3) (* col 3))
+ do (print (loop for bn below 3
+ collecting (setf (elti pixels (+ offset bn)) 0)))))
+
(values pixels columns rows))))
More information about the Cello-cvs
mailing list