mmal: use COMMON_RESOLUTIONS
authorCalin Crisan <ccrisan@gmail.com>
Mon, 30 Oct 2017 20:46:33 +0000 (22:46 +0200)
committerCalin Crisan <ccrisan@gmail.com>
Mon, 30 Oct 2017 20:46:33 +0000 (22:46 +0200)
motioneye/config.py
motioneye/utils.py

index 5100c95cdd063ee0d29197982f4d6637823253fd..39099aebf519f65f857c79c49c6209087abcef47 100644 (file)
@@ -1245,7 +1245,7 @@ def motion_camera_dict_to_ui(data):
         ui['device_url'] = data['mmalcam_name']
         ui['proto'] = 'mmal'
         
-        resolutions = utils.RPI_MMAL_RESOLUTIONS
+        resolutions = utils.COMMON_RESOLUTIONS
         resolutions = [r for r in resolutions if motionctl.resolution_is_valid(*r)]
         ui['available_resolutions'] = [(str(w) + 'x' + str(h)) for (w, h) in resolutions]
         ui['resolution'] = str(data['width']) + 'x' + str(data['height'])
index afab32c373c7ebabe207a4c085d73a0d0313b7cd..b4cfb63ffef758dd4403b2b54227bcc46140c915 100644 (file)
@@ -67,15 +67,6 @@ COMMON_RESOLUTIONS = [
     (1920, 1080)
 ]
 
-RPI_MMAL_RESOLUTIONS = [
-    (640, 480),
-    (1280, 720),
-    (1280, 960),
-    (1920, 1080),
-    (1920, 1088),
-    (2592, 1944)
-]
-
 
 def _(x):
     return x  # this could later be replaced by a proper translate function