icetCreateContext3
Usage
#include <IceT.h>
| IceTContext icetCreateContext( | IceTCommunicator | comm ); |
Overview
The icetCreateContext function creates a new context, makes it current, and returns a handle to the new context. The handle returned is of type IceTContext. This is an opaque type that should not be handled directly, but rather simply passed to other IceT functions.
Like OpenGL ,the IceT engine behaves like a large state machine. The parameters for engine operation is held in the current state. The entire state is encapsulated in a context. Each new context contains its own state.
It is therefore possible to change the entire current state of IceT by simply switching contexts. Switching contexts is much faster, and often more convenient, than trying to change many state parameters.
Errors
None.
Warnings
None.
Notes
icetCreateContext duplicates the communicator comm. Thus, to avoid deadlocks on certain implementations (such as MPI), the user level program should call icetCreateContext on all processes with the same comm object at about the same time.
Releases
8 releases since Debian 6.0 (Squeeze); the text changed 3 times.