I am making a program that creates a very large picture on the screen. The picture scrolls all by itself like a movie.
The problem is that the code that generates this is in a loop in OnDraw, and as long as it's in it, I can't do anything else, like push a button on the screen, or click on a menu option.
So I have to split the program into to threads. One thread will handle getting the picture onto the screen, and the other will handle the rest of the interface.
I was thinking of taking the picture processing into the secondary thread, but that's when I get into trouble.
I have made several threaded programs before, but no programs where the secondary thread need access to windows functions like BitBlt(....), SetPixel(....) and creating a bitmap memory. These are the functions that make the pixture apear on the screen.
Does anybody have any idea of how I can attack this problem?