Queues commands from a command list onto a device.
public:
void ExecuteCommandList(
ID3D11CommandList *pCommandList,
BOOL RestoreContextState
)
pCommandList
Type: ID3D11CommandList *
[in] A pointer to an ID3D11CommandList interface that encapsulates a command list.
RestoreContextState
Type: BOOLÂ
A Boolean flag that determines whether the immediate context state is saved prior to and restored after the execution of a command list. Use TRUE to indicate that the runtime needs to save and restore the state. Use FALSE to indicate that no state shall be saved or restored, which causes the immediate context to return to its default state after the command list executes. Applications should typically use FALSE unless they will restore the state to be nearly equivalent to the state that the runtime would restore if TRUE were passed. When applications use FALSE, they can avoid unnecessary and inefficient state transitions.
This parameter must be set to FALSE if the method is being used with Draw Bundles.
Use this method to play back a command list that was recorded by a deferred context on any thread.
This method performs some runtime validation related to queries. Queries that are begun in a device context cannot be manipulated indirectly by executing a command list (that is, Begin or End was invoked against the same query by the deferred context which generated the command list). If such a condition occurs, the ExecuteCommandList method does not execute the command list. However, the state of the device context is still maintained, as would be expected (ID3D11DeviceContext::ClearState is performed, unless the application indicates to preserve the device context state).
Header: Declared in d3d11_x.h (d3d11.h on other Windows platforms).
Library: Use d3d11_x.lib (d3d11.lib on other Windows platforms).