]> granicus.if.org Git - graphviz/commitdiff
add some comments
authorellson <devnull@localhost>
Wed, 13 Jul 2005 12:02:04 +0000 (12:02 +0000)
committerellson <devnull@localhost>
Wed, 13 Jul 2005 12:02:04 +0000 (12:02 +0000)
contrib/diffimg/Makefile
contrib/diffimg/diffimg.c

index 33b02dcaf5eacfb811a3d3f12549dc7af1cbb7b5..23d972d4d2bc80bfd90ba726e70e56c4a2a69473 100644 (file)
@@ -1,3 +1,6 @@
+VERSION=0.1
+
+CFLAGS=-O2 -Wall -DVERSION="$(VERSION)"
 LDFLAGS = -lgd
 
 diffimg: diffimg.o
@@ -11,5 +14,12 @@ test: diffimg
        echo $(GRAPH) | dot -Grankdir=LR -Tpng:cg >hello2.png
        ./diffimg hello1.png hello2.png >test2.png
 
+dist: clean
+       mkdir diffimg-$(VERSION)
+       tar cf - --exclude diffimg-$(VERSION) . | (cd diffimg-$(VERSION); tar xf -)
+       tar czf - diffimg-$(VERSION) >diffimg-$(VERSION).tgz
+       rm -rf diffimg-$(VERSION)
+
 clean:
-       rm -f diffimg *.o *.png
+       rm -f diffimg *.o *.png *,tgz
+
index 16a6b93a313c8bacb853a3a055e4cbdcd83852b4..5055bf32667fb72ba8e76fe870058d62fb5cb370 100644 (file)
@@ -1,3 +1,30 @@
+/* $Id$ $Revision$ */
+/* vim:set shiftwidth=4 ts=8: */
+
+/**********************************************************
+*      This software is part of the graphviz package      *
+*                http://www.graphviz.org/                 *
+*                                                         *
+*            Copyright (c) 1994-2004 AT&T Corp.           *
+*                and is licensed under the                *
+*            Common Public License, Version 1.0           *
+*                      by AT&T Corp.                      *
+*                                                         *
+*        Information and Software Systems Research        *
+*              AT&T Research, Florham Park NJ             *
+**********************************************************/
+
+/*
+ * This program generates an image where each pixel is the difference between
+ * the corresponding pixel in each of the two source images.  Thus, if the source images
+ * are the same the resulting image will be black, otherwise it will have regions of
+ * non-black where the images differ.
+ *
+ * Currently only supports PNG images.
+ *
+ * John Ellson <ellson@research.att.com>
+ */
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <gd.h>