pyvista.Property.diffuse#

property Property.diffuse: float[source]#

Return or set the diffuse lighting coefficient.

Default pyvista.plotting.themes._LightingConfig.diffuse.

This is the scattering of light by reflection or transmission. Diffuse reflection results when light strikes an irregular surface such as a frosted window or the surface of a frosted or coated light bulb. Must be between 0 and 1.

Examples

>>> import pyvista as pv
>>> prop = pv.Property()
>>> prop.diffuse = 0.2
>>> prop.diffuse
0.2

Visualize default diffuse light.

>>> prop.diffuse = 1.0
>>> prop.plot()
../../../_images/pyvista-Property-diffuse-1_00_00.png

Visualize diffuse at 0.5.

>>> prop.diffuse = 0.5
>>> prop.plot()
../../../_images/pyvista-Property-diffuse-1_01_00.png

Visualize diffuse at 0.0.

>>> prop.diffuse = 0.0
>>> prop.plot()
../../../_images/pyvista-Property-diffuse-1_02_00.png