![]() |
2011-04-29
, 11:13
|
|
Posts: 1,637 |
Thanked: 4,424 times |
Joined on Apr 2009
@ Germany
|
#2
|
* How do I programitically take an image snapshot, i.e. show a live video of the camera, and then snap it when the camera button is pressed?
import gst
bin = gst.element_factory_make("camerabin")
bin.set_property("videoenc", gst.element_factory_make("dspmp4venc"))
bin.set_property("videomux", gst.element_factory_make("hantromp4mux"))
bin.set_property("audioenc", gst.element_factory_make("nokiaaacenc"))
bin.set_state(gst.STATE_PLAYING)
bin.set_property("filename", "test.mp4")
bin.set_property("mode",1)
#starts recording
bin.emit("user-start")
# wait some time
# stops recording
bin.emit("user-stop")
bin.set_state(gst.STATE_PAUSED)
bin.set_state(gst.STATE_NULL)
The Following User Says Thank You to nicolai For This Useful Post: | ||
![]() |
2011-05-01
, 20:44
|
Posts: 81 |
Thanked: 45 times |
Joined on Dec 2009
|
#3
|
g_object_set(camerabin,"filename","foo.jpg",NULL);
g_signal_emit_by_name(camerabin, "capture-start");
![]() |
2011-05-01
, 21:36
|
|
Posts: 1,637 |
Thanked: 4,424 times |
Joined on Apr 2009
@ Germany
|
#4
|
g_object_set (bin, "filename", helper->file_path, NULL); TSTAMP (before-gst-capture); g_signal_emit_by_name (bin, "user-start", 0); g_signal_emit_by_name (bin, "user-stop", 0);
![]() |
2011-05-02
, 05:32
|
Posts: 81 |
Thanked: 45 times |
Joined on Dec 2009
|
#5
|
I have written a new application gmeasure that allows measuring distances in photographs. It is available in source from:
https://github.com/dov/gmeasure
I would very much appreciate with help on the following issues:
* Creation of infrastructure for a debian package.
* An icon.
* Currently the package compiles with scons, but perhaps it would make sense to translate it into autoconf.
* How do I programitically take an image snapshot, i.e. show a live video of the camera, and then snap it when the camera button is pressed?
Any other comments are welcome!
Thanks!