jim-easterbrook / python-gphoto2

Python interface to libgphoto2
GNU Lesser General Public License v3.0
357 stars 59 forks source link

trouble with gp.GP_CAPTURE_IMAGE #113

Closed sjohns5 closed 3 years ago

sjohns5 commented 3 years ago

This page is for reporting problems with the Python interface to libgphoto2. If your question is about using libgphoto2 you should ask on the gphoto2 mailing list.

Your system What version of Python are you using? 3.8 What version of libgphoto2 have you installed? 2.5.25 How have you installed (or attempted to install) python-gphoto2? yes Your problem Please describe what you are trying to do and what goes wrong. A short Python script that shows the problem may be useful. Hi Jim,

I am having trouble with the gp.GP_CAPTURE_IMAGE function in python. The command is able to take a photo but it isn't downloading anywhere. When I run the --capture-image-and-download in the command line it downloads to my photos. Could you help me with the downloading aspect.

jim-easterbrook commented 3 years ago

The libgphoto2 API is documented here: http://www.gphoto.org/doc/api/

Note that gp_camera_capture returns a CameraFilePath that tells you the folder and name of the captured image file. You can then download the image with gp_camera_file_get.