if ((type & Raster.RASTER_DEPTH) != 0) {
if (depthFormat == DepthComponentRetained.DEPTH_COMPONENT_TYPE_INT) {
// yOffset is adjusted for OpenGL - Y upward
gl.glReadPixels(xSrcOffset, yAdjusted, width, height,
GL2.GL_DEPTH_COMPONENT, GL.GL_UNSIGNED_INT, IntBuffer.wrap((int[]) depthBuffer));
} else {
// DEPTH_COMPONENT_TYPE_FLOAT
// yOffset is adjusted for OpenGL - Y upward
gl.glReadPixels(xSrcOffset, yAdjusted, width, height,