Hi,

No, it stops as soon as it sees the second color (for getcolors(1))...
ummm, my gut says there isn't a second color in a single-color image :)

and Mapniks tostring() and PILs fromstring() are just a memory copy. So this 
will also be fast. Of course, you need PIL as a dependency.
Don't know about Mapnik, but since I had the PIL sources open anyway, I looked it up. PILs fromstring() is a bit more involved than a memory copy. It actually has a cyclomatic complexity of three. Of course, it most probably _is_ quite fast so that you can't tell it from a memory copy for most practical purposes.

In the end, the First Networking Truth holds: It Has To Work. But that's for Markus to decide what works for his app (and an occasional mailing list archive reader in the future).

Bye
Igor

_______________________________________________
dev mailing list
[email protected]
http://lists.openstreetmap.org/listinfo/dev

Reply via email to