Does anybody remember the PICLAB program from back in the days of DOS? Well, this project is similar in nature, but a generation beyond.
It will be a command-line program for loading, saving, and doing various manipulations on graphics files. But it's more than just "a program" running in a console window. It's an extensible framework which can be programmed from any scripting language, and added to.
The "engine", as it were, will be supplied as C++ classes for representing images, with primitives for accessing and manipulating the data, and load/save ability for PNG files. This may be used directly in a C++ program, or accessed via an OLE "dispinterface" for use by anything that can handle OLE Automation.
Internally, images are represented as a set of related planes (or channels). An RGB image, for example, has a plane for Red, a plane for Green, and a plane for Blue. Each plane is a 2-D array of 4-byte floating point values. Floats are used instead of 8 or 16 bit integers because a key use of this system is for performing chromatisity adjustments, and intermediate results need to be held without quantatization errors.
The engine will be available via an Active-X Automation interface, so it can be used from any programming language or scripting system. For example, you could write a front-end in Visual BASIC. Or write a Perl script to batch-process images. Likewise, extensions, in the form of new commands that "do something" to the image, can be made available as Active-X Automation interfaces. In this way the system is easily extensible.
One specific use will be from the command line. The PICLAB program had its own internal loop that would read a line from the user and execute it. The Chromo Shell, on the other hand, executes one command and returns. This allows the user to have the full power of his regular command shell, as well as mix and match Chromo commands with any other programs. For example:
[e:\images] chromo load testimage.png Loaded testimage.png, 1024x768, 48-bits/pixel. [e:\images] dir *.png /w Volume in drive E is Barracuda 9.1 Serial number is 684A:D954 Directory of E:\Images\f AnotherWorld.bak.png AnotherWorld.png AnotherWorld.save.png detail_1.png femsit_test copy 1.png femsit_test copy 2.png femsit_test copy 3.png femsit_test copy 4.png femsit_test copy 5.png femsit_test copy 6.png femsit_test(1).png gamma_view.png Untitled2.png 15,228,041 bytes in 13 files and 0 dirs 15,235,072 bytes allocated 4,444,850,176 bytes free [e:\images] chromo setgamma 2.2 testimage.png gamma changed from 1.0 to 2.2 [e:\images] chromo reduce random 8 testimage.png reduced to 8-bit precision using Random Dither
The idea is that you can run the Chromo.exe program once for each thing you want to do, working in you command shell of choice or from a batch file, and mixing freely with other programs or shell commands.
You can also see a primary initial use from the example: adjusting color with high precision, and reducing the result not by simple truncation but by a choice of dithering methods including Random and Error Diffusion with programmable filters.
Still in the planning stages.