Posted 27 January 2000 - 04:40 PM
Start with a surface class. You should be able to set the init properties of this to any kind of surface and then have a generic create surface function. Put pixel plotting and bitmap functions in here. Then make a screen class. This should be higher up in the level of abstraction than the surface. It should have 3 pointers to surfaces and initalize them to make a double buffered screen system or a triple. This class should do windowed/fullscreen changes. the constructor of this should take width,height,bpp and the window handle as the params. also in your surface make a offscreen surface function that uses your lower level surface creation functions to make an offscreen surface for you and even automatically load a bmp and then create the surface for it automatically so all you have to do is Surface->LoadBmp("bm.bmp"); and then it creates everything for you. Im sure you can think of several other neat things to add too.