From 1b9cde00d95d1c75d65e831160f7e5fff9a01fca Mon Sep 17 00:00:00 2001 From: Sridhar Ramesh Date: Mon, 26 Feb 2018 11:47:37 -0800 Subject: [PATCH] Minor fix to camera.py, making SplitScreenCameras work again after some change to background handling made them crash --- camera/camera.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/camera/camera.py b/camera/camera.py index e4703ead..ef988f89 100644 --- a/camera/camera.py +++ b/camera/camera.py @@ -107,7 +107,7 @@ class Camera(object): def set_pixel_array(self, pixel_array, convert_from_floats = False): converted_array = self.convert_pixel_array(pixel_array, convert_from_floats) - if not hasattr(self, "pixel_array"): #TODO: And the shapes match? + if not (hasattr(self, "pixel_array") and self.pixel_array.shape == converted_array.shape): self.pixel_array = converted_array else: #Set in place