|
|
|
|
|
| ||||||||||||||||||||||||||||||||||||
|
| ||||||||||||||||||||||||||||||||||||
|
a Vega program is a single Windows process that has multiple threads in its context. A thread is the basic unit to which the operating system allocates processor time. To maximize performance on a given machine, the user can configure Vega to run in a variety of multithreading modes. The three main Vega threads application (APP), CULL, DRAW can be performed as a single thread, as two threads in any combination, or as three separate threads. You may also select to have a separate thread for intersection processing, a thread for database loading, and another thread for light point calculations. The database loading thread is only needed when paging geometry using Large Area Database Management (LADBM), or when doing it yourself. To select a multithreading mode, use vgProp to set VGSYS_MPMODE to one of the following:
The user may control which processors (CPUs) the threads run on. Draw CPUs and priorities are set as properties of a window. Cull CPUs and priorities are set as properties of a channel. Light point CPUs and priorities are also set as properties of a channel. Set the app CPU by setting the vgSystem property VGSYS_APPCPU to the appropriate CPU number. The CPU numbers are in the range 0 to the number of CPUs on the system minus one. The default value -1 means no particular CPU is assigned, i.e., the operating system will determine which CPU to use each time that thread runs. If a CPU number is specified that does not exist on the particular machine that the Vega application is running on, a warning is logged, and it is treated as if a value of -1 was specified.
Vega process priority classes.
The Vega thread Priority Level has a range of 32 to 39, with
32 being the highest. The table below explains the meanings of the Vega
thread priority level values. Refer to the sections on SetThreadPriority
and Scheduling Priorities in the WIN32 Function manual
for more information on the thread priority levels. Vega thread priority levels.
For cross-platform compatibility, the numerical values used to specify the Vega priority classes and thread levels differ from the actual numerical values of those items used by Windows. Vega NT will automatically translate from the above numerical scheme to the correct values required by Windows
| ||||||||||||||||||||||||||||||||||||
|
Some of the Irix conventions and methods may be slightly strange to experienced Windows users. For examples in the case of VGWIN_DRAWPRI, priorities in Vega are still specified using a Unix-like scheme, where a numerical priority of 30 is highest priority, and larger numbers mean lower priorities. However, Windows uses a completely different numbering scheme for priorities. In cases like this, Vega NT uses the original, mapping the Unix-like priorities to comparable Windows priorities behind the scenes. Another difference between Vega on Irix and Vega NT is apparent from the VGWIN_DRAWPRI example. On an Irix , Vega and OpenGL Performer will spawn separate Processes to split up the work in a simulation application. Under Vega NT thee separate processes are separate threads running under a single Vega NT Process. While in most cases the LynX GUI has been modified to reflect this change, the names of properties have not been changed, and so may seem slightly off in some cases. Vega for Irix is layered on top of Irix's OpenGL Performer; In the Performer library, all data structures and routine names begin with a lower-case pf. The purpose of some Vega API calls are to return pointers to scene graph nodes so that user code can directly manipulate them. For example, the Vega API call vgGetDSPfObj returns a pfNode* pointer. Vega NT has type deffed pfNode to be an appropriate data structure in the Jolt scene graph management library. There are many examples of where Vega NT defines a data structure similar to one defined in the Performer library, and for ease of porting, has type deffed this data structure to have the same name as the corresponding Performer data structures On Windows the coordinates are specified the following the Performer convention, with the Y coordinate measured from the bottom of the screen, while Windows specifies Y coordinates from the top of the screen. When specifying directories or file names forward slashes can be used in anyplace that a backslash is normally used. Vega NT will translate to backslashes when needed When running Vega on an Irix system, logging messages are sent to stdout, and appear in the shell that started Vega. Under Vega NT, if the Vega application is a console application then the logging messages will appear on the console. However, Windows applications are not required to have a console. For "normal" Windows applications or MFC-based applications, Vega NT provides some additional API calls to create a console window for the logging messages (see vgWin.h) | ||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||
|
| ||||||||||||||||||||||||||||||||||||
|
Vega ships with set of Example programs and ADF's that are described in the Vega Programmers are typically installed to: |