A SERVICE OF

logo

145
Chapter 13
13. Multiprocessing
If you would like to display two views of the same scene graph, you need to use the
multiprocessing capabilities of Cosmo 3D. You might, for example, like to display a
ground-view and an over-head view of the same scene at the same time. You can
accomplish this by creating a thread for each view and connecting each to their own
csWindow and csContext, as shown in Figure 13-1.
Figure 13-1 Multiprocessing
This chapter describes how to implement multiprocessing in the following sections:
•“Implementing Multiprocessing on page 146.
•“Thread Blocking on page 148.
•“Multithreaded Example on page 150.
Scene graph
csWindow 0
Graphics pipeline 0
Graphics pipeline 1
csWindow 1
Thread 0
csContext 0
Thread 1
csContext 1