0

This should be the last post of 3 that i made about my personal project (*)

The other two you can acess with these links(**) :

  1. Java screen capture App - How to?
  2. Select, Copy and Paste Images
  3. (is here):

@YohanesKhosiawan许先汉 gave me an advice. He said to me that i should use a list of rectangles to store all the selected images and when i pressed the (OK) button the program will concatenate it all in an single horizontal line (at the same file). So i had a new idea: Create a new button that when it is pressed it starts to save the nexts rectangles (images) in another lists and when i pressed [ (OK) button or this button again ] the program will concatenate this file under the first horizontal line (all at the same file).

I think i'll have to compare the heigth of all images of the horizontal line above. For example the first image of the horizontal line below drawImage(img, 0, biggest_height, null);

I tried to declare the list on tradicional way but it didnt work because it has limited length. then i tried to use this code:

ArrayList<Rectangle> al = new ArrayList<Rectangle>(); 

al.add(new Rectangle(x, y, w, h));

but it didn't work again. why ? how can i make this ?

(*) this project is to help me study. I study at a public Highschool in Sao Paulo, Brazil. The school dont have books for all so i have to download mines (pdf). This app will help me to resume the text-book.

(**) I have to thanks @MadProgrammer for the support from the beggining. All the credits of this app goes for him and for @YohanesKhosiawan许先汉

Community
  • 1
  • 1
  • 1
    *"but it didn't work again"* in what didn't it work? – MadProgrammer Oct 29 '14 at 02:42
  • the list isnt storing the images – Marco Vinicius Oct 29 '14 at 03:04
  • 1
    the list supposed to store rectangles of the area-of-interest, and in the end when you are done with selecting areas, you have to get sub-images based on the stored rectangles from the source image. And actually in the previous post, MadProgrammer's answer is also one alternative. just different way with mine, but it serves your requirement. – Yohanes Khosiawan 许先汉 Oct 29 '14 at 03:06

0 Answers0