wood burning stoves 2.0*
The moose likes Other JSE/JEE APIs and the fly likes Java Advanced Imaging throwing AccessControlExceptions when I try to perform a rendering operation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "Java Advanced Imaging throwing AccessControlExceptions when I try to perform a rendering operation" Watch "Java Advanced Imaging throwing AccessControlExceptions when I try to perform a rendering operation" New topic
Author

Java Advanced Imaging throwing AccessControlExceptions when I try to perform a rendering operation

J Ellis
Greenhorn

Joined: Aug 23, 2009
Posts: 27
I all,

I am hoping that someone might be able to help me. I have an applet that is used to view images. I use JAI to decode and load these TIF images (which are saved on the Applet's web server) to Swing components that allow a user to zoom in and out of the image, inverse the colors, and perform a few other functions. I am using jnlp to deploy the Applet and the associated classes and libraries, and I am trying to do this without signing the jars. Everything works perfectly (I can load images, zoom in and out, flip colors around and everything else), except when I click a button in the viewer that is supposed to interpolate the image (smooth out the rough edges by guessing at pixels). The interpolation method looks like this:



The above code runs completely through, but something breaks down between the completion of the above method and the point where the new image is drawn to my viewer. The error I get is this:



I cannot for the life of me figure out where or why JAI would be running into a security exception, especially when accessing a class that is included in the java runtime. What's more, I have no idea why it is using "sun.awt.image" (all of the awt classes I see being used are from the package "java.awt.image"). Everything works fine if I run this using an applet viewer in my development environment, or if I sign all of the jar files and set up the security permissions in the jnlp files, but I *really* want to avoid having signed jars.

I would greatly appreciate any help anyone has to offer!
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41634
    
  55
I'm not sure either why it needs that class, but the use of sun.* classes by the applet code requires the code to be signed.


Ping & DNS - my free Android networking tools app
J Ellis
Greenhorn

Joined: Aug 23, 2009
Posts: 27
Thank you for the information, Ulf. I guess I am out of luck!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Java Advanced Imaging throwing AccessControlExceptions when I try to perform a rendering operation