This is a short Processing sketch to demonstrate the use optical character recognition (OCR) with the Tesseract OCR engine. I used the Mac OSX platform for testing. Here are the steps.
Processing 3.0 Video library in Ubuntu
I installed the new Processing 3.0 and its video library in Ubuntu and found that the Movie class could not display the digital video. It only played the audio track. The Capture class worked well. Afters some Google researches about the gstreamer package, I concluded that it can be the missing gstreamer0.10-ffmpeg module. By installing it again as described here, the Movie class worked fine.
Processing 3.0 Beta 1
The new Processing 3.0 beta is available in the Processing website for download. There are some changes in the internal operations that we may need to pay attention to in case our programs depend on them.
Here is a sketch with 2D graphics, I try to list out those internal hidden variables and functions, especially those related to the PSurface class.
Continue reading
OpenCV and Processing 20
It is a little side tracked from the previous posts. The example demonstrated the use of Kalman Filter in OpenCV with Processing.
OpenCV and Processing 18
In addition to the Hough circle detection, this example works on the Hough line segment detection. It inputs the live webcam image; converts it into greyscale; applies a medianBlur filter; processes the Canny edge detection. The Imgproc.HoughLinesP() function will finally single out the line segments into a Mat – lines in our example codes.
Continue reading
OpenCV and Processing 17
The example explores the Hough Circle detection in the Imgproc module. It starts with a greyscale copy of the live webcam image with an application of a blur filter, in this case, a medianBlur.
Load external class in Processing
It is a short side project away from the OpenCV and Processing thread. In this example, I would like to see if I can load an external class within a Processing sketch. The structure of the program is:
OpenCV and Processing 16
This example continues from the last post to compute the optical flow between 2 greyscale images by using the calcOpticalFlowPyrLK() function in the Video module. The new position of the pixels tracked will be delivered in a MatOfPoint2f object. By using the last and current position of the feature points, we can plot the path of the pixel movements. Furthermore, we can use such information for interactive or generative drawings, found in my artwork, Movement in Time.
Continue reading
OpenCV and Processing 15
The coming example will be the sparse optical flow. Before that, we first work on the 2D feature points tracking. The function goodFeaturesToTrack() belongs to the Imgproc module. It takes in a greyscale image and identifies the feature points (corners) as a matrix of point, MatOfPoint. The sample code here uses the feature points to render a live graphics of the webcam image.
Continue reading