Tuesday, 21 July 2015

How to create Thumbnail image in Java?

Download thumbnailator-0.4.8.jar from link

then open cmd.exe

set classpath=.../thumbnailator-0.4.8.jar;.
 

Then run the folowing program....


       
/*
*Auther@jyotiprakash panigrahi
*/
import net.coobird.thumbnailator.*;
public class thumbnail
{
public static void main(String args[])throws Exception
{
Thumbnails.of("1.jpg")
        .size(250, 250)
        .toFile("thumbnail.jpg");
}
}

 

No comments:

Post a Comment