void encodeDone() throws IOException {
int transparentIndex = -1;
int transparentRgb = -1;
// Put all the pixels into a hash table.
colorHash = new IntHashtable();
int index = 0;
for (int row = 0; row < height; ++row) {
// int rowOffset = row * width;
for (int col = 0; col < width; ++col) {
int rgb = rgbPixels[row][col];