Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
COMPARATIVE STUDY OF IMAGE MANIPULATION OPERATIONS IN JAVA, MATLAB AND JAVA ADAVANCED IMAGING (JAI)
UNDER THE GUIDANCE OF
3.2.JAI and JDK installation. 3.3.Java and Java Advanced Imaging. 3.4.Matlab installation and working. 3.5.Functions used in Matlab. 4. Implementation 4.1.JAVA program (execute in netbeans) to find addition and difference of two images. 4.2.Program in matlab to find difference of two images. 4.3.Program in matlab to find addition of two images. 4.4.JAI program (execute in netbeans) to find addition and difference of two images.
5. Comparative Study. 5.1. Sample1(Resolution 1024*768)
5.2.Sample2 (Resolution 162*170) 5.3.Graph for addition module for 100 images. 5.4.Graph for difference module for 100 images.
6. Conclusion.
7. References.
ABSTRACT
Image Processing is analyzing and manipulating images with a computer. Image processing techniques are now applied to virtually all natural sciences and technical disciplines. Generally it involves three steps: 1. Importing an image with an optical scanner or directly through digital photography 2. Manipulate or analyze the image in some way. This stage can include image enhancement and data compression, or the image may be analyzed to find patterns that are not visible by human eye. 3. Output the result. The result might be the image altered in some way or it might be a report based on analysis of the image. A whole chain of processing steps is necessary to analyze and identify objects. The basic procedures for extracting the data of interest and its analysis are the image operations. Image operations include subtraction of two images, addition of two images which are basically used to identify the change and analysis. In this work, a comparative study of the image operations in Java, Matlab and Java Advanced Imaging (JAI) is made. The image operations are performed on different samples in Java, Matlab and JAI, and comparison is made based on the time taken for the operation.
Comparative study of image manipulation operations in Java and Matlab 1. BACKGROUND/PURPOSE Visual sensor networks have emerged as an important class of sensor-based distributed intelligent systems, with unique performance, complexity, and quality of service challenges. Visual Sensor Networks consists of a large number of low-power camera nodes. The camera nodes provide information from a monitored site, performing distributed and collaborative processing of their collected data. With the recent advances in imaging technologies, producing small, low-power, low cost image/video capture devices at a large scale may be available in the foreseeable future. However, the large amount of image data produced by the cameras combined with the network's resource constraints require exploring new means for image processing, communication, and sensor management. Meeting these challenges of visual sensor networks requires interdisciplinary approaches, utilizing image processing, communications and networking, and embedded processing. In this proposed work a comparative study of image processing algorithms in JAVA and MATLAB is been done. A sensor node installed with JVM java virtual machine can easily interpret the byte code of image processing algorithms. JVM can be installed on sensor node with very low memory and processing capabilities hence it is advantage to use java API for image processing instead of MATLAB program which requires matlab compiler to be installed on sensor node. Hence in this proposed work comparative study is been made to use java advanced imaging(API) for image processing on sensor node instead of MATLAB.
Comparative study of image manipulation operations in Java and Matlab c. Change the username and password for the default server domain or accept the defaults and click Next. The default username and password are admin and adminadmin. Verify the default port values (HTTP, HTTPS, and Admin) for the server or change them if necessary. Click Next. 8. If you selected the Register... checkbox at the previous step, the Registration page opens in the browser. Click Register. 9 .The netbeans icon appears on the desktop.
2.2.
Installation Steps: 1. Download the following files from https://jai.dev.java.net/binary-builds.html a. b. c. d. jai-1_1_3-lib-windows-i586-jdk.exe jai-1_1_3-lib-windows-i586-jre.exe jai-1_1_3-lib-windows-i586.jar.zip jai-1_1_3-lib-windows-i586.exe
2. Double click on the jai-1_1_3-lib-windows-i586-jdk.exe file. 3. Accept the license agreement and click next. 4. Select the path for installation. 5. Follow the instructions and select the option to finish the installation. This will install the library files into th following default location without any check for the JDK or the JRE . C:\Program Files\Sun Microsystems\Java Advanced Imaging 1.1.3 6. To install the JRE version, double-click on the jai-1_1_3-lib-windows-i586-jre.exe icon and follow the directions. 7. To install the JDK version, double-click on the jai-1_1_3-lib-windows-i586-jdk.exe icon and follow the directions. NOTE: The executable will try to install JAI within the latest JDK (or JRE) version that it finds. If you need to install and use JAI within another JDK (or JRE) version on disk, please make sure you enter a valid JDK directory when prompted.
http://java.sun.com/products/java-media/jai/downloads/download-iio-1_0_01.html. After installing Netbeans this package can be incorporated by just downloading from the above mentioned site and installing it. The Java Advanced Imaging API extends the Java platform (including the Java 2D API) by allowing sophisticated, high-performance image processing to be incorporated into Java programs. Java Advanced Imaging is a set of classes which provide imaging functionality beyond that of Java 2D and the Java Foundation classes, although it is compatible with those APIs. The Java Advanced Imaging API implements a set of core image processing capabilities including image tiling, regions of interest, threading and deferred execution. JAI also offers a set of core image processing operators including many common point, area and frequency-domain operators. Image processing algorithms usually require the manipulation of the image data (pixels).In this section the model used by JAI for image data storage and manipulation will be represented, with the corresponding Java/JAI classes. Images in JAI may be multidimensional (i.e. with several values associated to a single (pixel) and may have pixel with either integer or floating point values (although there are restrictions on the types of images which can be stored in disk). Pixels may be packed in different ways or unpacked in the image data array. Different color models can be used. As one may expect, in order to be able to represent a variety of image data, one must deal with a variety of classes. Some of those classes are abstract, concrete subclasses of those behave on more or less the same way PlanarImage: Basic class for image representation in JAI, allows the representation of images with more flexibility than the Java class BufferedImage. Both Buffered-Image and PlanarImage uses several different classes for flexible image data representation, its pixels are stored in an instance of Raster which contains an instance of a concrete subclass of DataBuffer, packed accordingly to the rules described by an instance of a concrete subclass of SampleModel. An instance of PlanarImage also have a ColorModel associated to it, which contains an instance of ColorSpace, which determines how a pixels value can be translated to color values. Figure 1 shows how those classes are used to compose an instance of PlanarImage. A PlanarImage is read-only, i.e. it may be created and its pixels values may be read in several different ways, but there are no methods that allow the modification of pixels values. PlanarImages may have the origin of the image in a position different from the coordinate (0, 0), or even pixel coordinates with negative values. TiledImage: A subclass of PlanarImage, which can be used for reading and writing image data. RenderedOp: Another subclass of PlanarImage, which represents a node in a rendered imaging chain. A rendered imaging chain is a powerful and interesting concept of JAI which allows the processing of an image to be specified as a series of steps (operators and parameters) which are applied to one or more images.
Another interesting concept used in JAI is tiled images. Tiles can be considered as subsets of the images which may be processed independently. Large images thus can be processed in Java/JAI with reasonable performance, even through rendered imaging chains, since there is no need to load the whole image data in memory at once. If the image is tiled, all its tiles must have the same width and height. JAI allows different origins for the pixels and for the tiles on an image, although there are few, if any, practical applications for this. CREATE METHOD IN JAI The JAI API contains several image operators which can be applied with minimum programming. Those operators follow the concept of a rendered imaging chain, where the steps for the image processing are defined but will be carried only when needed (deferred execution). Those operations are specified in a simple way: first an instance of ParameterBlock is created, which is basically a vector of data that will be used for the operation. Create The static method create of the class JAI gets as an argument a name for the operation and the instance of ParameterBlock and returns an instance of RenderedOp which can be manipulated as a PlanarImage. Alternatively one can add the original image in the instance of ParameterBlock as a parameter to its addSource method. Other parameters are added to the ParameterBlock with its add method. Other forms of the method does not require a ParameterBlock and accept other arguments. The call for the JAI.create method is used with different arguments as operator, a file name as string containing the desired image file name (TIFF, JPEG, PNG, etc.). It accepts different operator argument options like fileload for loading a file subtract to find difference of two images addto add two images A list of all operators can be found on the JAI API documentation for the package javax.media.jai.operator. Dept of Computer Science and Engineering SDMCET 8
2.4.
Matlab Installation
Step 1: Prepare to Install Before you run the installer: Make sure you have your e-mail address and your MathWorks Account password handy. You will need them to log in to your account during installation. If you have multiple licenses associated with your account, know the number of the license you want to install. If you don't have a MathWorks Account, you can create one during installation. However, you must have an Activation Key. An Activation Key is the unique code that identifies a license. It is used to activate the license. The Activation Key also allows licensed end users to associate their MathWorks Account with a license. Ask the administrator of the license for the Activation Key. Exit any existing copies of MATLAB software you have running. Log in to an account with administrator privileges.
Consider disabling virus-checking software and Internet security applications on your system for the duration of the installation process. These applications can slow down the installation process or cause it to appear unresponsive (or to hang).If you do not have an Internet connection during installation, see Connection. If you need to perform a network server or client installation, see Network Installation Procedure.
Step 2: Choose Whether to Install Automatically or Manually Insert the DVD into the DVD drive connected to your system or double-click the installer file you downloaded from the MathWorks Web site. The installer should start automatically. If you are connected to the Internet, the easiest way to install is by selecting the Install automatically using the Internet option. During installation, you log in to your MathWorks Account, select the license you want to install, and follow the prompts on the other installer dialog boxes. Choose to install manually if you do not have an Internet connection. Click Next to proceed with the installation. Step 3: Review the Software License Agreement Review the software license agreement and, if you agree with the terms, select Yes and click Next. After the installation is complete, you can view or print the license agreement using the file license.txt located in the top-level installation folder. Step 4: Log In to Your MathWorks Account Enter the e-mail address and password of your MathWorks Account and click Next. If you do not have a MathWorks Account, select the I need to create a MathWorks Account option and click Next. Step 5: Select the License You Want to Install Select a license from the list of licenses associated with your MathWorks Account and click Next. The list contains the following information about the licenses: Dept of Computer Science and Engineering SDMCET 9
License number. An optional descriptive text label that can help identify the license. To label a license, go to the License Center at the MathWorks Web site. See the License Center Help for instructions. Information identifying the license option and the activation type. If an activation type has not yet been set on the license, the word "Unset" appears. If you want to install products on a license that is not associated with your MathWorks Account, select the Enter an Activation Key for a license not listed option, enter an Activation Key, and click Next. Specify an Activation Key If there are no licenses associated with your account, or if permission to activate is disabled on the license you selected, you might see the Activation Key dialog box. Enter an Activation Key and click Next. Ask the administrator contact on the license for the Activation Key.
Step 6: Choose the Installation Type In the Installation Type dialog box, specify whether you want to perform a Typical or Custom installation and click Next.
Choose Typical if you have an Individual or Group license and do not need to specify which products you want to install and do not need to access any installation options. Choose Custom if you need to specify which products to install, need access to installation options, or need to install the license manager (network license options only). Specify the name of the folder where you want to install MathWorks products. You can accept the default installation folder or specify the name of a different installation folder. If the folder doesn't exist, the installer creates it. When specifying a folder name, do not specify a name that contains the @ sign, an exclamation point (!), the percent character (%), the plus sign (+), or the dollar sign character ($). The full path of the installation folder must not include a folder named private. If you make a mistake while entering a folder name and want to start over using the default folder name, click Restore Default Folder. To continue with the installation, click Next.
Step 8: Specify Products to Install (Custom Only) If you are performing a custom installation, you can specify which products you want to install in the Product Selection dialog box. This dialog box lists all the products associated with the license you selected or with the Activation Key you specified. In the dialog box, all the products are preselected for installation. If you do not want to install a particular product, clear the check box next to its name. After selecting the products you want to install, click Next to continue with the installation. After clicking Next, you might receive a message telling you that one or more of the products you selected depend on other products. Consider adjusting your product selection. Dept of Computer Science and Engineering SDMCET 10
Comparative study of image manipulation operations in Java and Matlab Step 9: Specify Installation Options (Custom Only) For Custom installations, you can specify several installation options, including Setting the permissions of all installed files to read only. Determining whether the installer puts shortcuts for MATLAB software in the Start menu and on the desktop. Specifying which files the operating system associates with MATLAB, based on their file extension. For example, if you associate files with the .m file extension with MATLAB, the operating system identifies the type of these files as MATLAB M-file. Step 10: Confirm Your Choices Before it begins copying files to your hard disk, the installer displays a summary of your installation choices. To change a setting, click Back. To proceed with the installation, click Install. Step 11: Complete the Installation When the installation successfully completes, the installer displays the Installation Complete dialog box. In this dialog box, you can choose to activate the software you just installed. You cannot use the software you installed until you activate it. The MathWorks recommends activating immediately after installation. If you logged in to your MathWorks Account during installation, your log-in session continues into the activation process. Click Next to proceed with activation. If you choose to exit the installer without performing activation, clear the Activate MATLAB option and click Finish (the button label changes). You can activate later using the activation application. 2.5.
To import an image from any supported graphics image file format, in any of the supported bit depths, use the imread function. This example reads a truecolor image into the MATLAB workspace as the variable RGB. RGB = imread('football.jpg'); If the image file format uses 8-bit pixels, imread stores the data in the workspace as a uint8 array. For file formats that support 16-bit data, such as PNG and TIFF, imread creates a uint16 array. imread uses two variables to store an indexed image in the workspace: one for the image and another for its associated colormap. imread always reads the colormap into a matrix of class double, even though the image array itself may be of class uint8 or uint16. [X,map] = imread('trees.tif'); In these examples, imread infers the file format to use from the contents of the file. You can also specify the file format as an argument to imread. imread supports many common graphics file formats, such as Microsoft Windows Bitmap (BMP), Graphics Interchange Format (GIF), Joint Photographic Experts Group (JPEG), Portable Network Graphics (PNG), and Tagged Image File Format (TIFF) formats. For the latest information concerning the bit depths and/or image formats supported, see imread and imformats. Dept of Computer Science and Engineering SDMCET 11
Comparative study of image manipulation operations in Java and Matlab Method: imadd - Add two images or add constant to image Syntax Z = imadd(X,Y) Description Z = imadd(X,Y) adds each element in array X with the corresponding element in array Y and returns the sum in the corresponding element of the output array Z. X and Y are real, nonsparse numeric arrays with the same size and class, or Y is a scalar double. Z has the same size and class as X, unless X is logical, in which case Z is double. If X and Y are integer arrays, elements in the output that exceed the range of the integer type are truncated, and fractional values are rounded. Examples Add two uint8 arrays. Note the truncation that occurs when the values exceed 255. X = uint8([ 255 0 75; 44 225 100]); Y = uint8([ 50 50 50; 50 50 50 ]); Z = imadd(X,Y) Z= 255 50 125 94 255 150 Add two images together and specify an output class. I = imread('rice.png'); J = imread('cameraman.tif'); K = imadd(I,J,'uint16'); imshow(K,[]) Add a constant to an image. I = imread('rice.png'); J = imadd(I,50); subplot(1,2,1), imshow(I) subplot(1,2,2), imshow(J) Method: imabsdiff - Absolute difference of two images Syntax Z = imabsdiff(X,Y) Description Z = imabsdiff(X,Y) subtracts each element in array Y from the corresponding element in array X and returns the absolute difference in the corresponding element of the output array Z. X and Y are real, nonsparse numeric arrays with the same class and size. Z has the same class and size as X and Y. If X and Y are integer arrays, elements in the output that exceed the range of the integer type are truncated. Dept of Computer Science and Engineering SDMCET 12
Comparative study of image manipulation operations in Java and Matlab If X and Y are double arrays, you can use the expression abs(X-Y) instead of this function. Examples Calculate the absolute difference between two uint8 arrays. Note that the absolute value prevents negative values from being rounded to zero in the result, as they are with imsubtract. X = uint8([ 255 10 75; 44 225 100]); Y = uint8([ 50 50 50; 50 50 50 ]); Z = imabsdiff(X,Y) Z= 205 40 25 6 175 50 Display the absolute difference between a filtered image and the original. I = imread('cameraman.tif'); J = uint8(filter2(fspecial('gaussian'), I)); K = imabsdiff(I,J); imshow(K,[]) % [] = scale data automatically
3.
IMPLEMENTATION
3.1.
JAVA code (run in netbeans) to find addition and difference of two images
package windowimageconstructor; import java.awt.*; import java.awt.event.*; import java.awt.Dimension; import java.awt.Graphics; import java.awt.Image; import java.awt.image.*; import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; import java.net.MalformedURLException; import java.net.URL; import java.util.Date; import javax.imageio.ImageIO; import javax.swing.JFileChooser; // create Frame Window. public class FrameImage extends Frame { String msg="RSR" ; Image myImage1,myImage3; BufferedImage myImage2; int iw,ih;
13
14
} {
15
16
17
//new logic //grab pixels from image, construct array of pixels and then // again construct image from array of pixels. iw=tempImage.getWidth(null); ih=tempImage.getHeight(null); int pixels[] = new int [iw*ih]; PixelGrabber pg = new PixelGrabber(tempImage,0,0,iw,ih,pixels,0,iw); try { pg.grabPixels(); } catch (InterruptedException ex) { ex.printStackTrace(); System.out.println(" TEST-3: BuildImage2:Failed to grab pixels"); } myImage3 = createImage(new MemoryImageSource(iw,ih,pixels,0,iw)); //Buffered Image only and not Image type saveImage(tempImage); }// end of buildImage-2 public void paint(Graphics g) { g.drawString(msg,40,40); g.drawImage(myImage3,50,50,this); } void doMyJob() { Date d1 = new Date(); long t1,t2,t3; t1= d1.getTime(); System.out.println(" Start TIME buildImage3(); Date d2 = new Date(); t2=d2.getTime(); System.out.println(" End TIME t3 = t2-t1; in millisec --> "+t1);
// Main public static void main(String args[]) { FrameImage fm = new FrameImage(); fm.setTitle("ImageA"); fm.setSize(new Dimension(300,200)); fm.setVisible(true); // Image Related ActivityCall to routine
18
3.2.
3.3.
3.4.
/* * Created on Feb, 05 2010 * @author Team B4 */ package operators; import import import import import import import import
JAI program (execute in netbeans) to find addition and difference of two images
/** * This class shows how one can extend the DisplayJAI class. We'll override the
19
20
21
22
/** * This class represents a JPanel which contains two scrollable * instances of DisplayJAIWithPixelInfo. The scrolling bars of both * images are synchronized so scrolling one image will automatically * scroll the other. */ public class DisplayTwoSynchronizedImages extends JPanel implements AdjustmentListener { /** The DisplayJAIWithPixelInfo for the first image. */ protected DisplayJAIWithPixelInfo dj1; /** The DisplayJAIWithPixelInfo for the second image. */ protected DisplayJAIWithPixelInfo dj2; /** The JScrollPane which will contain the first of the images */ protected JScrollPane jsp1; /** The JScrollPane which will contain the second of the images */ protected JScrollPane jsp2; /** * Creates an instance of this class, setting the components' layout, * creating two instances of DisplayJAIWithPixelInfo for the two images * and creating/registering event handlers for the scroll bars. * @param im1 the first image (left side) * @param im2 the second image (right side) */ public DisplayTwoSynchronizedImages(RenderedImage im1,RenderedImage im2) { super(); setLayout(new GridLayout(1,2)); dj1 = new DisplayJAIWithPixelInfo(im1); // Instances of DisplayJAI for the dj2 = new DisplayJAIWithPixelInfo(im2); // two images jsp1 = new JScrollPane(dj1); // JScrollPanes for the both jsp2 = new JScrollPane(dj2); // instances of DisplayJAI add(jsp1); add(jsp2); // Retrieve the scroll bars of the images and registers adjustment // listeners to them. // Horizontal scroll bar of the first image. jsp1.getHorizontalScrollBar().addAdjustmentListener(this); // Vertical scroll bar of the first image. jsp1.getVerticalScrollBar().addAdjustmentListener(this); // Horizontal scroll bar of the second image. jsp2.getHorizontalScrollBar().addAdjustmentListener(this); // Vertical scroll bar of the second image. jsp2.getVerticalScrollBar().addAdjustmentListener(this); }
23
/** * This method changes the first image to be displayed. * @param newImage the new first image. */ public void setImage1(RenderedImage newimage) { dj1.set(newimage); repaint(); } /** * This method changes the second image to be displayed. * @param newImage the new second image. */ public void setImage2(RenderedImage newimage) { dj2.set(newimage); repaint(); } /** * This method returns the first image. * @return the first image. */ public RenderedImage getImage1() { } /** * This method returns the second image. * @return the second image. */ public RenderedImage getImage2() { return dj2.getSource(); } /** * This method returns the first DisplayJAIWithPixelInfo component. * @return the first DisplayJAIWithPixelInfo component. */ public DisplayJAIWithPixelInfo getDisplayJAIComponent1() { return dj1; } /** * This method returns the second DisplayJAIWithPixelInfo component. * @return the second DisplayJAIWithPixelInfo component. */ public DisplayJAIWithPixelInfo getDisplayJAIComponent2() return dj1.getSource();
24
return dj2;
25
26
27
28
*/
public ArithmeticOps(String im1,String im2) { super(); // Store the images' names. this.im1 = im1; this.im2 = im2; // Read the input images. input1 = JAI.create("fileload", im1); input2 = JAI.create("fileload", im2); // Create a temporary output image so we can show something before // clicking on the buttons. output = createConstFrom(input1); // Let's create the graphical user interface. First we create a JPanel // with the operations' buttons. JPanel buttonPanel = new JPanel(); buttonPanel.setLayout(new GridLayout(1,4)); // Let's create the buttons, register their ActionListeners and add them // to the JPanel. add = new JButton("Add"); add.addActionListener(this); buttonPanel.add(add); subtract = new JButton("Subtract"); subtract.addActionListener(this); buttonPanel.add(subtract); multiply = new JButton("Multiply"); multiply.addActionListener(this); buttonPanel.add(multiply); divide = new JButton("Divide"); divide.addActionListener(this); buttonPanel.add(divide); // We'll create an instance of DisplayThreeSynchronizedImages to //display the input and output images. imagesPanel = new DisplayThreeSynchronizedImages(input1,input2,output); // Get the Container for this JFrame. Container cp = getContentPane(); cp.setLayout(new BorderLayout()); // Add the panel with the buttons and the panel with the images to //the container. cp.add(imagesPanel,BorderLayout.CENTER); cp.add(buttonPanel,BorderLayout.SOUTH); // Set the closing operation so the application is finished. setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); pack(); // adjust the frame size using preferred dimensions. setVisible(true); // show the frame.. } /**
29
public PlanarImage createConstFrom(PlanarImage pi) { // Create an array of Bytes with length equal to the number of bands // of the input image. Byte[] bandValues = new Byte[pi.getNumBands()]; // Fill the array with a constant value. for(int band=0;band<pi.getNumBands();band++) bandValues[band] = new Byte((byte)127); // Create a ParameterBlock with the parameters for the creation of //the output image. ParameterBlock pb = new ParameterBlock(); pb.add((float)pi.getWidth()); // the input image dimensions pb.add((float)pi.getHeight()); pb.add(bandValues); // Create and return the constant image. return JAI.create("constant", pb, null); } /** * This method will be called when an action event occur (such as the ones generated when an user clicks on the application's buttons). @param e the action event.*/ public void actionPerformed(ActionEvent e) { // Create a ParameterBlock for the images' operation. ParameterBlock pb = new ParameterBlock(); // Add the input images to the ParameterBlock. pb.addSource(input1); pb.addSource(input2); // Run the operation (depending on the source of the event, i.e. the // button that was clicked) if (e.getSource() == add) { setTitle("Sum of images "+im1+" and "+im2); output = JAI.create("add", pb); } else if (e.getSource() == subtract) { setTitle("Image "+im1+" minus image "+im2); output = JAI.create("subtract", pb); } else if (e.getSource() == multiply) { setTitle("Multiplication of images "+im1+" and "+im2); output = JAI.create("multiply", pb); }
30
31
FIRST IMAGE
SECOND IMAGE
JAISUBTRACTI ON (secs)
MATLABSUBTRACTI ON (secs)
JAVAADDITION (secs)
JAVASUBTRACTI ON (secs)
32
33
34
35
AVERA GES
0.0611 46
0.01158 854
0. 61 0.36
0.9414 792
0.93833 333
36
5. COMPARATIVE STUDY
5.1. Sample1(Resolution (1024*768)): Image2: a2.jpg
Image1: a1.jpg
37
Addition:
Difference:
Graph: 1. Addition:
x-axis: samples yaxis: time (in secs)
38
2. Difference
x-axis: samples yaxis: time (in secs)
5.2.
Image1: mase.jpg
39
Addition:
Difference:
Graph:
x-axis: samples yaxis: time (in secs)
1. Addition:
40
2. Difference
x-axis: samples yaxis: time (in secs)
5.3. Graph for addition module for 100 images x-axis: samples yaxis: time (in secs)
41
5.4.
6. CONCLUSION
42
By the above analysis, we conclude that the image processing in JAI (Java Advanced Imaging) is better compared to Core Java and MATLAB image processing. JAI is better both in terms of time and accuracy. 7. REFERENCES
[1] https://jaistuff.dev.java.net/ [2] www.netbeans.org/ [3] www.mathworks.com/products/matlab/ [4] https://jai.dev.java.net/binary-builds.html [5] http://java.sun.com/developer/technicalArticles/Media/AdvancedImage/ [6] http://wiki.netbeans.org/OpenImagesUsingJAI [7] Programming in Java Advanced Imaging- Release 1.0.1 -- By, Sun Microsystems. [8] Java Advanced Imaging API- A Tutorial By, Rafael Santos.
43