Skip to content
Squareys edited this page Dec 22, 2015 · 1 revision

When enabled, the exporter will export the Worlds ambient color similar to:

// ...
Metric (key = "up") {string {"z"}}
Extension (applic = "Blender", type = "AmbientColor")
{
	float[3] {{0.5, 0.4, 0.3}}
}
// ...

and the ambient value of materials as:

Material $material1
{
	Name {string {"Material"}}

	Color (attrib = "diffuse") {float[3] {{0.64, 0.64, 0.64}}}
	Color (attrib = "specular") {float[3] {{0.5, 0.5, 0.5}}}
	Param (attrib = "specular_power") {float {50}}
	Param (attrib = "ambient_factor") {float {0.5}} // <--
}

Ambient Colors

AmbientColor

The AmbientColor extension structure will always appear in top level and contain exactly one float array of length 3, representing the rgb values of the worlds ambient color.

ambient_factor

Default 1.0f (will not be exported, if the materials ambient factor is set to this value). This parameter is not specified in the OpenGEX Specification. It is however specified that importers should skip unknown Param structures, so this will not cause any trouble with importers not supporting this extension.