boolean testSectionUpdate(int x, int y, Dimension d) {

        if (oldrgbdata == null) {
            //updated
            return true;
        }
        int width = blockSize + x;
        int height = blockSize + y;
        if (width > d.width) {
            width = d.width;
        }
        if (height > d.height) {
            height = d.height;
        }
        for (int i = x; i < width; i += 2) {
            for (int j = y; j < height; j += 2) {
                //System.out.println("i=" + i + " j=" + j);
                if (oldrgbdata[j * d.width + i] != rgbdata[j * d.width + i]) {
                    //updated
                    return true;
                }
            }
        }
        return false;
    }