|
where can i find an image converter that can convert a vnt. image to jpg. or jpeg? |
|
|
|
|
|
|
|
Reply #1 aiskacang92's post
|
|
|
|
|
|
|
Reply #1 aiskacang92's post
|
|
|
|
|
|
|
ni salah satu cara konvensional...
guna code untuk convert image
- import java.io.*;
- import javax.imageio.ImageIO;
- import java.awt.image.BufferedImage;
- public class ImageConverter {
-
- public static void main(String argv[]) {
-
- try {
-
- System.out.println( " enter image name : " ) ;
- BufferedReader bf = new BufferedReader (new InputStreamReader(System.in));
-
- String imageName = bf.readLine();
- File input = new File(imageName);
- BufferedImage image = ImageIO.read(input);
-
- System.out.println("enter the output image name (*.jpg ): \n " ) ;
-
- String imageName1 = bf.readLine();
- File output = new File(imageName1);
- ImageIO.write(image, "jpg", output);
-
- System.out.println(" your image has been converted successfully ") ;
-
- }
- catch (FileNotFoundException e) {
- e.printStackTrace();
- }
- catch (IOException e) {
- e.printStackTrace();
- }
- }
- }
Copy the Code
sape yang tau nak compile code ni. boleh try. |
|
|
|
|
|
|
|
vnt tu apa?
K tak tahu..
kalau nak batch conversion, try gunairfanview [freeware]
[ Last edited by kmkd at 15-3-2008 02:32 AM ] |
|
|
|
|
|
|
| |
|