---
title: "WebModule"
description: "API documentation for WebModule"
url: https://developer.disguise.one/python-api/docs/webmodule/
---

# WebModule

A Module allowing the user to render webpages with Chromium. Grabs the texture stream from its  
underlying WebBrowser object that does the actual interfacing with Chromium.

Also allows for the sending of JavaScript commands and float/string parameters to the web page via its layer.

Base class (inherits properties and methods): _[Module](/python-api/docs/module#module)_

## Properties

#### **Command** : _[WebCommand](/python-api/docs/webcommand#webcommand)_

The currently selected command to send to the web browser.

#### **Name\_1** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 1](x)

_Category: Custom Parameters  
UserName: Name 1_

#### **Name\_2** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 2](x)

_Category: Custom Parameters  
UserName: Name 2_

#### **Name\_3** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 3](x)

_Category: Custom Parameters  
UserName: Name 3_

#### **Name\_4** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 4](x)

_Category: Custom Parameters  
UserName: Name 4_

#### **Name\_5** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 5](x)

_Category: Custom Parameters  
UserName: Name 5_

#### **Name\_6** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 6](x)

_Category: Custom Parameters  
UserName: Name 6_

#### **Name\_7** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 7](x)

_Category: Custom Parameters  
UserName: Name 7_

#### **Name\_8** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[Name 8](x)

_Category: Custom Parameters  
UserName: Name 8_

#### **String\_1** : _str_

A string value passed into the function String Name 1 each frame

_Category: Custom Parameters  
UserName: String 1_

#### **String\_2** : _str_

A string value passed into the function String Name 2 each frame

_Category: Custom Parameters  
UserName: String 2_

#### **String\_3** : _str_

A string value passed into the function String Name 3 each frame

_Category: Custom Parameters  
UserName: String 3_

#### **String\_4** : _str_

A string value passed into the function String Name 4 each frame

_Category: Custom Parameters  
UserName: String 4_

#### **String\_5** : _str_

A string value passed into the function String Name 5 each frame

_Category: Custom Parameters  
UserName: String 5_

#### **String\_6** : _str_

A string value passed into the function String Name 6 each frame

_Category: Custom Parameters  
UserName: String 6_

#### **String\_7** : _str_

A string value passed into the function String Name 7 each frame

_Category: Custom Parameters  
UserName: String 7_

#### **String\_8** : _str_

A string value passed into the function String Name 8 each frame

_Category: Custom Parameters  
UserName: String 8_

#### **String\_Name\_1** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 1](x)

_Category: Custom Parameters  
UserName: String Name 1_

#### **String\_Name\_2** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 2](x)

_Category: Custom Parameters  
UserName: String Name 2_

#### **String\_Name\_3** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 3](x)

_Category: Custom Parameters  
UserName: String Name 3_

#### **String\_Name\_4** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 4](x)

_Category: Custom Parameters  
UserName: String Name 4_

#### **String\_Name\_5** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 5](x)

_Category: Custom Parameters  
UserName: String Name 5_

#### **String\_Name\_6** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 6](x)

_Category: Custom Parameters  
UserName: String Name 6_

#### **String\_Name\_7** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 7](x)

_Category: Custom Parameters  
UserName: String Name 7_

#### **String\_Name\_8** : _str_

The name of a JavaScript function to call in the browser every frame.  
The function name in JavaScript will be d3.[String Name 8](x)

_Category: Custom Parameters  
UserName: String Name 8_

#### **Universes** : _str_

A comma separated list of DMX universes. Universes specified here will pass DMX data through to the browser.

_Category: DMX Parameters  
UserName: Universes (1-based)_

#### **Value\_1** : _float_

A float value passed into the function Name 1 each frame

_Category: Custom Parameters  
UserName: Value 1_

#### **Value\_2** : _float_

A float value passed into the function Name 2 each frame

_Category: Custom Parameters  
UserName: Value 2_

#### **Value\_3** : _float_

A float value passed into the function Name 3 each frame

_Category: Custom Parameters  
UserName: Value 3_

#### **Value\_4** : _float_

A float value passed into the function Name 4 each frame

_Category: Custom Parameters  
UserName: Value 4_

#### **Value\_5** : _float_

A float value passed into the function Name 5 each frame

_Category: Custom Parameters  
UserName: Value 5_

#### **Value\_6** : _float_

A float value passed into the function Name 6 each frame

_Category: Custom Parameters  
UserName: Value 6_

#### **Value\_7** : _float_

A float value passed into the function Name 7 each frame

_Category: Custom Parameters  
UserName: Value 7_

#### **Value\_8** : _float_

A float value passed into the function Name 8 each frame

_Category: Custom Parameters  
UserName: Value 8_

#### **bookmark** : _[WebBookmark](/python-api/docs/webbookmark#webbookmark)_

The currently loaded web bookmark.

_UserName: Bookmark_

#### **fade\_up\_time** : _float_

The time it takes for the web module to fade up from a completely transparent state.

_UserName: Fade up time_

#### **framerateFraction** : _int_

The fraction of the framerate the web browser renders at. Can help performance with particularly large resolutions.  
Does not help when in low latency output modes.

_Options: {0: ‘1’, 1: ‘1/2’, 2: ‘1/3’, 3: ‘1/4’}  
UserName: Framerate fraction_

#### **height** : _int_

The height of the web view in pixels.

_Category: Size  
UserName: Height_

#### **size\_mode** : _int_

The sizing mode of the web view.

_Options: {0: ‘Match Mapping’, 1: ‘Custom’}  
Category: Size  
UserName: Size mode_

#### **width** : _int_

The width of the web view in pixels.

_Category: Size  
UserName: Width_

## Methods

#### **clearCache**(self)

Clears the cache of the WebModule.

#### **greySizeFields**(self) -> _bool_

Returns whether the browser size fields should be greyed out (size mode is set to canvas).

**Returns** True if the browser size mode is set to canvas, False otherwise.

#### **reset**(self)

Resets the WebModule to its initial state.

#### **webBrowser**(self) -> _WebBrowser_

Returns the underlying WebBrowser instance.

**Returns** A shared pointer to the WebBrowser object.
