Py5Shape.get_emissive()#

Get the emissive color setting for one of a Py5Shape object’s vertices.

Examples#

example picture for get_emissive()
 1def setup():
 2    py5.size(100, 100, py5.P3D)
 3    py5.background(0)
 4    py5.directional_light(200, 200, 200, .5, 0, -1)
 5    py5.emissive(0, 50, 100)
 6    py5.no_stroke()
 7    s = py5.create_shape(py5.SPHERE, 30)
 8
 9    py5.shape(s, 50, 50)
10    emissive = s.get_emissive(0)
11    py5.println(py5.red(emissive), py5.green(emissive), py5.blue(emissive))

Description#

Get the emissive color setting for one of a Py5Shape object’s vertices. Use Py5Shape.set_emissive() to change the setting.

This method can only be used for a complete Py5Shape object, and never within a Py5Shape.begin_shape() and Py5Shape.end_shape() pair.

Underlying Processing method: PShape.getEmissive

Syntax#

get_emissive(index: int, /) -> int

Parameters#

  • index: int - vertex index

Updated on November 12, 2021 11:30:58am UTC