From charlesreid1

Line 16: Line 16:
</pre>
</pre>


=Using=


Here are some sample scripts that show you how to use various functions within SimpleCV.


==Capturing images==
You can capture images with SimpleCV with the following simple script:
<pre>
from SimpleCV import Camera
import time
cam = Camera()
time.sleep(3) # wait for the camera to warm up
img = cam.getImage()
img.save("myimage.png")
</pre>


=Flags=
=Flags=


{{PiFlag}}
{{PiFlag}}

Revision as of 06:17, 19 August 2016

Installing

Raspberry Pi

Start by installing things SimpleCV will need, namely, Scipy and OpenCV:

$ sudo apt-get install python-scipy
$ sudo apt-get install python-opencv

Now install simplecv using pip:

$ sudo pip install simplecv

Using

Here are some sample scripts that show you how to use various functions within SimpleCV.

Capturing images

You can capture images with SimpleCV with the following simple script:

from SimpleCV import Camera
import time
cam = Camera()
time.sleep(3) # wait for the camera to warm up
img = cam.getImage()
img.save("myimage.png")

Flags