ZennoLab Assemblies Documentation
WebGLPreferences Property
Example 
ZennoLab.CommandCenter Namespace > Instance Class : WebGLPreferences Property
Gets the WebGLPreferences object that allows you to edit webgl settings.
Syntax
public WebGLPreferences WebGLPreferences {get;}

Property Value

Type: ZennoLab.CommandCenter.AudioPreferences

The AudioPreferences object.

Example
The following example uses the WebGLPreferences property.
// set Chrome useragent
instance.SetHeader(ZennoLab.InterfacesLibrary.Enums.Browser.NavigatorField.UserAgent, "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.84 Safari/537.36");
// set webgl context params
instance.WebGLPreferences.Set(ZennoLab.InterfacesLibrary.Enums.Browser.WebGLPreference.Renderer, "WebKit WebGL");
instance.WebGLPreferences.Set(ZennoLab.InterfacesLibrary.Enums.Browser.WebGLPreference.Vendor, "WebKit");
instance.WebGLPreferences.Set(ZennoLab.InterfacesLibrary.Enums.Browser.WebGLPreference.Version, "WebGL 1.0 (OpenGL ES 2.0 Chromium)");
instance.WebGLPreferences.Set(ZennoLab.InterfacesLibrary.Enums.Browser.WebGLPreference.ShadingLanguageVersion, "WebGL GLSL ES 1.0 (OpenGL ES GLSL ES 1.0 Chromium)");
instance.WebGLPreferences.Set(ZennoLab.InterfacesLibrary.Enums.Browser.WebGLPreference.UnmaskedRenderer, "Google Inc.");
instance.WebGLPreferences.Set(ZennoLab.InterfacesLibrary.Enums.Browser.WebGLPreference.UnmaskedVendor, "ANGLE (NVIDIA GeForce GT 630 Direct3D11 vs_5_0 ps_5_0)");
Requirements

Target Platforms: Desktop: Windows XP SP3 and older. Server: Windows Server 2003 and older.

See Also

Reference

Instance Class
Instance Members