Stopping Camerabin

Thiago Santos thiago.sousa.santos at collabora.com
Mon Jan 20 05:43:08 PST 2014


On 01/20/2014 10:34 AM, Ian Davidson wrote:
> I am trying to use camerabin to take still pictures. All now goes well 
> until I try to stop.
>
> I can send a state change to camerabin to set the state to NULL - but 
> I do not see anything telling me that the state change has worked.  
> Consequently, the main loop is never exited, so the program hangs.
>
> Should I be waiting for the main loop to see some message, so that it 
> can exit - or should I just set the state to NULL, then unref the 
> pipeline, remove the bus watch and unref the main loop?

Setting elements/pipelines to NULL is a sync operation. So after that 
call returns it should be safe to quit the main loop and unref everything.

Additionally to make sure that all pictures were saved, check that the 
idle property of camerabin is true, or make sure to wait for the 
image-done messages posted on the bus for each picture you requested to 
capture.

--
Thiago

>
> Ian
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



More information about the gstreamer-devel mailing list