xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lo, Scott C (SLO)" <...@arinc.com>
Subject Need help on this Batik application developmment problem and thanks in advance!
Date Fri, 17 Dec 2010 00:11:18 GMT
Hi,

 

   I have a code like A.) below and failed on processing a SVG line like
B.) below in a SVG input file. 

C.) is the failed message dumped from exception handler and D.) is the
failed point when I trace the code.

 

   Because JPEGImageDecoder comes from "com.sun.org.apache.*"; so that I
can't trace further. I traced all codes

before creating the broken link image Graphics node (from PURL) and seem
fine. The classpath setting for resource 

RegistrEntry has no problem. I am wondering wheter you can help me on
this issue.

 

   Also, because JPEGImageDecoder has no source code, I can't exactly
identify the problem by further tracing. 

I am also wondering when Batik's implementation of ...codec/JPEG will be
available.

 

   The thing that confuse me the most is that batik-squiggle can opens
this SVG file fine.

 

Thanks,

Scott Lo

 

 

A.)

 

package com.arinc.afd.cupps.devices.pr;

 

import java.awt.Color;

import java.io.*;

 

import org.apache.batik.transcoder.Transcoder;

import org.apache.batik.transcoder.image.PNGTranscoder;

import org.apache.batik.transcoder.TranscoderInput;

import org.apache.batik.transcoder.TranscoderOutput;

import org.apache.xmlbeans.impl.xb.xsdschema.FieldDocument.Field.Xpath;

 

import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;

 

public class SvgToPNGTranscode {   

    

    @SuppressWarnings("deprecation")

                public SvgToPNGTranscode(String[] a1) throws Exception {

        // create a JPEG transcoder

        PNGTranscoder t = new PNGTranscoder(); 

        

        t.addTranscodingHint(PNGTranscoder.KEY_BACKGROUND_COLOR,
Color.white);

        t.addTranscodingHint(PNGTranscoder.KEY_PIXEL_TO_MM, new
Float(0.10584f));

        

        String[] ar = a1[0].split("\\\\");     

        String[] ar2 = ar[ar.length-1].split("\\.");

   

        // create the transcoder input

        String svgURI = new File(a1[0]).toURL().toString();        

 

        TranscoderInput input = new TranscoderInput(svgURI);

        // create the transcoder output

        OutputStream ostream =  new FileOutputStream(ar2[0] +".PNG");

        TranscoderOutput output = new TranscoderOutput(ostream);

        // save the image

        t.transcode(input, output);

    

        // flush and close the stream then exit

        ostream.flush();

        ostream.close();

    

        System.exit(0);

    }

    

    public static void main(String [] args) throws Exception { 

                

                     new SvgToPNGTranscode(args);

  }

}

 

 

 

B.)

 

   

   Inside SVG file, there is a <image....
xlink:href="data:image/jpg;base64,/9j/4AAQ...."/> Line. 

 

 

 

 

C.)

 

 

org.apache.batik.bridge.BridgeException: file:/C:/CA2/RobTest2.svg:0

The URI
"data:image/jpg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAgGBgcGBQgHBwcJC
QgKDBQNDAsLDBkSEw8UHRofHh0a..HBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDL
/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIy..MjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyM
jIyMjIyMjIyMjIyMjIyMjL/wAARCAAqAPUDASIA..AhEBAxEB/8QAHwAAAQUBAQEBAQEAAAA
AAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQA..AAF9AQIDAAQRBRIhMUEGE1FhB
yJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3..ODk6Q0RFRkdISUpTVFV
WV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTlJWWl5iZmqKjpKWm..p6ipqrKztLW2t
7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl5ufo6erx8vP09fb3+Pn6/8QAHwEA..AwEBAQE
BAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREAAgECBAQDBAcFBAQAAQJ3AAECAxEEBSEx..B
hJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYkNOEl8RcYGRomJygpKjU2Nzg5OkNERUZHS
ElK..U1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKm
qsrO0tba3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kfvV+XgMegsdJm1jxZout6vp8kiT2U19HbXcJcaZ
MVsQsQLD5XDRysD..hTkvxwTXeUUAfOGg+HfGHh66+IOsyxa5qOpw2jaXZTtDMJrzzJQguI3
5Y7FjVsDPBHzDGasR6F4k..l8R65byaVqotT4ghtNNla3k2WVuUvY45oeMLHCZUkXaQBhcFc
g19D0UAeD+I/DviTxl4rnudPi1X..wvb+HZYNL05beGTZLHJO0UlxCRsCKI9pIXI2qAWA5rQ
XRrzVfEWuQReGZ9I0C0u7GyXS0tSLXUP+..JgjSXQTaqH91GAeG+U8tgV7RRQB88XOpeJPE3
he58OS/D3VdNmSK9kstSa3kZrWMl5RbRjyl2qyK..tvgMAVIGCPlrT8K+GtSm+HmqPq2iXb6
tD4Xa1s2u7VjOjeZfr5ce4bgdjRDaP4Sg6EV7pRQB4Hpn..hbXviH4Mt/D2sWupaGReteG4v
LZ5MNFbwRH5W2czSTTSk5+8JPvElh0Hw+u5r7xJd3978OJNHnmv..Yktria1KtaQ/Y2TCMYl
IQG3C4GB+/A/3vXKKAPjzwX4L8VWvjrw9cXHhrWYYItTtnkkksJVVFEqk..kkrgADnNe3tpO
pf2P4BT+z7vfa6ZaJcL5LZhZbvTWIfj5SFjkJB7Ix7GvVKKAMPwnBNbaPcJPFJE..51O/cK6
lSVa7mZTz2KkEHuCDRW5RQB//2Q==.."

on element <image> can't be opened because:

JPEG URL is corrupt or unsupported variant

                at
org.apache.batik.bridge.UserAgentAdapter.getBrokenLinkDocument(UserAgent
Adapter.java:449)

                at
org.apache.batik.bridge.SVGImageElementBridge.createRasterImageNode(SVGI
mageElementBridge.java:604)

                at
org.apache.batik.bridge.SVGImageElementBridge.createImageGraphicsNode(SV
GImageElementBridge.java:327)

                at
org.apache.batik.bridge.SVGImageElementBridge.buildImageGraphicsNode(SVG
ImageElementBridge.java:177)

                at
org.apache.batik.bridge.SVGImageElementBridge.createGraphicsNode(SVGImag
eElementBridge.java:119)

                at
org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:213
)

                at
org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:171)

                at
org.apache.batik.bridge.GVTBuilder.buildGraphicsNode(GVTBuilder.java:219
)

                at
org.apache.batik.bridge.GVTBuilder.buildComposite(GVTBuilder.java:171)

                at
org.apache.batik.bridge.GVTBuilder.build(GVTBuilder.java:82)

                at
org.apache.batik.transcoder.SVGAbstractTranscoder.transcode(SVGAbstractT
ranscoder.java:208)

                at
org.apache.batik.transcoder.image.ImageTranscoder.transcode(ImageTransco
der.java:92)

                at
org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(XMLAbstractT
ranscoder.java:142)

                at
org.apache.batik.transcoder.SVGAbstractTranscoder.transcode(SVGAbstractT
ranscoder.java:156)

                at
com.arinc.afd.cupps.devices.pr.SvgToPNGTranscode.<init>(SvgToPNGTranscod
e.java:35)

                at
com.arinc.afd.cupps.devices.pr.SvgToPNGTranscode.main(SvgToPNGTranscode.
java:46)

Exception in thread "main"
org.apache.batik.transcoder.TranscoderException: null

Enclosed Exception:

file:/C:/CA2/RobTest2.svg:0

The URI
"data:image/jpg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wBDAAgGBgcGBQgHBwcJC
QgKDBQNDAsLDBkSEw8UHRofHh0a..HBwgJC4nICIsIxwcKDcpLDAxNDQ0Hyc5PTgyPC4zNDL
/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIy..MjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyM
jIyMjIyMjIyMjIyMjIyMjL/wAARCAAqAPUDASIA..AhEBAxEB/8QAHwAAAQUBAQEBAQEAAAA
AAAAAAAECAwQFBgcICQoL/8QAtRAAAgEDAwIEAwUFBAQA..AAF9AQIDAAQRBRIhMUEGE1FhB
yJxFDKBkaEII0KxwRVS0fAkM2JyggkKFhcYGRolJicoKSo0NTY3..ODk6Q0RFRkdISUpTVFV
WV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWGh4iJipKTl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EG URL is corrupt or unsupported variant

                at
org.apache.batik.transcoder.SVGAbstractTranscoder.transcode(SVGAbstractT
ranscoder.java:227)

                at
org.apache.batik.transcoder.image.ImageTranscoder.transcode(ImageTransco
der.java:92)

                at
org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(XMLAbstractT
ranscoder.java:142)

                at
org.apache.batik.transcoder.SVGAbstractTranscoder.transcode(SVGAbstractT
ranscoder.java:156)

                at
com.arinc.afd.cupps.devices.pr.SvgToPNGTranscode.<init>(SvgToPNGTranscod
e.java:35)

                at
com.arinc.afd.cupps.devices.pr.SvgToPNGTranscode.main(SvgToPNGTranscode.
java:46)

Corrupt JPEG data: 26 extraneous bytes before marker 0x32

 

 

 

 

D.)

 

 

public Filter handleStream(InputStream inIS,

                               ParsedURL   origURL,

                               boolean     needRawData) {

        final DeferRable  dr  = new DeferRable();

        final InputStream is  = inIS;

        final String      errCode;

        final Object []   errParam;

        if (origURL != null) {

            errCode  = ERR_URL_FORMAT_UNREADABLE;

            errParam = new Object[] {"JPEG", origURL};

        } else {

            errCode  = ERR_STREAM_FORMAT_UNREADABLE;

            errParam = new Object[] {"JPEG"};

        }

 

        Thread t = new Thread() {

                public void run() {

                    Filter filt;

                    try{

                        JPEGImageDecoder decoder;

                        decoder = JPEGCodec.createJPEGDecoder(is);

                        BufferedImage image;

                        try {

     ----------------------> image   = decoder.decodeAsBufferedImage();
<------------------------------------

                        } catch (TruncatedFileException tfe) {

                            image = tfe.getBufferedImage();

                            // Should probably draw some indication

                            // that this is a partial image....

                            if (image == null)

                                throw new IOException

                                    ("JPEG File was truncated");

                        }

                        dr.setBounds(new Rectangle2D.Double

                                     (0, 0, image.getWidth(),

                                      image.getHeight()));

                        CachableRed cr;

                        cr = GraphicsUtil.wrap(image);

                        cr = new Any2sRGBRed(cr);

                        cr = new FormatRed(cr, GraphicsUtil.sRGB_Unpre);

                        WritableRaster wr =
(WritableRaster)cr.getData();

                        ColorModel cm = cr.getColorModel();

                        image = new BufferedImage

                            (cm, wr, cm.isAlphaPremultiplied(), null);

                        cr = GraphicsUtil.wrap(image);

                        filt = new RedRable(cr);

                    } catch (IOException ioe) {

                        // Something bad happened here...

                        filt = ImageTagRegistry.getBrokenLinkImage

                            (JPEGRegistryEntry.this, errCode, errParam);

                    } catch (ThreadDeath td) {

                        filt = ImageTagRegistry.getBrokenLinkImage

                            (JPEGRegistryEntry.this, errCode, errParam);

                        dr.setSource(filt);

                        throw td;

                    } catch (Throwable t) {

                        filt = ImageTagRegistry.getBrokenLinkImage

                            (JPEGRegistryEntry.this, errCode, errParam);

                    }

 

                    dr.setSource(filt);

                }

            };

        t.start();

        return dr;

    }

}


Mime
View raw message