Diego Gómez Deck's blog

One thing is to make OLPC code old, and quite another to have that code work in an acceptable way. In video processing it is, perhaps, one of the most ambitious goals on the OLPC.

Imagine we have to process 20 frames per second, and the image measures 320x240 pixels. Each pixel is composed of 3 data (the Red part, the Green part, and the Blue part) which are called RGB (Red, Green, Blue). If we have to process each point of the image, we will have to process 320x240 times, for each frame, the operations for the Red, Green and Blue part.

To achieve 20 frames per second, with an image of 320x240, we will have to perform: 320 (width) * 240 * (RGB) * 20 (frames / sec) = 4.608.000 (operations / sec)

In a process like that, the OLPC slows down.

Well, Linux to the OLPC, was practically without problems BUT the processing speed obtained was of pity. I just processed 3 frames per second.

After some code changes (avoiding floating-point arithmetic, looping unrolling, using 16-bit bitmaps instead of 32-bit, etc.) we get 20 frames per second .

Colibri De Oro Dominican Republic Postcard | Zazzle
The spirit of the animal of power of the Hummingbird, will help us to see what good in others, to always look forward with enthusiasm and joy.

One thing to keep in mind is that Squeak's model and philosophy impose greater requirements on the code. Put another way: Processing video in Squeak is not ONLY to display a video in full screen, as fast as possible. If we just did that, we could get the same 30 frames x second with an image of 640x480 pixels that most video camera control programs achieve. Processing video in Squeak is integrating the video as a full-fledged citizen within the world of 100% manipulatable and programmable objects.

This is the vocabulary of the video object:

With this vocabulary (and the vocabulary of the other Squeak objects) you can do some interesting experiments ... For example: If we make an animation in Squeak , but if instead of filling the container with handmade drawings, we fill it with 1 frame per second from the webcam (using the #lastFrame property), we get an animation that is an accelerated video (like those video of fast growth of the plants they put on documentary channels, or an apple that rots in 20 seconds, etc.) of what the webcam is capturing.

The most interesting of this option is that, the video accelerated, is a production of the child. It does not use the "show accelerated video" option that does everything for him, but he has to face solving the problem, using knowledge he already has.

In order to finish I leave a question:

What other experiments can be done with the Webcam and Squeak?