Message-ID: From: Robert Humphris To: "'djgpp AT delorie DOT com'" , "'Jeff Weeks'" Subject: RE: Style AND speed in C++? How? Please, I need some radical ideas on this one! Date: Mon, 21 Apr 1997 14:06:55 +0100 Encoding: 39 TEXT Precedence: bulk How about using a parent class, and having all drivers for new cards etc. as children of that class. The base class would work thus: class videoDriver { protected: // some stuff private: videoDriver(); ~videoDriver(); .. . // other virtual video functions .... }; then you can derive all your new drivers from this: class S3videoDriver : public videoDriver { .... } then you can do... void main() { videoDriver *pvdVideo; pvdVideo = new S3videoDriver; S3videoDriver->.... // some driver type operation .. . } Any good do you think? Rob Humphris >