Skip to content

Commit 79b82a9

Browse files
committed
Set private attributes in Effect class
1 parent 70269c2 commit 79b82a9

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

demosys/effects/managers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def pre_load(self):
7171
# If an effect was specified in the initializer, find it
7272
if self.effect_module:
7373
for effect in effect_list:
74-
if effect.name == self.effect_module:
74+
if effect._name == self.effect_module:
7575
self.active_effect = effect
7676
else:
7777
# Otherwise we look just grab the first effect

demosys/view/controller.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,15 +39,15 @@ def run(manager=None):
3939
print("Loader started at", glfw.get_time())
4040

4141
# Inject attributes into the base Effect class
42-
Effect.window_width = context.WINDOW.buffer_width
43-
Effect.window_height = context.WINDOW.buffer_height
44-
Effect.window_aspect = context.WINDOW.aspect_ratio
45-
Effect.ctx = context.ctx()
42+
Effect._window_width = context.WINDOW.buffer_width
43+
Effect._window_height = context.WINDOW.buffer_height
44+
Effect._window_aspect = context.WINDOW.aspect_ratio
45+
Effect._ctx = context.ctx()
4646

4747
# Set up the default system camera
4848
global CAMERA
4949
CAMERA = camera.SystemCamera(aspect=context.WINDOW.aspect_ratio, fov=60.0, near=1, far=1000)
50-
Effect.sys_camera = CAMERA
50+
Effect._sys_camera = CAMERA
5151

5252
# Initialize Effects
5353
if not manager.pre_load():

0 commit comments

Comments
 (0)