Results 1 to 4 of 4
- 09-06-2011, 08:24 PM #1
Crop many images out of one image? Please help!
I just figured out how I can crop an image in Java using the following code:
Now I need some help with giving it specified parts, so that I can get out more than one image from this single image.Java Code:*Picture* = createImage(new FilteredImageSource(*Picture*.getSource(), new CropImageFilter(0, 0, 50, 50)));
Right now it is just cropping the current image. When you're using it you just type in *Picture* & it will get used.
So what I want is pretty much an array of those images cropped from the same one.
Thanks!
AhCurrently Developing a Game Called Loaie, You Can Download It From "The Loaie Website".
- 09-06-2011, 08:36 PM #2
Re: Crop many images out of one image? Please help!
Sorry, I don't know where your problem with doing this is. It seems its just some simple steps that you must know how to do:
Do you know how to create an array of the image object? Or perhaps an arraylist
Do you know how to address elements in that array?
Can you create an image object? The posted code looks like it does that.
Put those steps together,figure out how to vary the x,y, width and height for the region of the image you want and make a loop to do it.
- 09-06-2011, 08:45 PM #3
Re: Crop many images out of one image? Please help!
Is that Java or something else? What are the asterisks around Picture supposed to do?
If that's Java -- check out BufferedImage#getSubimage(...)what I want is pretty much an array of those images cropped from the same one.
db
- 09-06-2011, 09:10 PM #4
Re: Crop many images out of one image? Please help!
I solved it, I did as you said "Norm". I created an array of images & just cutted parts of each image out.
Thanks!Currently Developing a Game Called Loaie, You Can Download It From "The Loaie Website".
Similar Threads
-
How to show image on images
By johny2011 in forum AWT / SwingReplies: 5Last Post: 05-19-2011, 01:51 PM -
image web query from text argument? Like google images?
By minime12358 in forum New To JavaReplies: 0Last Post: 03-08-2011, 02:28 AM -
how to mark on 2 images at a time,both images are on different JPanel
By smitharavi in forum AWT / SwingReplies: 0Last Post: 12-16-2010, 05:14 PM -
how to scroll 2 images at a time(synchronisation),both images are on different panels
By smitharavi in forum AWT / SwingReplies: 4Last Post: 12-16-2010, 04:32 PM -
Converting multiple banded image into single banded image... Image enhancement
By archanajathan in forum Advanced JavaReplies: 0Last Post: 01-08-2008, 05:29 PM


2Likes
LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks