From: Arthur <ajs...@op...> - 2004-09-10 17:09:12
|
> -----Original Message----- > From: edu...@py... [mailto:edu...@py...] On > Behalf Of Joel Kahn > Sent: Thursday, September 09, 2004 4:42 PM > To: vis...@li...; ed...@py... > Subject: [Edu-sig] Images in VPython: Faces > > The attached script contains another approach to the > process of displaying images in VPython. Instead of > there being an object for each "pixel," two triangles > on a faces object are placed together to produce a > square, as noted in the appropriate comment lines. As > with my "objects" example, I kept this prototype as > simple as possible; there are many things that could > be done with varying normals, z-axis-positions, &c > that I haven't touched yet. > > The new "faces" algorithm delivers the image to the > screen significantly more quickly than the "objects" > system, and it seems to be able to handle much higher > resolution pictures; still, I suggest beginning your > experiments with small bitmaps to play it safe. > > As always, feedback is encouraged. I hadn't had PIL installed, and it wasn't downloading went I first went to get it, so I hadn't been able to look at this before. I can now, and so did now. I hadn't had PIL because I've never have done much outside of vector graphics. I am used to working at the graphics object level, not the pixel level. I think your demo ties the two concepts together in a fun way. Thanks, Art |