Original Post
🔒 Locked
[java] tile images
Advertisement
Quote:
Original post by deonbotha
what I want to do it extract each tile and put it in an Image array,
You've got a couple of options. The first - and probably easiest, as you're already using Images - is to simply crop the image using a CropImageFilter.
The second way is to use an array of BufferedImages instead. The main image (tileset) would be loaded using a BufferedImage, and then you'd use the BufferedImage.getSubimage method to obtain the smaller images and copy them.
Both examples (basic usage) are demonstrated here. There are also other Image resources there that might be of interest.
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement
what I want to do it extract each tile and put it in an Image array, how do I go about copying a part of that image specified by coords into a new image?