logging.debug('listing resolutions of device %(device)s...' % {'device': device})
resolutions = set()
- output = subprocess.check_output('v4l2-ctl -d %(device)s --list-formats-ext | grep -oE "[0-9]+x[0-9]+" || true' % {
+ output = subprocess.check_output('v4l2-ctl -d %(device)s --list-formats-ext | grep -vi stepwise | grep -oE "[0-9]+x[0-9]+" || true' % {
'device': device}, shell=True)
for pair in output.split('\n'):
width = int(width)
height = int(height)
+ if width < 96 or height < 96: # some reasonable minimal values
+ continue
+
resolutions.add((width, height))
logging.debug('found resolution %(width)sx%(height)s for device %(device)s' % {
}
/* also update the config stored in the camera frame div */
- Object.update($('div.camera-frame#camera' + cameraId)[0].config, cameraConfig);
+ var cameraFrame = $('div.camera-frame#camera' + cameraId);
+ if (cameraFrame.length) {
+ Object.update(cameraFrame[0].config, cameraConfig);
+ }
}
function pushPreview(control) {
<img class="main-loading-progress" src="{{STATIC_URL}}img/main-loading-progress.gif">
</div>
<div class="footer">
- <div class="copyright-note">copyright © Calin Crisan 2013</div>
+ <div class="copyright-note">copyright © Calin Crisan</div>
</div>
</div>
<div class="modal-glass"></div>