Does any one know any source code for any language that would make a connected camera take a picture and save it? If it helps, I'm using an outdated Argus DC 1600.
Is it a webcam?
If not,
set up your cd-rom drive so that it hits the button to take a picture and use
#include <mmsystem.h>
...
mciSendString("open cdaudio",0,0,0);
mciSendString("set cdaudio door open",0,0,0);
mciSendString("close cdaudio",0,0,0);
Post has been edited 1 time(s), last time on Mar 30 2009, 10:11 pm by Doodle77.
None.
Hmm... that might not work in this case. However, it COULD be a webcam, it depends on which computer I use.
Post has been edited 1 time(s), last time on Mar 31 2009, 5:46 am by A_of-s_t.
I found some code for python that I'm going to try out:
import appuifw, e32, camera
app_lock = e32.Ao_lock()
#Define the exit function
def quit():
#Close the viewfinder
camera.stop_finder()
#Release the camera so that other programs can use it
camera.release()
app_lock.signal()
appuifw.app.exit_key_handler = quit
#Function for displaying the viewfinder
def vf(im):
appuifw.app.body.blit(im)
#Function for taking the picture
def take_picture():
#Take the photo
photo = camera.take_photo('RGB', (1024, 768))
#Save it at maximum quality
photo.save(photo_savepath, quality = 100)
#Restart the viewfinder
camera.stop_finder()
camera.start_finder(vf)
photo_savepath = u"C:\\photo.jpg"
#This is the path and name for storing the photo
#Set the application's body to Canvas
appuifw.app.body = appuifw.Canvas()
#Start the viewfinder
camera.start_finder(vf)
#Set the script title
appuifw.app.title = u"Capture Photo"
#Set the application's menu with the option to take the photo
appuifw.app.menu=[(u"Take photo", take_picture),(u"Exit",quit)]
#Wait for the user to request the exit
app_lock.wait()
Problem solved.... FOR NOW >.>