FreeHEP - Vector Graphics

Release Notes 1.2.2

Release Notes Version: $Revision: 1.4 $.

The most recent version of this file is available here. Release notes for all versions of the VectorGraphics package are available here.

The VectorGraphics package of FreeHEP Java Library enables any Java program to export to a variety of vector graphics formats as well as bitmap image formats. Among the vector formats are PostScript, PDF, EMF, SVF, SWF and CGM, while the image formats include GIF, PNG, JPG and PPM.

The package uses the standard java.awt.Graphics2D class as its interface to the user program. Coupling this package to a standard Java program is therefore quite easy. It also comes with a dialog box which allows you to choose between all the formats mentioned above and set specific parameters for them.

Major changes in VectorGraphics 1.2.2

  • Separately packaged for users who only want the VectorGraphics package.
  • FREEHEP-307: Added extra documentation for usage without ExportDialog.
  • FREEHEP-326: VectorGraphics now runs inside Applets.
  • FREEHEP-323: PixelGraphics2D, caught SecurityException to allow it to run in Applets.
  • FREEHEP-227: All Registered ImageIO writers will now register themselves as ExportFileTypes.
  • WIRED-6: Added BufferedPanel to allow for easy double buffering.
  • FREEHEP-286: Changed algorithm for Cubic to Quad beziers, supplied by Robert Penner.

CGM, Contributed by Ian Graham, ian@kelman.com

  • FREEHEP-361: CGM CellArray supports large images.
  • FREEHEP-324: Constructor uses proper OutputStream.
  • FREEHEP-344: Added CGM Raster (image) support.
  • Added CGMInputStream, CGMDummyTag, CGMDump and CGMAnalyze to analyze an CGM file.

EMF

  • Added EMFAnalyze to analyze an EMF file. * FREEHEP-378: Pen (draw) and Brush (fill) only set when changed, and kept separately since EMF allows separate colors for them. * FREEHEP-377: Line2D, Rectangle2D, RoundRectangle2D, CubicCurve2D and Ellipse are mapped to their equivalent EMF tags without going through a path constructor. * FREEHEP-376: MiterLimit only set when changed. * FREEHEP-93: EMFInputStream now tested for EMF2SVG converter. * FREEHEP-340: Added an EMFDisplay and an EMF2SVG converter, contributed by Carsten Zerbst, carsten.zerbst@atlantec-es.com

Java

  • FREEHEP-381: Java: NPE if PACKAGE_NAME not set.

PDF

  • FREEHEP-293: Fixed a problem with setMultiPage method. Now works correctly. Also fixed TestPDFMultipage test.

RAW

  • FREEHEP-380: RawImageWriteParam generates NPE

SWF

  • Added SWFAnalyze to analyze an SWF file.

Documentation

The following documentation is currently available:

License

The VectorGraphics package is part of the FreeHEP Java Library, an "Open Source" library distributed under the terms of the LGPL. If you have questions about the licensing please send a mail to: developers@freehep.org.

Installing the VectorGraphics package

Download VectorGraphics and unpack. The distribution creates the following directory structure:

VectorGraphics-version            containing license and release notes
VectorGraphics-version/examples   containing examples
VectorGraphics-version/lib        containing jar files

Compiling the VectorGraphics package

The current distribution does not contain source files.

To (re-)build the VectorGraphics package you need to get VectorGraphics-1.2.2-src.zip or .tar.gz file from the ftp://ftp.slac.stanford.edu/software/freehep/VectorGraphics/v1.2.2/ directory.

To compile it, follow the general instructions for Building the Java FreeHEP Library and compile only the VectorGraphics jar files using the commands:

ant -Djar=graphics2d
ant -Djar=graphicsio
ant -Djar=graphicsio-cgm
ant -Djar=graphicsio-emf
ant -Djar=graphicsio-gif
ant -Djar=graphicsio-java
ant -Djar=graphicsio-pdf
ant -Djar=graphicsio-ppm
ant -Djar=graphicsio-ps
ant -Djar=graphicsio-svg
ant -Djar=graphicsio-swf

To build the distribution kit:

cd org/freehep/graphicsio
gmake dist

Building an Application with the VectorGraphics package

Add the following libraries to your CLASSPATH:

freehep-graphics2d.jar
freehep-base.jar

Running an Application with the VectorGraphics package

Add the following libraries to your CLASSPATH:

freehep-graphicsio.jar
freehep-graphics2d.jar
freehep-base.jar

Then add any of the following jar files to your CLASSPATH to enable that format for output:

freehep-graphicsio-cgm.jar
freehep-graphicsio-emf.jar
freehep-graphicsio-gif.jar
freehep-graphicsio-java.jar
freehep-graphicsio-pdf.jar
freehep-graphicsio-ppm.jar
freehep-graphicsio-ps.jar
freehep-graphicsio-svg.jar
freehep-graphicsio-swf.jar

Features/Limitations of the Current Release

The following limitations exist:

  • All outstanding issues in the Bug Database.
  • The distribution kits contain some CVS directories and files, please ignore.

Reporting Bugs

To report bugs or request enhancements you may use the FreeHEP bug database, component VectorGraphics.

Examples

The VectorGraphics/examples directory contains:

  • ExportDialogExample.java to show how to use the default ExportDialog that comes with the VectorGraphics package.