Module: config

API for the engine's global configuration.

Use the set()/get()
method to change/get the value of a property. Use the
reset() method to reset all properties to their
default state. Any change in configuration must occur before engine
initialization. Keep in mind that some of the properties are affected by the
quality profile and the user's hardware/browser. In the former case use the
P_CUSTOM profile in order to change such
properties.

Normally, the users should not alter these parameters.

Configuration Parameters Available

allow_cors

Boolean, allow cross-origin resource sharing.

allow_hidpi

Boolean, allow HIDPI mode on supported devices (use the
P_CUSTOM profile in order to change this parameter).

Boolean, enable postprocess-based anti-aliasing (use the
P_CUSTOM profile in order to change this parameter).

assets_dds_available

Boolean, allow the engine to use compressed DDS textures.

assets_gzip_available

Boolean, enable loading gzipped versions of json/bin/dds/pvr files. It's worth
doing it if gzip compression is not set up on a server. A gzipped file must be
placed near the original one and its name must be the same as the name of the
original file + the ".gz" extension. For example:

Boolean, cache all textures to prevent redundant resource requests and
speed up scene dynamic loading. Enabled by default. Note: this option affects
the dynamic loading functionality only, if it's your case and you have some
issues with GPU memory overloading consider disabling this option.

glow_materials

Boolean, enable glow materials.

gl_debug

Boolean, enable gl errors check. Very slow.

god_rays

Boolean, enable god rays.

is_mobile_device

Boolean, check mobile device. Read-only.

lod_leap_smooth_threshold

Number, the maximum amount of the camera movement (in meters) that
still can trigger a smooth transition during the LOD switching. Low values can
be useful to prevent noticeable smooth transitions while teleporting. High
values can be useful to keep smooth transitions for fast moving cameras
(e.g. flight simulators).

String, number of shadow border blur samples. It can be "16x", "8x" or "4x".

show_hud_debug_info

Boolean, show HUD with debug information.

smaa

Deprecated. Boolean, enable SMAA
anti-aliasing (use the P_CUSTOM
profile in order to change this parameter).

smaa_area_texture_path

Deprecated. String, path to the SMAA
"area" texture. If not specified, search in the directory with the engine's
sources.

smaa_search_texture_path

Deprecated. String, path to the SMAA
"search" texture. If not specified, search in the directory with the engine's
sources.

srgb_type

String, the quality of the "Linear sRGB" color conversions. Can be
one of the following: "SRGB_SIMPLE" - a bit faster, but less accurate, which
is especially noticeable for the dark tones; "SRGB_PROPER" - a bit slower,
but more precise.