Take a look:
The Circle class has a well and functioning function named draw. The problem here is how to invoke it on all of the Circles in the set circles.Code:set<Circle*>* circles = new set<Circle*>() ; for(int i=0; i<100; i++) circles->insert(new Circle(rand()%screen_width, rand()%screen_height )); set<Circle*>::iterator pos; for (pos = circles->begin(); pos != circles->end(); pos++) { pos->draw(buffer); }



LinkBack URL
About LinkBacks



