From olpa@sybcom.de Mon Apr 2 11:15:28 2001 From: olpa@sybcom.de (olpa@sybcom.de) Date: Mon, 2 Apr 2001 12:15:28 +0200 (CEST) Subject: [Image-SIG] PIL / group4 CCITT Compression in TIFF Message-ID: Hi Folks, I browsed through the mailing list and found some questions asking for group4 decompression in TIFF files. I found no hint about a current development or library available. Is this still the actual status ? I would need a group4 decompressor for TIFF files ! Regards, oliver --- "Oh, I've seen copies [of Linux Journal] around the terminal room at The Labs." (By Dennis Ritchie) --- Oliver Pabst .-------------------------. mailto:olpa@sybcom.de : : phone :+49 681 56600600 : project department : SYBCOM GmbH fax :+49 681 56600660 : : http://www.sybcom.de From olpa@sybcom.de Mon Apr 2 15:34:13 2001 From: olpa@sybcom.de (olpa@sybcom.de) Date: Mon, 2 Apr 2001 16:34:13 +0200 (CEST) Subject: [Image-SIG] PIL / group4 CCITT Compression in TIFF In-Reply-To: <3AC87A32.37FAA399@pobox.com> Message-ID: On Today, warmerda@spitfire.velocet.net wrote: > Date: Mon, 02 Apr 2001 09:10:10 -0400 > From: Frank Warmerdam > To: olpa@sybcom.de > Subject: Re: [Image-SIG] PIL / group4 CCITT Compression in TIFF > > olpa@sybcom.de wrote: > > > > Hi Folks, > > > > I browsed through the mailing list and found some questions asking for > > group4 decompression in TIFF files. I found no hint about a current > > development or library available. > > > > Is this still the actual status ? > > > > I would need a group4 decompressor for TIFF files ! > > Oliver, > > I am a little confused about what you need. The libtiff library > already includes support for compressing and decompressing CCITT group 4 > tiff files. Isn't this what PIL is using? Unfortunately, this is not really true (I think). I got a blank PIL 1.1.1 from www.pythonware.org and compiled it. When I execute following code: >>> a=PIL.Image.open('2000120114153400--0-1.tif') >>> a.save('b.jpg') Traceback (innermost last): File "", line 1, in ? File "/usr/lib/python1.5/site-packages/PIL/Image.py", line 663, in save self.load() File "/usr/lib/python1.5/site-packages/PIL/ImageFile.py", line 133, in load d = Image._getdecoder(self.mode, d, a, self.decoderconfig) File "/usr/lib/python1.5/site-packages/PIL/Image.py", line 237, in _getdecoder raise IOError, "decoder %s not available" % decoder_name IOError: decoder group4 not available >>> exit where the .tif file is a CCITT group4 compressed file. It seems, there is no decoder for group4 in PIL. How can I load this file ??? libtiff should have a group4 decoder... Regards, oliver --- Running Windows on a Pentium is like having a brand new Porsche but only be able to drive backwards with the handbrake on. (Unknown source) --- Oliver Pabst .-------------------------. mailto:olpa@sybcom.de : : phone :+49 681 56600600 : project department : SYBCOM GmbH fax :+49 681 56600660 : : http://www.sybcom.de From srichter@cbu.edu Thu Apr 5 11:13:46 2001 From: srichter@cbu.edu (Stephan Richter) Date: Thu, 05 Apr 2001 05:13:46 -0500 Subject: [Image-SIG] PIL / group4 CCITT Compression in TIFF In-Reply-To: References: <3AC87A32.37FAA399@pobox.com> Message-ID: <5.0.2.1.0.20010405051027.00ab6c80@mail.cbu.edu> >where the .tif file is a CCITT group4 compressed file. > >It seems, there is no decoder for group4 in PIL. > >How can I load this file ??? > >libtiff should have a group4 decoder... This question is asked every two month or so. Indeed, PIL does not support the Group4 TIFF format. If you like, you can write your own decoder. The documentation for it is fairly good. I used tiffcp to copy it to a different format; be aware that the file size will drastically increase. If you implement the decoder, please post your results to the list. A lot of people would like to get the code. Regards, Stephan -- Stephan Richter CBU - Physics and Chemistry Student Web2k - Web Design/Development & Technical Project Management From duncan@rcp.co.uk Mon Apr 9 15:17:32 2001 From: duncan@rcp.co.uk (Duncan Booth) Date: Mon, 9 Apr 2001 15:17:32 +0100 Subject: [Image-SIG] PngImagePlugin 0.5 fails to load Png files Message-ID: <3AD1D28C.8969.3F1DB6BE@localhost> There seems to be a problem with PngImagePlugin version 0.5 and many but not all Png files (I was working my way through the images in the Zope Book, and the mono ones load but the colour ones don't). The problem is that version 0.5 has sprouted a line: self.png.close() at line 269 near the end of PngImageFile._open. This means that when you call the ImageFile.load() method, which calls PngImageFile.load_read(), the call: cid, pos, len = self.png.read() fails as the png object is no longer connected to the file. A typical traceback is shown below. Possible fixes include deleting the self.png.close call on line 269, or setting self.png=None after the close and reopening it in load_read as required. N.B. the source download at Secretlabs has version 0.4 of this file, but the windows download has version 0.5, so this problem probably hasn't hit Unix users yet. Python 2.0 (#8, Oct 16 2000, 17:27:58) [MSC 32 bit (Intel)] on win32 Type "copyright", "credits" or "license" for more information. >>> from PIL import PngImagePlugin, Image >>> im = Image.open("d:/work/book/Figures/4-3.png") >>> im.load() Traceback (most recent call last): File "", line 1, in ? File "d:\python20\PIL\ImageFile.py", line 146, in load s = self.load_read(self.decodermaxblock) File "d:\python20\PIL\PngImagePlugin.py", line 294, in load_read cid, pos, len = self.png.read() File "d:\python20\PIL\PngImagePlugin.py", line 82, in read s = self.fp.read(8) AttributeError: 'None' object has no attribute 'read' >>> -- Duncan Booth duncan@dales.rmplc.co.uk int month(char *p){return(124864/((p[0]+p[1]-p[2]&0x1f)+1)%12)["\5\x8\3" "\6\7\xb\1\x9\xa\2\0\4"];} // Who said my code was obscure? http://dales.rmplc.co.uk/Duncan From flytv1@yahoo.com Tue Apr 10 20:20:42 2001 From: flytv1@yahoo.com (t v) Date: Tue, 10 Apr 2001 12:20:42 -0700 (PDT) Subject: [Image-SIG] "Pil" module information. Message-ID: <20010410192042.28693.qmail@web13906.mail.yahoo.com> To: image-sig@python.org Hi. I am in the process of learning Python and I would like to use the "Pil" module. I have Python Ver. 2.1a2, from "..Python.org" and I downloaded "Pil" for this version, and I am using it on a Win98SE as an OS. I unzipped the module in the main path C:\Python21 and copied _imaging.pyd into the Dll subdirectory and file "pil.pth" into C:\Python21 . When I try to draw a line, see program below, I get a message: Traceback (most recent call last): File "C:\Python21\Tools\idle\linedraw.py", line 1, in ? import Image, ImageDraw File "c:\python21\Image.py", line 56, in ? import ImagePalette ImportError: No module named ImagePalette I see a module named "imagepal.py" in the C:\Python21\Pil, subdirectory and this is defined as class ImagePalette: and I am sure this is what it's needed to make it work. I used a number of other programming languages in the past and I would like to get a package together that I could use with Python, but it gets to be more difficult than I anticipated. There are a lot of Plugins/Modules, but they all seem to be incompatible, wrong versions etc. If you know of a package that I can download that would allow me to "open a file, read data, get coordinates, (XY) and draw lines between them " it is all I am trying to accomplish for now, I would greatly appreciate it. I keep going back to "C" and I know that Python would be more efficient to use in many cases, but it appears to be somewhat difficult right now, at least for Win98SE, OS. The program I ran: import Image, ImageDraw im = Image.open("test.gm") draw = ImageDraw.Draw(im) draw.line((0, 0), im.size, fill=128) draw.line((0, im.size[1]), (im.size[0], 0), fill=128) Thanks for your effort. Tiberiu Vela (T.V.) __________________________________________________ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/ From fredrik@pythonware.com Tue Apr 10 20:49:13 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Tue, 10 Apr 2001 21:49:13 +0200 Subject: [Image-SIG] "Pil" module information. References: <20010410192042.28693.qmail@web13906.mail.yahoo.com> Message-ID: <02e201c0c1f7$5444c5d0$e46940d5@hagrid> "flytv1@yahoo.com" wrote: > I am in the process of learning Python and I would > like to use the "Pil" module. I have Python Ver. > 2.1a2, from "..Python.org" and I downloaded "Pil" for > this version, and I am using it on a Win98SE as an OS. > I unzipped the module in the main path C:\Python21 and > copied _imaging.pyd into the Dll subdirectory and file > "pil.pth" into C:\Python21. if you're about to learn a new language, maybe you should stay away from alpha releases ;-) (I definitely recommend 2.0 over 2.1 alpha) > I see a module named "imagepal.py" in the > C:\Python21\Pil, subdirectory it should be "ImagePalette.py", not "imagepal.py" what tool did you use to unzip the library? make sure you use winzip [1] or Info-Zip's unzip [2]. older utilities (including pkzip) don't understand long filenames. Cheers /F 1) http://www.winzip.com 2) http://www.info-zip.org/pub/infozip/UnZip.html From fredrik@pythonware.com Wed Apr 11 14:16:02 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Wed, 11 Apr 2001 15:16:02 +0200 Subject: [Image-SIG] PngImagePlugin 0.5 fails to load Png files References: <3AD1D28C.8969.3F1DB6BE@localhost> Message-ID: <00a101c0c289$8fe10210$0900a8c0@SPIFF> duncan wrote: > Possible fixes include deleting the self.png.close call on line 269, > or setting self.png=None after the close and reopening it in load_read > as required. iirc, that close call is part of another bug fix (a resource leakage). looks like it didn't quite work. I'll look into this for 1.1.2. Thanks /F From Aureli.Soria_Frisch@ipk.fhg.de Thu Apr 12 18:22:34 2001 From: Aureli.Soria_Frisch@ipk.fhg.de (Aureli Soria Frisch) Date: Thu, 12 Apr 2001 19:22:34 +0200 Subject: [Image-SIG] Bug in paste method? In-Reply-To: <20010410192042.28693.qmail@web13906.mail.yahoo.com> Message-ID: Hi, I am using the MacPython 2.0 and the PIL included by default there. When doing: >>> a=Image.new('L',(128,128)) >>> a.paste(128,(0,0,9,9)) >>> a.save('prova.tif') A black 128x128 image appears, while up to the documentation an 8x8 box of grayvalue 128 should appear at the top left corner. What am I doing wrong? Thanks in advance, Aureli PS: paste() of another image (8x8 icon) is working properly ################################# Aureli Soria Frisch Fraunhofer IPK Dept. Pattern Recognition post: Pascalstr. 8-9, 10587 Berlin, Germany e-mail:aureli@ipk.fhg.de fon: +49 30 39 00 61 50 fax: +49 30 39 17 517 ################################# From nedens@checkerdist.com Fri Apr 13 14:05:00 2001 From: nedens@checkerdist.com (Nick Edens) Date: 13 Apr 2001 09:05:00 -0400 Subject: [Image-SIG] JPEG Files not reading DPI settings Message-ID: When I open a JPEG file (the file is a 300 DPI file) with the Image.open()= command it doesn't seem to read in the dpi settings.=20So when I go and sa= ve it it automatically saves it as a 72DPI file. Does anyone know of any wa= y to save it in the origonal DPI settings=3F Any prompt help would be GREATLY appreciated. - Nick Edens Checker Distributors From too@pk.highway.ne.jp Sat Apr 14 12:12:26 2001 From: too@pk.highway.ne.jp (Takekun Sato) Date: Sat, 14 Apr 2001 20:12:26 +0900 Subject: [Image-SIG] Gif file size Too Big for 1x1 image. Message-ID: <3AD8309A.776C247D@pk.highway.ne.jp> 1x1 pixel Gif image saved with Photoshop is 41Byte and 800Byte with PIL. (It seems PIL saves all 256 color palettes while only one palette is needed for 1x1 image.) What can I do ? From jleach@mail.ocis.net Sat Apr 14 17:17:17 2001 From: jleach@mail.ocis.net (Jason C. Leach) Date: Sat, 14 Apr 2001 09:17:17 -0700 (PDT) Subject: [Image-SIG] Gif file size Too Big for 1x1 image. In-Reply-To: <3AD8309A.776C247D@pk.highway.ne.jp> Message-ID: hi, Can you get the image format for a GIF and just write it yourself? j. ...................... ..... Jason C. Leach ... University College of the Cariboo. .. On Sat, 14 Apr 2001, Takekun Sato wrote: > > 1x1 pixel Gif image saved with Photoshop is 41Byte and > 800Byte with PIL. > > (It seems PIL saves all 256 color palettes > while only one palette is needed for 1x1 image.) > > What can I do ? > > > > > > > From jasonic@nomadicsltd.com Sat Apr 14 18:25:06 2001 From: jasonic@nomadicsltd.com (Jason Cunliffe) Date: Sat, 14 Apr 2001 13:25:06 -0400 Subject: [Image-SIG] extracting frame from movie? References: <022701c094de$b94dad20$01c8a8c0@it.tin.it> Message-ID: <008d01c0c507$d9da9e00$c3090740@megapathdsl.net> ----- Original Message ----- From: "Giulio Borrini - Netbuilder" > is it possibile with pil or any other lib to extract a frame from an avi > movie? > i need it to make a preview of some movies. Giulio How did you solve your problme? I need to do the same thing, also for Quicktime movies. Has anyone done this already or can point to useful [cross-platform] py-friendly tools. The immediate application we are developnig is non-profit community web site where people [mostly artists/filmmakers] upload all sorts of media. The site uses Zope which has a number of Zope plugins ['Products'] using PIL to do some nice server side image automatic manipulation. These are being extended ni intersting ways as demadn grows for a flexible servers-side image processing toolset. Already It's wonderful what PIL offers. Thanks! :-) But what has not been met yet afaik, is the strong demand is for thumnailing Quicktime and Avi files, preferably with option to set some 'keyframe' params so that people may upload digital movies, and thereby automagically generate a sequence of thumbnails with timestamp metadata also. any ideas? thanks - Jason ___________________________________________________________ Jason CUNLIFFE = NOMADICS['Interactive Art and Technology'] From too@pk.highway.ne.jp Mon Apr 16 13:35:02 2001 From: too@pk.highway.ne.jp (Takekun Sato) Date: Mon, 16 Apr 2001 21:35:02 +0900 Subject: [Image-SIG] Transparent Gif Message-ID: <3ADAE6F5.9D2E0307@pk.highway.ne.jp> I would like to make transparent Gif image. I tested following code but failed to make transparent pixels. If you know anything, please let me know. (platform: PIL1.1.1, Python2.0, Win2K) ----- import Image; im=Image.new("P",(100,100),0); im.putpalette([0,0,0,128,128,128]); for i in range(20,80): for j in range(20,40): im.putpixel((i,j),1); im.save("C:/tmp/test.gif",transparency=1); From fredrik@pythonware.com Mon Apr 16 15:46:08 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Mon, 16 Apr 2001 16:46:08 +0200 Subject: [Image-SIG] PngImagePlugin 0.5 fails to load Png files References: <3AD1D28C.8969.3F1DB6BE@localhost> Message-ID: <012301c0c683$fde8c600$e46940d5@hagrid> duncan wrote: > There seems to be a problem with PngImagePlugin version 0.5 and > many but not all Png files (I was working my way through the > images in the Zope Book, and the mono ones load but the colour > ones don't). The problem is that version 0.5 has sprouted a line: > self.png.close() > at line 269 near the end of PngImageFile._open. here's the "official" patch for this bug (bug id @PIL21) Cheers /F *** \py20\PIL\pngimageplugin.py Thu Feb 08 21:40:41 2001 --- PIL/PngImagePlugin.py Mon Apr 16 14:13:29 2001 *************** *** 266,273 **** rawmode, data = self.png.im_palette self.palette = ImagePalette.raw(rawmode, data) - self.png.close() - self.__idat = len # used by load_read() --- 267,272 ---- *************** *** 284,290 **** def load_read(self, bytes): ! "Read more data from chunks (used by ImageFile.load)" while self.__idat == 0: # end of chunk, skip forward to next one --- 283,289 ---- def load_read(self, bytes): ! "internal: read more image data" while self.__idat == 0: # end of chunk, skip forward to next one *************** *** 309,315 **** return self.fp.read(bytes) ! # # -------------------------------------------------------------------- # PNG writer --- 308,321 ---- return self.fp.read(bytes) ! ! def load_end(self): ! "internal: finished reading image data" ! ! self.png.close() ! self.png = None ! ! # -------------------------------------------------------------------- # PNG writer From Kevin.Cazabon@gretag.com Mon Apr 16 16:18:33 2001 From: Kevin.Cazabon@gretag.com (Kevin.Cazabon@gretag.com) Date: Mon, 16 Apr 2001 09:18:33 -0600 Subject: [Image-SIG] JPEG Files not reading DPI settings Message-ID: I ran into the same issue myself... I ended up hacking dpi support into a few of the PIL file modules, but didn't manage to get it into the JPG library... I think I found that it needed some deeper changes than I was willing to make at the time. If you like, I can send you the tiff, eps, bmp, and other modules that I DID hack, but don't know if that's of any use to you. I'd really like to see PIL support this feature where possible myself, as it's very important in many situations. Kevin Cazabon "Nick Edens" cc: (bcc: Kevin Cazabon/sienna/gig) Subject: [Image-SIG] JPEG Files not reading DPI settings 04/13/2001 07:05 AM When I open a JPEG file (the file is a 300 DPI file) with the Image.open() command it doesn't seem to read in the dpi settings. So when I go and save it it automatically saves it as a 72DPI file. Does anyone know of any way to save it in the origonal DPI settings? Any prompt help would be GREATLY appreciated. - Nick Edens Checker Distributors _______________________________________________ Image-SIG maillist - Image-SIG@python.org http://mail.python.org/mailman/listinfo/image-sig From too@pk.highway.ne.jp Mon Apr 16 23:29:33 2001 From: too@pk.highway.ne.jp (Takekun Sato) Date: Tue, 17 Apr 2001 07:29:33 +0900 Subject: [Image-SIG] Transparent Gif References: <3ADAE6F5.9D2E0307@pk.highway.ne.jp> Message-ID: <3ADB724D.76E8400A@pk.highway.ne.jp> Hello, I have posted 2 articles about gif with titles of "Gif file size too big for 1x1 pixel image" and "Transparent Gif" recently. I think I have solved the problems by modifying "GifImagePlugin.py". As to making transparent gif, you can consult a message here. http://mail.python.org/pipermail/image-sig/1999-December/000949.html - how to set palette size of saved gif (I'm not sure it is good way, so tips are presented here with no guarantee. If you find something wrong, or better way to do the same thing, please send me an email.) > im=Image.new("P",(1,1),0); > im.putpalette([0,0,0,255,255,255]); > im.putpixel(1); > im.info["colors"]=2; #set palette size(extension) > im.save("test.gif"); (A saved image thus was 38Bytes, initially about 800Bytes.) Before testing above, you need to modify "GifImagePlugin.py" like following. (From "GifImagePluglin.py" around line 295) # global palette if im.mode == "P": # colour palette ### s.append(im.im.getpalette("RGB")) #1. comment line 301 #-------------insertion start-----------# #2. add following palstr=im.im.getpalette("RGB"); while(1): if(im.info.has_key("colors")): cols=im.info["colors"]; bits=None; if(cols<=0 or cols>256): raise ValueError,"colors(%s) out of range[1:256] !"%cols for i in range(1,8): if(2**i>=cols): bits=i; break; if(bits!=None): if(len(palstr)>(3*cols)): palstr=palstr[:(3*(2**bits))]; s=["GIF87a"+o16(im.size[0])+o16(im.size[1])+chr((bits-1)+128)+chr(0)+chr(0),palstr]; break; s.append(palstr); break; #--------------insertion end--------------# else: # greyscale for i in range(256): s.append(chr(i) * 3) From fredrik@pythonware.com Wed Apr 18 10:42:09 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Wed, 18 Apr 2001 11:42:09 +0200 Subject: [Image-SIG] Python 2.1 issues Message-ID: <000901c0c7eb$d8475790$0900a8c0@spiff> PIL 1.1.1 works well under 2.1 final, but there are some old code in there that results in warnings under 2.1. one problem is that PIL 1.1.1 uses the old "regex" module in a few places. this module is deprecated in 2.1, and will be phased out in future versions. in 2.1, the easiest workaround is to filter out that group of warnings: import warnings warnings.filterwarnings(action = 'ignore', message='.*regex module is deprecated', category=DeprecationWarning) (from http://www.amk.ca/python/2.1/index.html) the other warning is a real bug under 2.1 and earlier: the ImagePalette.random function assumed that Python already had nested scopes (!). here's a patch: --- Imaging-1.1.1/PIL/ImagePalette.py Wed Jun 7 15:17:04 2000 +++ Imaging-1.2a3/PIL/ImagePalette.py Wed Apr 18 10:06:09 2001 @@ -62,8 +63,9 @@ return ImagePalette(mode, palette * len(mode)) def random(mode = "RGB"): - from whrandom import randint - palette = map(lambda a: randint(0, 255), [0]*256*len(mode)) + from random import randint + palette = map(lambda a, randint=randint: + randint(0, 255), [0]*256*len(mode)) return ImagePalette(mode, palette) def wedge(mode = "RGB"): --- end --- we plan to release a maintenance release some time next week (should have been this week, but paying customers got in the way ;-) Cheers /F PS. for pil plus customers who missed our announcement, another PIL 1.2 prerelease was released yesterday. see our site for more info. From gregc@cgl.ucsf.EDU Thu Apr 19 01:00:00 2001 From: gregc@cgl.ucsf.EDU (Greg Couch) Date: Wed, 18 Apr 2001 17:00:00 -0700 (PDT) Subject: [Image-SIG] GeoTIFF? (and patch) Message-ID: <200104190000.RAA416982@socrates.cgl.ucsf.edu> Here's an alternative patch to add image resolution and several other TIFF tags to TIFF files. Here you would add various entries to the Image.save's options parameter to place them in a TIFF file. The ones I added are: "resolution unit", "resolution", "x resolution", "y resolution", "software", "date time", "artist", and "copyright". TIFF images already supported an image "description" option. The resolutions are correctly written as TIFF rational values. Please cc any replies directly to me as I do not normally read this mailing list. Greg Couch UCSF Computer Graphics Lab gregc@cgl.ucsf.edu =================================================================== RCS file: RCS/TiffImagePlugin.py,v retrieving revision 1.1 diff -c -r1.1 TiffImagePlugin.py *** TiffImagePlugin.py 2001/04/18 21:40:09 1.1 --- TiffImagePlugin.py 2001/04/18 23:54:25 *************** *** 66,77 **** --- 66,84 ---- SAMPLESPERPIXEL = 277 ROWSPERSTRIP = 278 STRIPBYTECOUNTS = 279 + X_RESOLUTION = 282 + Y_RESOLUTION = 283 PLANAR_CONFIGURATION = 284 + RESOLUTION_UNIT = 296 + SOFTWARE = 305 + DATE_TIME = 306 + ARTIST = 315 PREDICTOR = 317 COLORMAP = 320 EXTRASAMPLES = 338 SAMPLEFORMAT = 339 JPEGTABLES = 347 + COPYRIGHT = 33432 IPTC_NAA_CHUNK = 33723 # newsphoto properties PHOTOSHOP_CHUNK = 34377 # photoshop properties *************** *** 313,318 **** --- 320,328 ---- if tag == STRIPOFFSETS: stripoffsets = len(directory) typ = 4 # to avoid catch-22 + elif tag in (X_RESOLUTION, Y_RESOLUTION): + # identify rational data fields + typ = 5 else: typ = 3 for v in value: *************** *** 329,335 **** elif len(data) < 4: append((tag, typ, len(value), data + (4-len(data))*"\0", "")) else: ! append((tag, typ, len(value), o32(offset), data)) offset = offset + len(data) if offset & 1: offset = offset + 1 # word padding --- 339,348 ---- elif len(data) < 4: append((tag, typ, len(value), data + (4-len(data))*"\0", "")) else: ! count = len(value) ! if typ == 5: ! count = count / 2 # adjust for rational data field ! append((tag, typ, count, o32(offset), data)) offset = offset + len(data) if offset & 1: offset = offset + 1 # word padding *************** *** 551,556 **** --- 564,579 ---- "LAB": ("LAB", 8, 1, (8,8,8), None), } + def _cvt_res(value): + # convert value to TIFF rational number -- (numerator, denominator) + if type(value) in (type([]), type(())): + assert(len(value) % 2 == 0) + return value + if type(value) == type(1): + return (value, 1) + value = float(value) + return (int(value * 65536), 65536) + def _save(im, fp, filename): try: *************** *** 566,573 **** --- 589,626 ---- ifd[IMAGEWIDTH] = im.size[0] ifd[IMAGELENGTH] = im.size[1] + # additions written by Greg Couch, gregc@cgl.ucsf.edu + # inspired by image-sig posting from Kevin Cazabon, kcazabon@home.com + if hasattr(im, 'tag'): + # preserve tags from original TIFF image file + for key in (RESOLUTION_UNIT, X_RESOLUTION, Y_RESOLUTION): + if im.tag.tagdata.has_key(key): + ifd[key] = im.tag.tagdata.get(key) if im.encoderinfo.has_key("description"): ifd[IMAGEDESCRIPTION] = im.encoderinfo["description"] + if im.encoderinfo.has_key("resolution"): + ifd[X_RESOLUTION] = ifd[Y_RESOLUTION] \ + = _cvt_res(im.encoderinfo["resolution"]) + if im.encoderinfo.has_key("x resolution"): + ifd[X_RESOLUTION] = _cvt_res(im.encoderinfo["x resolution"]) + if im.encoderinfo.has_key("y resolution"): + ifd[Y_RESOLUTION] = _cvt_res(im.encoderinfo["y resolution"]) + if im.encoderinfo.has_key("resolution unit"): + unit = im.encoderinfo["resolution unit"] + if unit == "inch": + ifd[RESOLUTION_UNIT] = 2 + elif unit == "cm" or unit == "centimeter": + ifd[RESOLUTION_UNIT] = 3 + else: + ifd[RESOLUTION_UNIT] = 1 + if im.encoderinfo.has_key("software"): + ifd[SOFTWARE] = im.encoderinfo["software"] + if im.encoderinfo.has_key("date time"): + ifd[DATE_TIME] = im.encoderinfo["date time"] + if im.encoderinfo.has_key("artist"): + ifd[ARTIST] = im.encoderinfo["artist"] + if im.encoderinfo.has_key("copyright"): + ifd[COPYRIGHT] = im.encoderinfo["copyright"] if bits != (1,): ifd[BITSPERSAMPLE] = bits From bfordham@afpress.com Sat Apr 21 17:51:01 2001 From: bfordham@afpress.com (Bryan Fordham) Date: Sat, 21 Apr 2001 12:51:01 -0400 Subject: [Image-SIG] twain support Message-ID: <3AE1BA75.B5AFAB69@afpress.com> I've searched the archives and didn't see this answered anywhere. Forgive me if I missed it... Is there a python module that provides TWAIN support on windows? Thanks, --B From kevin_cazabon@hotmail.com Mon Apr 23 17:45:13 2001 From: kevin_cazabon@hotmail.com (kcazabon@hotmail.com) Date: Mon, 23 Apr 2001 10:45:13 -0600 Subject: [Image-SIG] Screen capture... Message-ID: This is a multi-part message in MIME format. ------=_NextPart_000_000B_01C0CBE2.79ACF780 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Just wondering if anyone knows how to do a "screen capture" through = Python and save the resulting image through PIL... I want to create a tool to automatically capture the current screen and = save it to file (probably after some resizing, etc), and thought this = might be possible through Python/PIL. Thanks for any suggestions! Kevin Cazabon. ------=_NextPart_000_000B_01C0CBE2.79ACF780 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Just wondering if anyone knows how to = do a "screen=20 capture" through Python and save the resulting image through = PIL...
 
I want to create a tool to = automatically capture=20 the current screen and save it to file (probably after some resizing, = etc), and=20 thought this might be possible through Python/PIL.
 
Thanks for any = suggestions!
 
Kevin = Cazabon.
------=_NextPart_000_000B_01C0CBE2.79ACF780-- From kjetil.kjernsmo@astro.uio.no Tue Apr 24 10:51:47 2001 From: kjetil.kjernsmo@astro.uio.no (Kjetil Kjernsmo) Date: Tue, 24 Apr 2001 11:51:47 +0200 (MET DST) Subject: [Image-SIG] Porting PIL to Tru64 Message-ID: Dear all, I have grown soooo sick and tired of xfig I've just got to port Sketch to Tru64 UNIX (formerly Digital UNIX, osf1V4 or something like that). :-) To do that, I've got to port PIL, I guess, but I'm stuck. Unless, of course, somebody allready did, in which case I would be happy to hear about it. Anyway, I started last week by having someone install python-2.0 system-wide. I soon ran into the trouble I'm about to describe and gave up, but my itches was so bad last night, I just got to get it done. I have compiled both v1.0, which is linked from the Sketch pages and now v1.1.1. I have used different compilers, both gcc and Compaq's cc. There is an installation of tcl and tk versions 8.0 and 8.3. I have tried to link them both (but I haven't tried every possible combination of these). According to my sysadmin, they are both well tested. The compilation seems to go through without any trouble, all I need to do is change a path to where tk and tcl libraries are in the Setup-file. After having set setenv PYTHONPATH $HOME/lib/python/site-packages:$HOME/lib/python/site-packages/PIL setenv LD_LIBRARY_PATH /astro/local/lib:/local/lib:/local/X11R6/lib (yes, I know I should use a different shell) I run python: Python 2.0 (#2, Nov 13 2000, 15:15:57) [C] on osf1V4 Type "copyright", "credits" or "license" for more information. >>> import _imaging Traceback (most recent call last): File "", line 1, in ? ImportError: Unresolved symbol in /astro/local/lib/libtk8.0.so: XGetInputFocus I'm not much of a hacker, so I really don't have much of a clue as to how to address this. So, if anybody feels like taking my paw and guide me through this, it would be appreciated. Best, Kjetil -- Kjetil Kjernsmo Graduate astronomy-student Problems worthy of attack University of Oslo, Norway Prove their worth by hitting back E-mail: kjetikj@astro.uio.no - Piet Hein Homepage Webmaster@skepsis.no From bh@intevation.de Tue Apr 24 15:51:11 2001 From: bh@intevation.de (Bernhard Herzog) Date: 24 Apr 2001 16:51:11 +0200 Subject: [Image-SIG] Extracting hotspots from xbm files Message-ID: <6qvgnujqqo.fsf@abnoba.intevation.de> Hi all, here's a patch to the XbmImagePlugin so that it also extracts the hot-spots (important for X-cursors). The hotspot co-ordinates are put into the image's info dictionary under the key "hot_spot" as a 2-tuple. It also makes the plugin use re instead of regex. Bernhard *** PIL/XbmImagePlugin.py.orig Tue Apr 24 16:27:59 2001 --- PIL/XbmImagePlugin.py Tue Apr 24 16:42:27 2001 *************** *** 18,30 **** __version__ = "0.3" ! import regex, string import Image, ImageFile # XBM header ! xbm_head = regex.compile( ! "#define[ \t]+[^_]*_width[ \t]+\([0-9]*\)[\r\n]+" ! "#define[ \t]+[^_]*_height[ \t]+\([0-9]*\)[\r\n]+" "[\000-\377]*_bits\[\]" ) --- 18,34 ---- __version__ = "0.3" ! import re, string import Image, ImageFile # XBM header ! xbm_head = re.compile( ! "#define[ \t]+[^_]*_width[ \t]+(?P[0-9]*)[\r\n]+" ! "#define[ \t]+[^_]*_height[ \t]+(?P[0-9]*)[\r\n]+" ! "(?P" ! "#define[ \t]+[^_]*_x_hot[ \t]+(?P[0-9]*)[\r\n]+" ! "#define[ \t]+[^_]*_y_hot[ \t]+(?P[0-9]*)[\r\n]+" ! ")?" "[\000-\377]*_bits\[\]" ) *************** *** 40,56 **** def _open(self): ! s = xbm_head.match(self.fp.read(512)) ! if s > 0: ! ! xsize = string.atoi(xbm_head.group(1)) ! ysize = string.atoi(xbm_head.group(2)) self.mode = "1" self.size = xsize, ysize ! self.tile = [("xbm", (0, 0)+self.size, s, None)] def _save(im, fp, filename): --- 44,62 ---- def _open(self): ! match = xbm_head.match(self.fp.read(512)) ! if match is not None: + xsize = string.atoi(match.group("width")) + ysize = string.atoi(match.group("height")) + if match.group("hot_spot") is not None: + self.info["hot_spot"] = (string.atoi(match.group("xhot")), + string.atoi(match.group("yhot"))) self.mode = "1" self.size = xsize, ysize ! self.tile = [("xbm", (0, 0)+self.size, match.end(), None)] def _save(im, fp, filename): -- Intevation GmbH http://intevation.de/ Sketch http://sketch.sourceforge.net/ MapIt! http://mapit.de/ From NHYTRO@compuserve.com Wed Apr 25 13:57:49 2001 From: NHYTRO@compuserve.com (Sharriff Aina) Date: Wed, 25 Apr 2001 08:57:49 -0400 Subject: [Image-SIG] composition ! Message-ID: <200104250858_MC2-CDD4-54DD@compuserve.com> Hi List! Could someone tell me iff its possible to compose strips of images to one= big image? ( tile the images along the x or Y axis) Thanks Sharriff From spirou@carolo.com Wed Apr 25 13:02:23 2001 From: spirou@carolo.com (Denis) Date: Wed, 25 Apr 2001 14:02:23 +0200 Subject: [Image-SIG] Screen capture... In-Reply-To: ; from kevin_cazabon@hotmail.com on Mon, Apr 23, 2001 at 10:45:13AM -0600 References: Message-ID: <20010425140223.C30110@carolo.com> Le Mon, Apr 23, 2001 at 10:45:13AM -0600, kcazabon@hotmail.com pianota: > Just wondering if anyone knows how to do a "screen capture" > through Python and save the resulting image through PIL... I'm not a PIL specialist --> my answer is better than no answer, but ... I did a capture app once and I used ImageMagick with os.system("import -frame %s" % filename) > Thanks for any suggestions! Better ideas ? -- Denis FRERE P3B : Club Free-Pytho-Linuxien Caroloregien http://www.p3b.org Aragne : Internet - Reseaux - Formations http://www.aragne.com From jasonic@nomadicsltd.com Wed Apr 25 21:15:38 2001 From: jasonic@nomadicsltd.com (Jason Cunliffe) Date: Wed, 25 Apr 2001 16:15:38 -0400 Subject: [Image-SIG] Screen capture... References: <20010425140223.C30110@carolo.com> Message-ID: <009501c0cdc4$7ec38200$c3090740@megapathdsl.net> ----- Original Message ----- From: "Denis" > I'm not a PIL specialist --> my answer is better than no > answer, but ... > I did a capture app once and I used ImageMagick with > > os.system("import -frame %s" % filename) Hi I need to do something like this. Was planning to use PIL or a Zope prodcyt liek 'Photo' so I can capture and automatically upload and thumbnail users screens. Needs to be very cross platform, opensource.. I am new to ImageMagick. How did you interface it to Python? ...Details, examples welcome One crazy idea I just had is to look at VNC VNC has versatile ways for grabbing screens and section of them. An awesome tool. Free... Would be great to connect VNC and PIL! http://www.uk.research.att.com/vnc/ What is VNC? - A practical introduction VNC stands for Virtual Network Computing. It is, in essence, a remote display system which allows you to view a computing 'desktop' environment not only on the machine where it is running, but from anywhere on the Internet and from a wide variety of machine architectures. - Jason From spirou@carolo.com Thu Apr 26 03:45:50 2001 From: spirou@carolo.com (Denis) Date: Thu, 26 Apr 2001 04:45:50 +0200 Subject: [Image-SIG] Screen capture... In-Reply-To: <009501c0cdc4$7ec38200$c3090740@megapathdsl.net>; from jasonic@nomadicsltd.com on Wed, Apr 25, 2001 at 04:15:38PM -0400 References: <20010425140223.C30110@carolo.com> <009501c0cdc4$7ec38200$c3090740@megapathdsl.net> Message-ID: <20010426044550.C31609@carolo.com> Le Wed, Apr 25, 2001 at 04:15:38PM -0400, Jason Cunliffe pianota: > ----- Original Message ----- > From: "Denis" > > > I'm not a PIL specialist --> my answer is better than no > > answer, but ... > > I did a capture app once and I used ImageMagick with > > > > os.system("import -frame %s" % filename) > > Hi > > I need to do something like this. Was planning to use PIL or > a Zope prodcyt liek 'Photo' so I can capture and > automatically upload and thumbnail users screens. > > Needs to be very cross platform, opensource.. Open-Source : no problem. Cross-platform : I don't think ImageMagick would compile on a Win box. > I am new to ImageMagick. > How did you interface it to Python? ...Details, examples > welcome It's just a os.system() call. For the rest, you have to read the doc of ImageMagick to set the right command for your needs. Once you've captured and saved an image file, you can work on it with PIL or use it in Zope (never used the Photo product you are speaking of). > One crazy idea I just had is to look at VNC > VNC has versatile ways for grabbing screens and section of them. > An awesome tool. Free... > Would be great to connect VNC and PIL! I've played with VNC, but I don't think it would be that easy to "connect" it to PIL. In my head, it's far from a screen capture app. Won't a true guru give his 2 cents here ? -- Denis FRERE P3B : Club Free-Pytho-Linuxien Caroloregien http://www.p3b.org Aragne : Internet - Reseaux - Formations http://www.aragne.com From fredrik@pythonware.com Thu Apr 26 09:46:25 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Thu, 26 Apr 2001 10:46:25 +0200 Subject: [Image-SIG] composition ! References: <200104250858_MC2-CDD4-54DD@compuserve.com> Message-ID: <006c01c0ce2d$61a223c0$0900a8c0@spiff> Sharriff Aina wrote: > > Could someone tell me iff its possible to compose strips of images to one > big image? ( tile the images along the x or Y axis) using PIL, you can simply paste the strips into the resulting big image. See the "cutting, pasting, and merging" section in the PIL tutorial: http://www.pythonware.com/library/pil/handbook/intro01.htm more info on PIL can be found here: http://www.pythonware.com/products/pil/index.htm Cheers /F From fredrik@pythonware.com Thu Apr 26 09:56:12 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Thu, 26 Apr 2001 10:56:12 +0200 Subject: [Image-SIG] Porting PIL to Tru64 References: Message-ID: <007c01c0ce2e$bf269c50$0900a8c0@spiff> Kjetil Kjernsmo wrote: > I have grown soooo sick and tired of xfig I've just got to port Sketch to > Tru64 UNIX (formerly Digital UNIX, osf1V4 or something like that). :-) > To do that, I've got to port PIL, I guess, but I'm stuck. I've used PIL on that platform since long before it was known as tru64, and we do test all releases on that platform. > After having set > setenv PYTHONPATH $HOME/lib/python/site-packages:$HOME/lib/python/site-packages/PIL > setenv LD_LIBRARY_PATH /astro/local/lib:/local/lib:/local/X11R6/lib looks like you're using a non-standard X11 install (/local/X11R6 is not where X11 is installed by default). if that's the case, the only ones who can help you here are your local sysadms. (and let's hope they have very good reasons for using a non-standard X11 install on a tru64 box... ;-) > ImportError: Unresolved symbol in /astro/local/lib/libtk8.0.so: XGetInputFocus fwiw, this symbol is usually defined in libX11.a (or libX11.so). Cheers /F From kjetil.kjernsmo@astro.uio.no Thu Apr 26 10:49:35 2001 From: kjetil.kjernsmo@astro.uio.no (Kjetil Kjernsmo) Date: Thu, 26 Apr 2001 11:49:35 +0200 (MET DST) Subject: [Image-SIG] Porting PIL to Tru64 In-Reply-To: <007c01c0ce2e$bf269c50$0900a8c0@spiff> Message-ID: Thanks a lot for the response! On Thu, 26 Apr 2001, Fredrik Lundh wrote: >Kjetil Kjernsmo wrote: >> I have grown soooo sick and tired of xfig I've just got to port Sketch to >> Tru64 UNIX (formerly Digital UNIX, osf1V4 or something like that). :-) >> To do that, I've got to port PIL, I guess, but I'm stuck. > >I've used PIL on that platform since long before it was known as >tru64, and we do test all releases on that platform. Good! >> After having set >> setenv PYTHONPATH $HOME/lib/python/site-packages:$HOME/lib/python/site-packages/PIL >> setenv LD_LIBRARY_PATH /astro/local/lib:/local/lib:/local/X11R6/lib > >looks like you're using a non-standard X11 install (/local/X11R6 is >not where X11 is installed by default). if that's the case, the only >ones who can help you here are your local sysadms. Hm... Actually, we are discouraged from setting LD_LIBRARY_PATH at all, and if we do set it, it should be in a wrapper script.... Anyway, there exists a symlink /local/X11 -> /local/X11R6, so it is there. I always heard that it's /local/X11R6/lib I would include in LD_LIBRARY_PATH if I did include anything. But wouldn't this mean that changing setenv LD_LIBRARY_PATH /astro/local/lib:/local/lib:/local/X11R6/lib to setenv LD_LIBRARY_PATH /astro/local/lib:/local/lib:/local/X11/lib would solve the problem? >> ImportError: Unresolved symbol in /astro/local/lib/libtk8.0.so: XGetInputFocus > >fwiw, this symbol is usually defined in libX11.a (or libX11.so). I see. I found this in /local/X11/lib: lrwxr-xr-x 1 root system 13 Nov 10 23:41 libX11.so -> libX11.so.6.1 -rw-r--r-- 1 root staff 1155072 Nov 11 1998 libX11.so.6.1 does this make sense...? Best, Kjetil -- Kjetil Kjernsmo Graduate astronomy-student Problems worthy of attack University of Oslo, Norway Prove their worth by hitting back E-mail: kjetikj@astro.uio.no - Piet Hein Homepage Webmaster@skepsis.no From Aureli.Soria_Frisch@ipk.fhg.de Thu Apr 26 11:17:31 2001 From: Aureli.Soria_Frisch@ipk.fhg.de (Aureli Soria Frisch) Date: Thu, 26 Apr 2001 12:17:31 +0200 Subject: [Image-SIG] composition ! In-Reply-To: <006c01c0ce2d$61a223c0$0900a8c0@spiff> References: <200104250858_MC2-CDD4-54DD@compuserve.com> Message-ID: Hello, >using PIL, you can simply paste the strips into the resulting >big image. See the "cutting, pasting, and merging" section >in the PIL tutorial: >http://www.pythonware.com/library/pil/handbook/intro01.htm > Now thinking about paste method , maybe someone could answer an e-mail I sent some days ago: >I am using the MacPython 2.0 and the PIL included by default there. >When doing: > >>>> a=Image.new('L',(128,128)) >>>> a.paste(128,(0,0,9,9)) >>>> a.save('prova.tif') > >A black 128x128 image appears, while up to the documentation an 8x8 box of >grayvalue 128 should appear at the top left corner (I think). > >What am I doing wrong? > > >Thanks in advance, > >Aureli > >PS: paste() of another image (8x8 icon) is working properly Regards ################################# Aureli Soria Frisch Fraunhofer IPK Dept. Pattern Recognition post: Pascalstr. 8-9, 10587 Berlin, Germany e-mail:aureli@ipk.fhg.de fon: +49 30 39 00 61 50 fax: +49 30 39 17 517 ################################# From fredrik@pythonware.com Thu Apr 26 11:46:26 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Thu, 26 Apr 2001 12:46:26 +0200 Subject: [Image-SIG] composition ! References: <200104250858_MC2-CDD4-54DD@compuserve.com> Message-ID: <00f101c0ce3e$258596e0$0900a8c0@spiff> Aureli Soria Frisch wrote: > Now thinking about paste method , maybe someone could answer an e-mail I > sent some days ago: > > >I am using the MacPython 2.0 and the PIL included by default there. > >When doing: > > > >>>> a=Image.new('L',(128,128)) > >>>> a.paste(128,(0,0,9,9)) > >>>> a.save('prova.tif') > > > >A black 128x128 image appears, while up to the documentation an 8x8 box of > >grayvalue 128 should appear at the top left corner (I think). > > > >What am I doing wrong? in theory, nothing. it works just fine for me, on Windows with PIL 1.1.1. in case you cannot update, here's a workaround: def paste(image, ink, box): size = box[2] - box[0], box[3] - box[1] plate = Image.new(image.mode, size, ink) image.paste(plate, box) Cheers /F From Kevin.Cazabon@gretag.com Thu Apr 26 16:11:02 2001 From: Kevin.Cazabon@gretag.com (Kevin.Cazabon@gretag.com) Date: Thu, 26 Apr 2001 09:11:02 -0600 Subject: [Image-SIG] Screen capture... Message-ID: >> Won't a true guru give his 2 cents here ? There's got to be a way to do this through the Win32API module... my needs are Win-only, so that should work, but unfortunately not if you need cross-platform. I'll post the same screen-cap question on comp.lang.python tonite, and let you know if anything turns up, Win-specific or not. Kevin. From jasonic@nomadicsltd.com Thu Apr 26 17:06:46 2001 From: jasonic@nomadicsltd.com (Jason Cunliffe) Date: Thu, 26 Apr 2001 12:06:46 -0400 Subject: [Image-SIG] Screen capture... References: <20010425140223.C30110@carolo.com> <009501c0cdc4$7ec38200$c3090740@megapathdsl.net> <20010426044550.C31609@carolo.com> Message-ID: <001701c0ce6a$e525f860$c3090740@megapathdsl.net> ----- Original Message ----- From: "Denis" > Open-Source : no problem. > Cross-platform : I don't think ImageMagick would compile on a > Win box. The Good news is VNC very cross-platform [they call it 'Any-to-Any'], and even has recompiled binaries for ftp also. > I've played with VNC, but I don't think it would be that easy > to "connect" it to PIL. In my head, it's far from a screen > capture app. The VNC protocol is a simple protocol for remote access to graphical user interfaces. It is based on the concept of a remote framebuffer or RFB. In the past we have tended to refer to the VNC protocol as the RFB protocol, so you may have seen this term in other publications. The protocol simply allows a server to update the framebuffer displayed on a viewer. Because it works at the framebuffer level it is potentially applicable to all operating systems, windowing systems and applications. This includes X/Unix, Windows 3.1/95/NT and Macintosh, but might also include PDAs, and indeed any device with some form of communications link. The protocol will operate over any reliable transport such as TCP/IP. How it Works http://www.uk.research.att.com/vnc/howitworks.html Screenshots http://www.uk.research.att.com/vnc/screenshots.html VNC Protocol http://www.uk.research.att.com/vnc/protocol.html Easy? Depends on one's skill.. Alas I am not a C/C++ programmer so it is harder for me to say. But installing and running VNC is very easy. There are a number of add-ons and modifications people have made, VNC has a small but bright, focused user community. I see severl possible approaches: A. 'Tweak' NVC client to allow python to grab and convert images uses PIL, ImageMagick etc. B. Embed Python inside of a VNC Server / Client. C. Implement a version of VNC in Python eigther from scracth or more likely by taking VNC and making it a Python extension module. VNC Contributions http://www.uk.research.att.com/vnc/contribs.html Source and binaries from: http://www.uk.research.att.com/vnc/download.html any thoughts? - Jason ___________________________________________________________ Jason CUNLIFFE = NOMADICS['Interactive Art and Technology'] From fredrik@pythonware.com Thu Apr 26 18:13:33 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Thu, 26 Apr 2001 19:13:33 +0200 Subject: [Image-SIG] Screen capture... References: Message-ID: <005501c0ce74$44b22e30$e46940d5@hagrid> kevin wrote: > There's got to be a way to do this through the Win32API module... my needs > are Win-only, so that should work, but unfortunately not if you need > cross-platform. I just posted a simple "grabscreen" extension module to http://effbot.org/pil the PYD file requires Python 2.0 (PY20 or compatible), and has only been tested on a Win2k box. Cheers /F From mmiller3@iupui.edu Fri Apr 27 00:23:45 2001 From: mmiller3@iupui.edu (Michael A. Miller) Date: 26 Apr 2001 18:23:45 -0500 Subject: [Image-SIG] Screen capture... In-Reply-To: Denis's message of "Thu, 26 Apr 2001 04:45:50 +0200" References: <20010425140223.C30110@carolo.com> <009501c0cdc4$7ec38200$c3090740@megapathdsl.net> <20010426044550.C31609@carolo.com> Message-ID: <87ae53s0se.fsf@lumen.med.iupui.edu> >>>>> "Denis" == Denis writes: > Open-Source : no problem. Cross-platform : I don't think > ImageMagick would compile on a Win box. Actually, "ImageMagick is known to compile and run on virtually any Unix. system and Linux. It also runs under Windows 2000, Windows 95/98, Macintosh, VMS, and OS2. See the install guide for compiling instructions. Pre-compiled binaries are available for some of the more popular operating systems. The entire source and binary distribution is also available for a limited time on CD." From jasonic@nomadicsltd.com Fri Apr 27 00:51:49 2001 From: jasonic@nomadicsltd.com (Jason Cunliffe) Date: Thu, 26 Apr 2001 19:51:49 -0400 Subject: [Image-SIG] Screen capture... References: <005501c0ce74$44b22e30$e46940d5@hagrid> Message-ID: <003101c0ceab$dcf13a60$c3090740@megapathdsl.net> From: "Fredrik Lundh" > I just posted a simple "grabscreen" extension module to > > http://effbot.org/pil > > the PYD file requires Python 2.0 (PY20 or compatible), and > has only been tested on a Win2k box. Thankyou :-) What is need to make this also work on Mac and Linux? cheers - Jason ___________________________________________________________ Jason CUNLIFFE = NOMADICS['Interactive Art and Technology'] From deirdre@deirdre.net Fri Apr 27 01:12:43 2001 From: deirdre@deirdre.net (Deirdre Saoirse Moen) Date: Thu, 26 Apr 2001 17:12:43 -0700 Subject: [Image-SIG] Screen capture... In-Reply-To: <003101c0ceab$dcf13a60$c3090740@megapathdsl.net> References: <005501c0ce74$44b22e30$e46940d5@hagrid> Message-ID: >From: "Fredrik Lundh" >> I just posted a simple "grabscreen" extension module to >> >> http://effbot.org/pil >> >> the PYD file requires Python 2.0 (PY20 or compatible), and >> has only been tested on a Win2k box. > >Thankyou :-) >What is need to make this also work on Mac and Linux? Is there a mac port of PIL? If not, is anyone working on it? If so, who do I contact? -- _Deirdre Stash-o-Matic: http://weirdre.com http://deirdre.net "I love deadlines. I like the whooshing sound they make as they fly by." - Douglas Adams From fredrik@pythonware.com Fri Apr 27 09:32:08 2001 From: fredrik@pythonware.com (Fredrik Lundh) Date: Fri, 27 Apr 2001 10:32:08 +0200 Subject: [Image-SIG] Screen capture... References: <005501c0ce74$44b22e30$e46940d5@hagrid> Message-ID: <003801c0cef4$8cd7f840$0900a8c0@spiff> Deirdre Saoirse Moen wrote: > Is there a mac port of PIL? the standard Mac distribution includes PIL: http://www.python.org/download/download_mac.html (I don't have a Mac myself, so I cannot offer an "official" port. contributions are welcome ;-) Cheers /F