Hi Stefan. On 23 May 2018 at 21:30, Stefan Schake <stschake@xxxxxxxxx> wrote: > This checks the preview component for overlay functionality, but that has > little to do with streaming (you don't need to enable the overlay to do > streaming). We shouldn't withhold frames from userspace because of an > estimate for AGC stabilization time in any case. I'm not sure I agree with you there. With your patch if you open the camera and take one (eg JPEG) frame you'll get an incorrectly exposed image. That's a regression over the current behaviour. Something like Motion running on those first few frames is likely to see the change in exposure as significant changes and therefore give false triggers. The reason for the check for the overlay being enabled is that if it is running then AE/AGC will then have already had a chance to process some frames, therefore the capture image should be reasonable. Have you tried it with "v4l2-ctl --stream-mmap=3 --stream-count=1 --stream-to=capture.jpg" and looked at the output? In all but fairly bright conditions I'd expect to get a very dark image. Dave > Signed-off-by: Stefan Schake <stschake@xxxxxxxxx> > --- > drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c | 7 ------- > 1 file changed, 7 deletions(-) > > diff --git a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c > index ce26741..fbc23b8 100644 > --- a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c > +++ b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c > @@ -22,7 +22,6 @@ > #include <media/v4l2-fh.h> > #include <media/v4l2-event.h> > #include <media/v4l2-common.h> > -#include <linux/delay.h> > #include <linux/platform_device.h> > > #include "mmal-common.h" > @@ -511,12 +510,6 @@ static int start_streaming(struct vb2_queue *vq, unsigned int count) > /* enable frame capture */ > dev->capture.frame_count = 1; > > - /* if the preview is not already running, wait for a few frames for AGC > - * to settle down. > - */ > - if (!dev->component[MMAL_COMPONENT_PREVIEW]->enabled) > - msleep(300); > - > /* enable the connection from camera to encoder (if applicable) */ > if (dev->capture.camera_port != dev->capture.port > && dev->capture.camera_port) { > -- > 2.7.4 > _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel