Hey, I'm working on a Paint program. I've never built a proper program before so I was wondering how I should go about structuring an actual piece of software. I'm trying to a make a simple paint application (like MS paint) using C++ and the SDL library.
Right now, I'm thinking along the lines of having two main objects, a Screen and a Handler. The Handler waits on the Screen class for events and processes the events and updates the Screen.
Something like this
class screen{} Screen;
class handler{
[INDENT]start(){
[INDENT]while(1){
[INDENT]drawscreen()
processevent()[/INDENT]
}[/INDENT]
}[/INDENT]
}
That looks very simple. Is this a scalable way of doing things? How I render things like lines and circles? Do I make a Line class and 'add' it to the screen, or just 'tell' the screen to draw a line? These are the kinds of questions I have. Any ideas?