Questions tagged [im4java]

The library im4java provides a pure-java interface to ImageMagick, GraphicsMagick and other popular commandline tools like jpegtran, ufraw, dcraw, exiftool. The im4java-engine permits the addition of new tools in a very short time (less than an hour)

The basic architecture of im4java is quite simple. It boils down to calling all underlying tools simply by using a ProcessBuilder-object. All the magic of im4java ist to hide the complexities. If you have just one simple call of an external tool in your program, you might be better of by hardcoding the ProcessBuilder-call yourself. If you don't need the simplicity or the advanced features of the im4java-library, your code will certainly be faster and more efficient.

73 questions
2
votes
1 answer

Draw a circle using im4java

I need to draw a circle and save it as an image in a directory. I want to draw the image using im4java. I have tried to create, but there is no IMoperation available in im4java. Any help???
2
votes
1 answer

Best way to compare 2 images in Java jUnit?

I'm writing a junit test case to validate a cropping and resizing class. The class is fairly simple, it just delegates the calls to ImageMagick via Im4Java. But to do things properly, I am trying to write up a jUnit test case. I manually created…
Eric B.
  • 23,425
  • 50
  • 169
  • 316
2
votes
1 answer

How to improve image quality using im4java?

I'm using im4java library for image processing operations with ImageMagick. The code I'm using looks like: ImageCommand imageCommand = new ConvertCmd(); imageCommand.setSearchPath(getImageMagickPath()); operation = new…
Czarina
  • 21
  • 1
  • 2
2
votes
1 answer

GraphicsMagick + im4java, how can I remove color profile (and other redundant data)

I'm using graphicsmagick + im4java for generating thumbnails in my web application. Unfortunately as I can see, while processing pictures taken with photo cameras, the thumbnails contains all original data such color profile, aperture, camera's…
biesior
  • 55,576
  • 10
  • 125
  • 182
2
votes
0 answers

im4java overlay image overlay

I have two images of different sizes. If I want to overlay the smaller one on the bigger one with the given position, how should I use the CompositeCmd to do this? thanks hammer
Hammer
  • 8,538
  • 12
  • 44
  • 75
2
votes
2 answers

im4java, mac run issue

Every time when I try to run im4java in my java app got this error: org.im4java.core.CommandException: org.im4java.core.CommandException: dyld: Library not loaded: /ImageMagick-6.7.7/lib/libMagickCore.5.dylib at…
goodm
  • 7,275
  • 6
  • 31
  • 55
1
vote
0 answers

im4java: is possible create a final image using others different images?

My project give me 3 images: track.jpg (background full size) pilote.jpg (40% of full size, position left) car.jpg (40% of full size, position right) Basically I need to get these 3 images resize and reposition it, and finally create a new…
LeandroPL
  • 503
  • 5
  • 8
1
vote
0 answers

Create Solid color rectangle with ImageMagick

I can not find any command to create solid color with rgb options in Java. I can create it in commandLine like convert -size 100x200 xc:rgb(0,255,255) whatever.jpg from here But how do that in Java? Something like this: ConvertCmd cmd =…
Dred
  • 1,076
  • 8
  • 24
1
vote
0 answers

Unable to access folder location war!\WEB-INF\classes\ in packaged war with Spring boot

I want to access my resource folder path which is inside the packaged WAR created by spring boot. I have looked this link, which is to access specific file at some location but I am looking for just the folder location. With WAR file getRealPath() /…
Ravi
  • 195
  • 3
  • 15
1
vote
1 answer

ImageMagick unable to find the path of convert.exe in packed WAR of Spring boot

I am using ImageMagick to crop image file. I am deploying packed WAR with ImageMagick inside. searchForCmd() function of ProcessStarted class is unable to find the files of ImageMagick from WEB-INF/classes…
Ravi
  • 195
  • 3
  • 15
1
vote
1 answer

Azure : Image Magick gives 0kb output?

I have integrated Image magick with a Java WebApp and have deployed it on Azure App Service. On azure , I am getting 0kb as output image for a image while the same image gets converted fine on my local machine. I am using im4java for integration…
1
vote
0 answers

Composite operation with im4java - imageMagick

I want to use imagemagick/im4java to combine two images into a single image - I have a command that works great in command line. 'composite -gravity center -geometry +25+0 image1.png -compose multiply …
Programmer
  • 59
  • 2
1
vote
2 answers

How to resize a buffered Image using im4java and get the output as bufferedImage?

When I am trying to resize a image i am getting an exception saying "java.lang.IllegalStateException: no ImageReader for given format". public static void main(String... args) throws Exception { IMOperation op = new IMOperation(); …
Debojit Paul
  • 213
  • 4
  • 12
1
vote
1 answer

batch combine multiple tif in a directory

I have 200x3 tif files in a folder which is to to be combined in multi-page tif files like 1_1.tif,1_2.tif,1_3.tif-->1_m.tif 2_1.tif,2_2.tif,2_3.tif-->2_m.tif .......... 200_1.tif,200_2.tif,200_3.tif-->200_m.tif Can i have a command line solution…
1
vote
1 answer

How to get im4java working with BufferedImage

I am using im4java version 1.4.0 to access ImageMagick functionality from Java. It is working well for processing images to and from files. The Developers Guide has a section on using Buffered Images instead of writing output to a file, and there is…
Glennn
  • 467
  • 1
  • 7
  • 18