ImageIcon ii = null;
    protected boolean loadSubframe(RpfSubframe subframe,                                   RpfCoverageBox coverageBox, int x, int y) {        boolean good = false;        int[] pixels = null;        ImageIcon ii = null;        if (frameProvider == null) {            Debug.message("rpf",                    "RpfCacheHandler.loadSubframes(): null frameProvider");            return false;        }        if (viewAttributes.colorModel == OMRasterObject.COLORMODEL_DIRECT) {            pixels = frameProvider.getSubframeData(coverageBox.tocNumber,                    coverageBox.entryNumber,                    x,                    y);            if (pixels != null) {                subframe.image.setPixels(pixels);                good = true;            }        } else if (viewAttributes.colorModel == OMRasterObject.COLORMODEL_INDEXED) {            RpfIndexedImageData riid = frameProvider.getRawSubframeData(coverageBox.tocNumber,                    coverageBox.entryNumber,                    x,                    y);            if (riid != null && riid.imageData != null                    && riid.colortable != null) {                subframe.opaqueness = viewAttributes.opaqueness;                subframe.image.setBits(riid.imageData);                subframe.image.setColors(riid.colortable);                subframe.image.setTransparent(viewAttributes.opaqueness);                good = true;            }        } else {            Debug.error("RpfCacheHandler: Frame Provider colormodel not handled.");            return false;        }        if (good == true) {            //LOAD UP the geographic stuff into            // cache.subframe[index].image            float lat, lon, lat2, lon2;            double xlloffset, ylloffset;            ylloffset = (double) (y * coverageBox.subframeLatInterval);            xlloffset = (double) (x * coverageBox.subframeLonInterval);            lat = (float) ((coverageBox.nw_lat) - ylloffset);            lon = (float) ((coverageBox.nw_lon) + xlloffset);            lat2 = (float) (lat - coverageBox.subframeLatInterval);            lon2 = (float) (lon + coverageBox.subframeLonInterval);            String data;            if (viewAttributes != null                    && (viewAttributes.autofetchAttributes || viewAttributes.showInfo)) {                data = frameProvider.getSubframeAttributes(coverageBox.tocNumber,                        coverageBox.entryNumber,                        x,                        y);            } else {                data = "";            }            if (DEBUG_RPFDETAIL) {                Debug.output("Attribute data for subframe " + x + ", " + y                        + ":\n" + data);            }            // fill in the information for the subframe.            subframe.setLocation(lat, lon, lat2, lon2);            subframe.setAttributeText(data);            return true;        } else {            subframe.setAttributeText("");        }        return false;    }