The Steam HTML Surface API enables the display and render of HTML-based pages directly in a game or application. It is built upon the Chromium Embedded Framework and supports HTML5 markup.
Getting Started with ISteamHTMLSurface
interface is implemented in
and can be found in the
folder in the Steamworks SDK
. The interface can be accessed through the
There are a series of callbacks that can be setup to determine when certain browser events occur (see
for a complete list). The Steamworks Example demonstrates implementing and using some of these callbacks in
To complete a simple HTML Surface implementation, a CallBack for ISteamHTMLSurface::HTML_NeedsPaint_t
must be implemented to retrieve the image data for rendering.
Steamworks Example Implementation
The Steamworks API Example Application (SpaceWar)
that ships with the SDK contains a basic implementation of the Steam HTML Surface API. Upon launching the sample, scroll down and select HTML Page. The Steam Community home page will then load in the game.
You can find the integration of the Steam HTML Surface API in the
NOTE: Interactivity with the web page has not been implemented in the example at this time.