Share via


TKQueryPhysicsEngine

4/8/2010

This function returns the state of the physics engine. If the engine mode is default mode, the engine state is based on the current time indicated by the system clock. If the engine mode is PHYSICSENGINE_FLAG_USERTIME then the engine state is based on the time specified in the most recent call to TKSetPhysicsEngineUserTime.

Syntax

HRESULT TKQueryPhysicsEngine(
    HPHYSICSENGINE hEngine,
   __out PHYSICSENGINESTATE* pState
);

Parameters

  • hEngine
    [in] A handle to a physics engine object.
  • pState
    [out] A pointer to a PHYSICSENGINESTATE structure that indicates the state of the physics engine.

Return Value

The return value can contain the following values. It may also return other values and should be tested using the SUCCEEDED and FAILED macros.

  • S_OK
    Indicates that the physics engine state is successfully returned.
  • E_INVALIDARG
    Indicates that a parameter is invalid.
  • E_UNEXPECTED
    Indicates that the physics engine object is not initialized.

Requirements

Header GesturePhysicsEngine.h

See Also

Other Resources

Physics Engine Functions (DTK)