Skip to content

Commit b0ce4c7

Browse files
authored
Update calls to use tuples for colors (#118)
1 parent 9519a74 commit b0ce4c7

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

crates/processing_pyo3/examples/lights.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,19 @@ def setup():
77
mode_3d()
88

99
# Directional Light
10-
dir_light = create_directional_light(0.5, 0.24, 1.0, 1500.0)
10+
dir_light = create_directional_light((0.5, 0.24, 1.0), 1500.0)
1111

1212
# Point Lights
13-
point_light_a = create_point_light(1.0, 0.5, 0.25, 1000000.0, 200.0, 0.5)
13+
point_light_a = create_point_light((1.0, 0.5, 0.25), 1000000.0, 200.0, 0.5)
1414
point_light_a.position(-25.0, 5.0, 51.0)
1515
point_light_a.look_at(0.0, 0.0, 0.0)
1616

17-
point_light_b = create_point_light(0.0, 0.5, 0.75, 2000000.0, 200.0, 0.25)
17+
point_light_b = create_point_light((0.0, 0.5, 0.75), 2000000.0, 200.0, 0.25)
1818
point_light_b.position(0.0, 5.0, 50.5)
1919
point_light_b.look_at(0.0, 0.0, 0.0)
2020

2121
# Spot Light
22-
spot_light = create_spot_light(0.25, 0.8, 0.19, 15.0 * 1000000.0, 200.0, 0.84, 0.0, 0.7854)
22+
spot_light = create_spot_light((0.25, 0.8, 0.19), 15.0 * 1000000.0, 200.0, 0.84, 0.0, 0.7854)
2323
spot_light.position(40.0, 0.0, 70.0)
2424
spot_light.look_at(0.0, 0.0, 0.0)
2525

crates/processing_pyo3/examples/materials.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ def setup():
77
size(800, 600)
88
mode_3d()
99

10-
dir_light = create_directional_light(1.0, 0.98, 0.95, 1500.0)
11-
point_light = create_point_light(1.0, 1.0, 1.0, 100000.0, 800.0, 0.0)
10+
dir_light = create_directional_light((1.0, 0.98, 0.95), 1500.0)
11+
point_light = create_point_light((1.0, 1.0, 1.0), 100000.0, 800.0, 0.0)
1212
point_light.position(200.0, 200.0, 400.0)
1313

1414
mat = Material()

0 commit comments

Comments
 (0)