Guest User

BufferedImageLoader.java

a guest
Oct 2nd, 2019
197
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. package com.game.src.main;
  2.  
  3. import java.awt.image.BufferedImage;
  4. import java.io.IOException;
  5.  
  6. import javax.imageio.ImageIO;
  7.  
  8.  
  9. class BufferedImageLoader {
  10.  
  11. BufferedImage loadImage(String path) throws IOException {
  12. // TODO Auto-generated method stub
  13. return ImageIO.read(getClass().getResource(path));
  14.  
  15. }
  16.  
  17. }
Advertisement
Add Comment
Please, Sign In to add comment