I've discontinued this effort as the free software Blender can do the job much better. However, it remains as an example of a Java GUI which displays an image with graphics.
A software assistant to help artists create pictures.
With recent improvements in computer power it is possible to use a desktop computer to aid artists in sketching and rendering pictures, saving them hours of toil.
As an amateur artist, I've often wished for a tool which can help me craft a scene from the imagination, relieving me of the drudgery of making preliminary sketches, laying out the perspective and shadows, and using photographs, props and clay models.
Prentice will be such an artistically knowlegable intelligent software agent.
This is an ambitious project for one person doing it in his limited free time, so needs extremely careful planning.
Can be simple: frequent archiving of tested snapshots with versioning.
Probably will be GUI objects derived from Java's basic ones, coordinate transform and projection objects, illumination objects, general purpose model objects/ file I/O and data conversion objects. Here's the preliminary software design and the Javadoc software documentation
Source code is distributed under the terms of the GNU General Public License. You will need to download each of the .c and .h source files below, compile and link them. For compiling and running, follow instructions below. Current version is 1.1
| Click on the symbol
|
|
|
|
Top level program for Prentice. Creates the main and GUI threads. Constructs the application, frame, view, image, and model objects. |
|
|
Application wide constants. |
|
|
Debug logging to file. |
|
|
Graphical Model. |
|
|
My own simple implementation since SwingWorker is absent in Java SE 5. If you have Java SE 6, you don't need to include this. |
|
|
Read and parse model files. |
|
|
Matrix transformations including perspective. |
|
|
Rendered image upon which we draw. |
|
|
Top level of the GUI: the frame which handles menus and buttons. |
|
|
Top level view within the frame containing the image and special buttons. |
|
|
Container for the image, with scrollability. |
|
|
A class for opening a file. |
|
|
A class for printing. |
|
|
Handles all mouse events. |
|
|
Makefile for Unix or Windows/Cygwin. |
Here's how to compile and run by hand without using the makefile:
Copyright © 2005-2009 by Sean Erik O'Connor. All Rights Reserved. last updated 01 Jan 09.