question: private static void blankOutline ( final Image alphaChannelImage , final BufferedImage relief ) { final Graphics2D gc = ( Graphics2D ) relief . getGraphics ( ) ; final Composite prevComposite = gc . getComposite ( ) ; gc . setComposite ( AlphaComposite . getInstance ( AlphaComposite . DST_IN ) ) ; final ImageIoCompletionWatcher watcher = new ImageIoCompletionWatcher ( ) ; final boolean drawComplete = gc . drawImage ( alphaChannelImage , 0 , 0 , watcher ) ; if ( ! drawComplete ) { watcher . waitForCompletion ( ) ; } gc . setComposite ( prevComposite ) ; }
target:  Sets the alpha channel to the same as that of the base image