Hi,
 Pls help me to figure out , how to convert and svg file into jpg
file.

My code is like this..but i got exception
        JPEGTranscoder t = new JPEGTranscoder();
                                        System.out.println("err1");
                                        // set the transcoding hints
                                        
t.addTranscodingHint(JPEGTranscoder.KEY_QUALITY,
                                                                                
new Float(.8));
                                                                                
System.out.println("err2");
                                        // create the transcoder input
                                        //String svgURI = new
File(deleteFile );
                                        String svgURI = tmpstr + "/" + 
children[i];
                                                                                
System.out.println("err3");
                                                                                
System.out.println("svgURI"+svgURI);
                                        //TranscoderInput input = new
TranscoderInput(svgURI);
                                        File inputFile = new
File("c:/defectfindratio.svg"); 
                                        TranscoderInput input = new
TranscoderInput("c:/defectfindratio.svg");
                                        //TranscoderInput input = new
TranscoderInput("c:/defectfindratio.svg");
                                        // create the transcoder output
                                                                                
System.out.println("err4");
                                        File outputFile = new
File("c:/out.jpg");     
                                        FileWriter out = new
FileWriter(outputFile,true);
                                        //OutputStream ostream = new
FileOutputStream(outputFile);
                                        //OutputStream ostream = new
FileOutputStream("c:out.jpg");
                                                                                
System.out.println("err5");
                                        TranscoderOutput output = new
TranscoderOutput(out);
                                                                                
System.out.println("err6");
                                        // save the image
                                        t.transcode(input, output);
                                                System.out.println("err7");
                                        // flush and close the stream
then exit
                                        //ostream.flush();
                                        //ostream.close();

Thanks and Regards
Sridhar

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to