private static Pointer _getRaster(BufferedImage img) {
    if (img == null) {
      return null;
    }

    final DataBuffer db = img.getRaster().getDataBuffer();
    DirectDataBufferInt dbb = (DirectDataBufferInt)db;
    return dbb.myMemory;
  }
private static Pointer _getRaster(BufferedImage img)