Partager via


ITileEngineGraphicsDevice::Lock (Windows Embedded CE 6.0)

1/6/2010

This function locks access to the ITileEngineGraphicsDevice interface, which makes it possible for your thread to access the display driver without interference from other threads in the same process.

Syntax

HRESULT Lock();

Return Value

The following table shows the possible return values.

Value

Description

S_OK

Function completed successfully.

Remarks

You can implement the ITileEngineGraphicsDevice::Lock and ITileEngineGraphicsDevice::Unlock functions to serialize access to the ITileEngineGraphicsDevice interface, if needed. For example, most OpenGL ES drivers are not thread-safe. If both ITileEngineGraphicsDevice (from Internet Explorer Embedded) and ICustomGraphicsDevice (from xxxrframeworkextxx) call OpenGL ES, the two classes should synchronize with a critical section or mutex object.

If the underlying graphics hardware does not need to be protected from concurrent access, you can implement the Lock and Unlock functions to immediately return S_OK.

Requirements

Header TileEngineRenderPlugin.h
Library TileEngineRenderPlugin.lib

See Also

Reference

ITileEngineGraphicsDevice
ITileEngineGraphicsDevice::Unlock

Other Resources

Customizing the Browser for Graphics Hardware