Well, I got it to work! :) Thanks so much for all the help. The issue was that by drawing an image, all the transparency was being filled. The solution was to draw the painted image on the component,...
Type: Posts; User: JavaInProgress
Well, I got it to work! :) Thanks so much for all the help. The issue was that by drawing an image, all the transparency was being filled. The solution was to draw the painted image on the component,...
The only thing in the top layer is just the text. Shouldnt the rest of the top layer be transparent already?
yes, but then the image (bottom layer) will have the text in it. the goal was to display both layers, but keep them separate so that I can save the bottom layer without having the top layer being...
there is another layer behind it that lets you use the mouse to draw. The issue is this bottom layer isn't visible through the top layer with the text. the goal is to be able to paint on the bottom...
Trimmed the fat out
I swapped the code for paintListener to print a sentence in the middle instead of using images. I might have done that after you ran the version that used images. try and use the paintListener class...
The new code above now compiles
Ok, I've been working on it for a while now. I've been able to get past your step 3, but I'm stuck again. I have two graphics objects that are being edited offscreen, but when I use paintComponent()...
I'm not sure what you mean. Are you saying to cast a Graphics2D onto a BufferedImage?
Edit:
Ok, here is what I've changed. No compilation errors, but the image won't appear:
BufferedImage...
From what I've found so far, it seems like I will want to create a BufferedImage that corresponds to each Graphics2D object (I think).
BufferedImage layerOneImage = new...
Thanks for the link! As for the buffering method, that's the same concept as what I did for the prototype in my link. I just don't know how to implement it in java :confused:
1) the 'layer' that I'm referring to would be the equivalent to a transparency slide that is being painted on. If you were to take these and then stack them on top of each other, you would be able to...
There is no compilation error, but it isn't doing what I would like it to do. Currently, if your mouse is dragged, it will draw a line from your previous position to your current position with a...
I'm starting a new paint project to get some experience with java.:confused: I've been working with Processing for a while, and I'm struggling to transition. :-s The goal is to make a program in...