I believe that I have successfully implemented all of your suggestions: The surfacecacher class is now in its own .cc file with its own .h file. The getsurface() method returns a surfaceref object, that when deleted, takes care of the references. There is also a getsurfaceonly() method, and a freesurface() method that can be used temporarily that return and free surface pointers All of the underscores in the method names should be gone All of the unsigned ints are u_int32's now. The gfx::setup function loads a value from the configuration and uses it for the maximum memory
On Feb 7, 2008 5:25 PM, Rian Shelley <[EMAIL PROTECTED]> wrote: > On Feb 7, 2008 4:16 PM, Tyler Nielsen <[EMAIL PROTECTED]> wrote: > > It's a great start. I'll only add one thing to what Kai said. The removal > > from the cache call needs to be improved. Basically free_surface needs to > > be easier to call. Passing in a 'surface *' would be better, but what I've > > That would be trivial to overload the function to do > > > been working towards is change the return value of surface_cache from > > 'surface *' to 'surfaceref *'. Then deleting surfaceref would decrease the > > ref counter automatically. > > I wasn't sure how solid the current api was, so I wanted to keep the > return the same. > > > > > If you want to finish up the cache things, I'll let you make the changes. > > If you want to work on another task, I'll take what you have and get it > > Integrated with Kai's comments. Just let us know. > > I'm good with whatever. > If you guys let me know what the irc channel is, I'll stop by tomorrow. >
surface_cacher_patch.tar.gz
Description: GNU Zip compressed data
_______________________________________________ Adonthell-devel mailing list Adonthell-devel@nongnu.org http://lists.nongnu.org/mailman/listinfo/adonthell-devel