|
|
@ -136,8 +136,8 @@ public class Controller { |
|
|
|
System.out.println(url); |
|
|
|
System.out.println(url); |
|
|
|
BufferedImage img = null; |
|
|
|
BufferedImage img = null; |
|
|
|
if (url.contains("http://projectdivar.com/")) { |
|
|
|
if (url.contains("http://projectdivar.com/")) { |
|
|
|
System.out.println("Locally available. "+"./"+url.replace("http://projectdivar.com/", "")); |
|
|
|
//System.out.println("Locally available. "+"./"+url.replace("http://projectdivar.com/", ""));
|
|
|
|
img = ImageIO.read(new File("./"+url.replace("http://projectdivar.com/", ""))); |
|
|
|
img = ImageIO.read(new File("../../server/"+url.replace("http://projectdivar.com/", ""))); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
downloadFileFromUrl(url,"temp"); |
|
|
|
downloadFileFromUrl(url,"temp"); |
|
|
|
//BufferedImage img = ImageUtils.toBufferedImage(ImageIO.read(new File("temp")).getScaledInstance(1227, 690, Image.SCALE_SMOOTH));
|
|
|
|
//BufferedImage img = ImageUtils.toBufferedImage(ImageIO.read(new File("temp")).getScaledInstance(1227, 690, Image.SCALE_SMOOTH));
|
|
|
|