Hi, I need to develop a full featured UI which interfaces a imaging device and display frames of data as a video sequence(BMP images). I have a standard USB Driver, which can dump data into a file pointed by the user.(for interfacing the device with the UI) I have a GUI which can display image from a buffer. What i need to do: I have planned to create two separate threads where, in one thread the GUI routine opens a window and keeps checking for the data buffer to be full using a flag mechanism. In the other thread, the USB driver needs to draw data frames form the device and check conditions on the data for getting one full frame image data. when it is true. it will raise a flag and indicate the other thread about its availability. After getting the flag indication the UI routine should display the it as a bmp image on the window. This should continue as a video sequence. As all camera software works. Any related code snippets, related procedures, links, etc would help me a lot. thread creation. how to run it as required. (in seperate threads). efficient usage of time and memory. integration of the driver with the UI.