This week's book giveaway is in the Jython/Python forum.
We're giving away four copies of Murach's Python Programming and have Michael Urban and Joel Murach on-line!
See this thread for details.
Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

how to provide ROI ( Region of Interest ) in applying Median Filter using JAI?  RSS feed

 
ashish donvir
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am applying median filter to my image to remove noise from it. But instead of removing noise from whole image i need to provide a particular region or to process the median filter. i tried like this but it is not working and giving error like this

Exception in thread "main" java.lang.IllegalArgumentException: MedianFilter - Parameter value`s class (javax.media.jai.ROIShape) is not an instance of the parameter class (javax.media.jai.operator.MedianFilterShape) for parameter "maskShape". at javax.media.jai.JAI.createNS(JAI.java:1087) at javax.media.jai.JAI.create(JAI.java:973) at javax.media.jai.JAI.create(JAI.java:1395) at noiseremove.NoiseRemove.main(NoiseRemove.java:86)

here is part of my code what i tried it works perfect if i do not providing the ROI
 
Darryl Burke
Bartender
Posts: 5167
11
Java Netbeans IDE Opera
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!