Configure how the HTML5 plugin renders a page and places it over video: destination geometry, opacity, browser viewport, page capabilities, storage and diagnostics. Set these properties on the MFOverlayHTMLClass instance that processes your video, not on the preview or the video source.
The same property calls are available with MFORMATSLib and MPLATFORMLib. They configure the SDK plugin, not CSS or MLCG template data. For pipeline integration, see HTML5 Overlay: getting started; shared deployment requirements are in Before you start.
Apply properties at the correct lifecycle stage
// html is your pipeline's MFOverlayHTMLClass instance.
// Browser options: set before the first BrowserPageLoad.
html.PropsSet("cef.web_security", "true");
html.PropsSet("cef.mute_audio", "true");
html.PropsSet("transparency", "true");
// Composition: these can also change at runtime.
html.PropsSet("dst.x", "0%");
html.PropsSet("dst.y", "0%");
html.PropsSet("dst.w", "100%");
html.PropsSet("dst.h", "100%");
html.PropsSet("dst.alpha", "50%");
string alpha;
html.PropsGet("dst.alpha", out alpha);
- Runtime composition includes destination geometry, opacity and crop. It does not select the source video format.
-
Browser recreation is triggered by changes to settings such as
webGL.enabled,cef.mute_audio,cef.web_security,cef.default_cssandscrollbars.enabled. These are not animation controls: changing them can discard page state. - CEF initialization settings include cache/profile paths, logging, debugging and additional switches. Set them before the first page load. A page reload is not CEF reinitialization. For later changes, stop using the browser, close/recreate it deliberately, reapply settings, then load the page.
-
Read back and verify.
PropsGetconfirms the stored value; actual frames, browser diagnostics and page behavior confirm its effect. Available options depend on the installed SDK and CEF build.
Composition and transparency
| Property | Value format | Purpose and lifecycle |
|---|---|---|
dst.x, dst.y
|
Pixels or percentage, for example 120 or 10%
|
Top-left position of the overlay in the destination video frame. Runtime composition controls. |
dst.w, dst.h
|
Pixels or percentage, for example 960 or 50%
|
Destination width and height. Use explicit 100% values for a full-frame overlay. Historical zero values select an automatic extent, not a zero-sized overlay. |
dst.alpha |
Opacity ratio or percentage, for example 0.5 or 50%
|
Opacity of the complete overlay: 0% is invisible and 100% is fully opaque where the page has content. Runtime control; it does not stop the page or its animations. |
dst.border_width |
Non-negative integer pixels | Optional border around the destination area. 0 disables it. Border drawing adds processing; leave it off unless required. |
dst.border_color |
SDK color string, for example white
|
Color of that border. It does not change the HTML background or CSS. |
transparency |
auto, true, false
|
Plugin transparency mode. true is appropriate for an overlay page designed with a transparent background. The page must also avoid painting an opaque background. |
interlacing |
true or false
|
Interlaced-page processing for interlaced output. This does not convert progressive source video into an interlaced video format. Validate motion on the target field order and SDK build. |
Destination geometry is resolved against the video frame, not the size of the preview control. The implementation can align coordinates for the negotiated pixel format, so do not rely on subpixel placement at the composition boundary.
Page viewport, crop, and scrolling
| Property | Value format | Purpose and lifecycle |
|---|---|---|
zoom |
Positive scale, usually a percentage such as 100% or 125%
|
Browser page zoom. It changes page layout and is not the same as changing the destination rectangle. |
crop |
left, top, right, bottom; pixels or percentages |
Margins removed from the rendered page. Examples: 50, 0, 50, 0 or 10%, 0, 10%, 0. Cropping participates in page-size calculation; it is not CSS padding. Validate the resulting viewport and visible area. |
width.min, width.max
|
Integer pixels | Constraints used while calculating browser viewport width from the requested overlay size. These are decimal pixel values, not registry hexadecimal strings. They are not output-video format controls. |
width, height
|
Positive integer pixels | Advanced explicit browser viewport dimensions in builds that expose these properties. Leave automatic sizing in place unless the page needs a fixed design viewport; check support on the installed SDK. |
scrollbars.enabled |
true or false
|
Controls scrollbar display. Set before page load; changing it can recreate the browser. This is not a ticker-direction or ticker-message setting. |
scroll.speed_h, scroll.speed_v
|
Signed decimal increment; 0 stops automatic scrolling |
Horizontal/vertical document-scroll increments per plugin frame-processing update, not pixels per second. Positive values increase the document scroll position. Effective speed depends on processing cadence and page scrollability; use page code for a time-based ticker. |
For an MLCG ticker, configure its messages and motion through MLCG. Scrolling the browser document with these properties is a different operation.
Browser capabilities and page audio
| Property | Value format | Purpose and lifecycle |
|---|---|---|
cef.mute_audio |
true or false
|
Mutes audio generated by the web page. Set before browser initialization; changing it can recreate the browser. This is separate from muting the SDK preview or the source video's audio. |
webGL.enabled |
true or false
|
Controls WebGL capability. Set before page load. It does not by itself select an all-GPU video path or guarantee higher throughput. |
media_stream.enabled |
true or false
|
Enables browser media-stream capability for pages that use it. Set before page load. It does not open an SDK live source; permissions, devices, page security and CEF support still matter. |
js_dialogs.enabled |
true or false
|
Controls JavaScript dialogs such as alerts. Keep dialogs disabled for unattended playout; use application events or logs for diagnostics. |
cef.default_css |
CSS file path or stylesheet URL | Additional stylesheet loaded for pages. Set before page load; changing it can recreate the browser. For an already loaded page, BrowserCSSSet accepts CSS text; see browser control and events. |
cef.web_security |
true or false
|
Controls browser web-security restrictions. Use true and solve cross-origin access with correct hosting and CORS. Legacy installations may inherit permissive settings; do not copy those defaults into new applications. Set before initialization. |
Load only trusted pages when exposing the cef_plugin application bridge. Web-security restrictions are not an authorization layer for your application's commands.
Page audio can be part of the SDK output. Supporting plugin builds capture CEF audio as PCM, attach it to rendered SDK frames and can mix it into the processed video frame; page audio is not necessarily limited to the operating system's audio output. This is build-, page- and codec-dependent, not a promise that every page or recorder receives audio automatically. Default overlay mixing can also depend on destination area and dst.alpha. If page audio is required, set cef.mute_audio to false before browser initialization and verify PCM samples, channel layout and sample rate in the processed frames and the actual recording/output. Check page autoplay and downstream audio configuration separately. Keep cef.mute_audio set to true for visual-only graphics.
Typical graphics page. Enable WebGL only if the page uses it, mute browser audio if the overlay is visual-only, and keep web security enabled. Host page resources with appropriate CORS rather than disabling security to make a failing request work. These choices do not change the source video's audio or guarantee an all-GPU path.
// Before BrowserPageLoad; choose capabilities your page actually needs.
html.PropsSet("webGL.enabled", "true");
html.PropsSet("cef.mute_audio", "true");
html.PropsSet("cef.web_security", "true");
html.PropsSet("js_dialogs.enabled", "false");
Cache, logs, and advanced configuration
| Property | Value format | Purpose and lifecycle |
|---|---|---|
cef.cache_path |
Absolute writable directory path | Persistent browser-profile/cache location. Configure before initialization. A cache can avoid some repeated downloads but does not preload a template or remove all page-startup cost. Persistent storage may retain cookies and page data; plan its lifetime accordingly. |
cef.root_cache_path |
Absolute writable directory path; newer builds only | CEF root/profile-data location where supported. Cache paths must follow the bundled CEF version's relationship rules. Do not point independent running browser processes at the same profile directory. Older SDK builds may not expose this option. |
cef.log_file |
Absolute file path in a writable directory | CEF diagnostic log destination. Set before initialization and protect the file: URLs and page diagnostics may contain sensitive information. |
cef.log_severity |
Integer | Plugin mapping: 0 disables CEF logging; 1 verbose, 2 info, 3 warning, 4 error, 5 fatal. A non-empty cef.log_file is also required by this plugin. Use verbose logging temporarily, not as a performance setting. |
cef.remote_debugging_port |
Integer port 1024–65535; 0 leaves this option disabled |
Developer-only browser inspection where supported. Set before initialization. Keep it disabled in production unless an explicitly secured diagnostic workflow requires it. |
external_process |
true or false
|
Chooses whether the plugin's browser host is created externally. This is not a “single-process Chromium” switch; CEF can still have renderer/GPU subprocesses. Set before initialization and change only after testing the complete deployment. |
object_name |
String | Name used for plugin identification/diagnostics. Set before page load; changing it can recreate the browser. |
register_object |
true or false
|
Registers the plugin for SDK object/statistics discovery. It is not COM DLL registration or an application account setting. Set before page load. |
cef.config_string |
CEF/Chromium command-line switch string | Expert configuration applied at CEF initialization. Switch availability and effects depend on the bundled CEF version. Do not paste arbitrary “performance flag” lists or security-disabling flags into production; benchmark a specific change and keep a known-good baseline. |
Keep a browser profile and capture useful logs
Use an application-owned writable folder, not the SDK installation directory. This example enables a persistent profile and warning/error logging. Apply it before the first page load; restore your normal logging level after diagnosis.
// Use a separate profile directory for each concurrently running CEF host.
string profile = System.IO.Path.Combine(
Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData),
@"MyCompany\MyVideoApp\HtmlProfile");
System.IO.Directory.CreateDirectory(profile);
html.PropsSet("cef.cache_path", profile);
html.PropsSet("cef.log_file", System.IO.Path.Combine(profile, "cef.log"));
html.PropsSet("cef.log_severity", "3");
A persistent profile can retain page storage and downloaded resources; it is not template preloading. Give independently running CEF hosts separate profile directories. In newer CEF builds, cef.root_cache_path controls the common profile root and must be compatible with cef.cache_path; do not add that property to an older SDK without checking support. See the version-specific CEF settings reference and use the documentation matching the runtime delivered with your SDK. A profile does not share a running overlay between applications.
Inspect a page during development
// Before the first BrowserPageLoad, in a local development build only.
html.PropsSet("cef.remote_debugging_port", "9222");
Open chrome://inspect/#devices in Chrome and discover localhost:9222 to inspect the embedded page's network requests, console and performance. Inspection grants control of the page: use a trusted local machine, restrict network access and never expose this port as a public service. Set the option back to 0 before browser initialization in production. An already running debug listener requires browser/host recreation to disable it.
Use additional Chromium switches only for a measured requirement
cef.config_string is a plugin-parsed list, not a shell command or a JSON object. Entries are separated by whitespace, commas or semicolons. A plain switch name is forwarded to AppendSwitch; a name=value entry goes to AppendSwitchWithValue. Prefer the named SDK property when one exists—for example, cef.remote_debugging_port instead of injecting a debugging flag. The parser is not a general shell-quoting parser; do not assume it can preserve separators or multiple equals signs inside a switch value.
One conditional use case is a trusted application page that must autoplay HTML audio/video without a user click. Chromium defines the following policy switch; verify it on your delivered runtime, rather than adding it as a default for every overlay:
// Optional: before CEF initialization, only when the page requires it.
html.PropsSet("cef.config_string", "autoplay-policy=no-user-gesture-required");
This changes browser media autoplay policy, not MLCG animation timing. It does not add codec/DRM support or unmute audio when cef.mute_audio is enabled. The switch and policy value are defined in Chromium's media switches. Retain any other required switches when constructing your configuration: this assignment replaces the property string.
Switch availability, defaults and GPU behavior vary by runtime. Verify an individual switch in the matching CEF command-line API and Chromium source, apply it before CEF initialization, then compare the same page and video workload against a clean baseline. Disabling web security, GPU synchronization or browser safety checks is not a general performance recipe.
Prefer per-instance settings. Older installations also read creation defaults from HKEY_CURRENT_USER\Software\Medialooks\HTMLOverlay. Those values affect the current Windows user and do not reconfigure an already running browser automatically.
Legacy options
adobe_flash.enabled exists in older property sets for historical Flash integrations. It is not a supported way to add Flash to modern Chromium/CEF and should not be enabled in new HTML5 applications. Migrate the page to HTML/CSS/JavaScript instead.
SDK samples for trying properties
These full paths refer to a default x64 installation; a custom installation can use a different root.
| Sample | Executable | C# project |
|---|---|---|
| MFormats — File Playback Sample x64 | C:\Program Files (x86)\Medialooks\MFormats SDK\Samples\C#\Sample File Playback\bin\x64\Debug\Sample File Playback.exe |
C:\Program Files (x86)\Medialooks\MFormats SDK\Samples\C#\Sample File Playback\Sample File Playback.csproj |
| MPlatform — Advanced Playlist Sample x64 | C:\Program Files (x86)\Medialooks\MPlatform SDK\Samples Advanced\C#\Playlist Sample\bin\x64\Debug\Playlist Sample.exe |
C:\Program Files (x86)\Medialooks\MPlatform SDK\Samples Advanced\C#\Playlist Sample\Playlist Sample.csproj |
Play a video, enter a page URL beside HTML overlay and enable that checkbox. Click its Props button—not CG Props—then edit values in Properties. The window also provides a preview, a page-address box, Init Source, a local-file ... button and Presets. After editing the main sample's URL while HTML overlay is enabled, press Enter to navigate.
Verify a configuration change
- Record the installed SDK version, browser runtime and current property values.
- Apply initialization options before the first page load. Recreate the browser/host deliberately when changing CEF initialization settings; reloading a page alone is insufficient.
- Check page-load errors, asset access and actual rendered frames at the required video format.
- For performance tests, compare the same page, video, format and workload. WebGL, cache or a Chromium switch alone does not establish a frame-rate guarantee.
Related: Browser control and events · HTML5 as a live source · MLCG HTML REST samples · MLCG REST Client for C#. For an older runtime, the CEF 120.2 settings reference is available separately; it is not the current version for every SDK.
Still have questions?
Tell us what didn’t work or what you’d like clarified.