Glide supports two forms of multiple Voodoo Graphics subsystem support: multiple Voodoo Graphics subsystems driving multiple displays and two Voodoo Graphics subsystems driving a single display.
1Selecting Voodoo Graphics Units
At any given moment, only a single Voodoo Graphics subsystem is active. The grSstSelect(), presented above, activates a specific unit. All Glide functions, with the exception of the grGlide family and grSstSelect(), operate on only the currently active Voodoo Graphics subsystem. Note that the global Glide state is bound to each Voodoo Graphics independently. So, to set the constant color in each Voodoo Graphics unit to the same value, for example, you must write a loop that selects each one in turn and sets the color, as shown in Example Getting Started.2.
Example Getting Started.2 Setting a state variable in all Voodoo Graphics subsystems.
Each Voodoo Graphics subsystem has its own version of the Glide state variables, including a constant color value that will be used to clear the screen. The constant color is zero by default. The code fragment below cycles through all the Voodoo Graphics units found by a previous call to grSstQueryHardware(), setting the constant color to black.
GrHwConfiguration hwconfig;
for ( I = 0; I < hwconfig.num_sst; I++ )
{
grSstSelect( I );
grConstantColorValue( ~0 ); /* only affects SST “I” */
}
grSstWinOpen() must be called once for each Voodoo Graphics subsystem that will be used. Note that two Voodoo Graphics subsystems linked together in a scanline interleaving configuration are treated in software as a single Voodoo Graphics subsystem.
3Scanline Interleaved Voodoo Graphics Units
Two Voodoo Graphics subsystems can be wired together in a configuration known as scanline interleaving, which effectively doubles rasterization performance. From an application’s perspective, two Voodoo Graphics subsystems in a scanline-interleaved configuration are treated as if a single Voodoo Graphics subsystem is installed in the system, including during Voodoo Graphics selection, initialization, state management, texture download, etc.
Share with your friends: |