diff --git a/src/examples/vision/joy/joy_detection_demo.py b/src/examples/vision/joy/joy_detection_demo.py index 91f0d871..6f33146e 100755 --- a/src/examples/vision/joy/joy_detection_demo.py +++ b/src/examples/vision/joy/joy_detection_demo.py @@ -263,7 +263,11 @@ def take_photo(): photographer.shoot(camera) # Blend the preview layer with the alpha value from the flags. - camera.start_preview(alpha=preview_alpha) + if preview_alpha > 0: + logger.info('Starting preview with alpha %d', preview_alpha) + camera.start_preview(alpha=preview_alpha) + else: + logger.info('Not starting preview, alpha 0') button = Button(23) button.when_pressed = take_photo