Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-15-2008, 11:56 PM
Member
 
Join Date: Oct 2008
Posts: 4
Rep Power: 0
pedjacar is on a distinguished road
Lightbulb Cutting parts of an image and reordering them
Hi people,

I have checked the forums for image clipping, but it seems that no topic tackles this problem (I'm helping out my girlfriend with her MSc. thesis in psychology):

I need to cut six pieces from an image of a human face (eyebrows, eyes, nosetip and mouth) and display them (only them, rest of the pic remains hidden) but each of them on different, randomly selected position of another piece (e.g. left eyebrow on the position of the mouth, right eyebrow on the position of left eye, left eye on the position of the nose and so on). Image dimensions and coordinates of the image parts are known.

Any ideas? Thanks!
Pedja
Bookmark Post in Technorati
Reply With Quote
  #2 (permalink)  
Old 10-16-2008, 02:42 AM
Member
 
Join Date: Oct 2008
Location: Sweden, Gothenburg
Posts: 21
Rep Power: 0
zoomix is on a distinguished road
Default
BufferedImage has a method that can be useful.

getSubimage(int x, int y, int w, int h)
Returns a subimage defined by a specified rectangular region.

I suppose you could load the original image, get the six subimages and draw them back onto a new image. Or is this not the kind of help you had in mind?
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 10-16-2008, 10:46 AM
Member
 
Join Date: Oct 2008
Posts: 4
Rep Power: 0
pedjacar is on a distinguished road
Default
Yes, that may be the trick I'm looking for...

Is it also possible to extract elliptic part of the image with getSubimage method?

Anyway, I'll try this for now...

Thanks a lot, zoomix!
Bookmark Post in Technorati
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Canvas Image popups another image (SWT) SpaceY New To Java 2 11-11-2008 02:25 PM
Breaking huge text into multiple parts.Please help.. waNnY New To Java 2 02-18-2008 05:24 AM
Converting multiple banded image into single banded image... Image enhancement archanajathan Advanced Java 0 01-08-2008 06:29 PM
Selecting parts of an image shaungoater Java 2D 1 12-15-2007 11:06 PM
Jtree - making parts editable kmarie AWT / Swing 1 07-27-2007 03:34 AM


All times are GMT +2. The time now is 06:17 AM.



VBulletin, Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2009, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org