31 May 2011

Playing with the Gimp server: my notebook

In the following post, I'll show how the Gimp can be used as a server that will read and execute some statements in the scheme programming language. The scheme script will be used to downlad, resize and filter an image from the web.

Starting the Gimp Server

Go in menu FiltersScript-FuStart Server

The original image


(3156 x 2538)Barbara McClintock in the lab at Cold Spring Harbor in 1947

The script

Here is the scheme script:

The java client

The following java client will send the previous scheme script to the gimp server. The simple protocol used by GIMP is described on this page.
>javac GimpClient.java
>java GimpClient input.scm
Success

The result




That's it,


Pierre

No comments: