Crossfire Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: xpm slow?



Mark Wedel writes:
->  One thought I've had about pixmap creation is to change the way they
-> are initially read.
	Sounds like a good idea.

	Another suggestion is to do something with background pixmaps.
Right you have to draw both a background and foreground pixmap. But
you don't redraw the background tile ( wall, floor, etc ) unless
something above it has changed (because of the shape mask). What you
could do is map all the background objects, onto a seperate pixmap. At
the begining of the loop copy that entire pixmap to right on over the
current map pixmap ( both of these pixmaps are internal and not mapped
windows ). And then just throw down all the the rest of the object
pixmaps that actually move ( creatures, players, fireballs ). Now just
copy this entire pixmap striaght to the screen. This way you eliminate
all of the background copys and replace it with on large background
copy. Means an extra fairly large pixmap in memory for every map
active but it will speed things up. Its certanly feasable for a
client/server setup but it will consume much more memory if
implemented under the current setup (especially if all the players are
on different maps!!


				matt
				matt@cs.odu.edu