The project is to build an optimized Animated GIF Encoder which has to fullfil the following requirements:
**Requirements**
1. The GIF encoder has to minimized the encoded GIF file size. The overall encoded size must smaller or equal than those produced by Advanced GIF Compressor ([login to view URL]). Bonus will be given if the compression ratio can be as small as those created by "A Smaller GIF" ([login to view URL])
2. The input to the encoder are [login to view URL] objects of the type **TYPE_INT_ARGB** representing the individual frames of the Animated GIF. As the BufferedImage object may contain Alpha channel, any pixel less than 50% opaque will be treated as transparent in the encoded GIF.
3. The GIF encoder should implement the following Java Interfaces:
/**
* Add a frame to the animated GIF with a specified delay value in milliseconds
* throws Exception if the added image is of different size than the first added one
*/
public void addFrame(BufferedImage image, int delay) throws Exception
/**
* Writes the encoded animated GIF to the OutputStream
*/
public void encode(OutputStream os) throws Exception
/**
* Add text comment to the newly added frame
*/
public void addComment(String comment)
/**
* Sets the number of loops the animated GIF shall play in the browser by the Netscape Extension
*/
public void setRepeat(int repeat)
4. For ecnonomy of memory comsumption, the encoder should not buffer all the frames in raw before encoding, it can only allow a footage of a maximum of 10 raw frames to be buffered. A java profiler will used to verify this requirement.
5. The Encoder implementation should be written in pure-java and self-contained such that it does not rely on any external components.
**Reference Resources:
**1. The GIF89a specification
[login to view URL]
2. Hints on Animated GIF optimization
[login to view URL]
3. List of Java libraries to read and write image files
[login to view URL]
4. Netscape Extension in GIF
[login to view URL]
## Deliverables
1) Complete and fully-functional demonstration program(s) in executable form as well as complete source code of all work done.
2) Exclusive and complete copyrights to all work purchased. (No GPL, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site).
## Platform
- Pure Java without native components
- Runnable on Linux, Unix and Windows environment with
JDK 1.3 or JDK 1.4