Hi,
I have a question as to how I can send an already existing image (i.e. ".jpg", ".gif" as the response of an HttpServletRequest.
I was able to send an image back as a response when I generate the image dynamically. That is, I create a JFrame object, paint it, then convert to JPeg with the JPeg encoder, then send it back on the Output stream of the response object.
What I want to do now is to be able to load a gif/jpeg image, draw on it, and then send the combination back on the Output stream as an image (preferably gif, but will accept anything for now).
I would appreciate any help in this matter. I would really prefer a end-to-end example, as supposed to some code tid-bits, because i'm still not completely familiar with all the different paint/paintComponents/.... methods (as far as who to call, and when, and why).
Thanks for any help
Marwan
I have a question as to how I can send an already existing image (i.e. ".jpg", ".gif" as the response of an HttpServletRequest.
I was able to send an image back as a response when I generate the image dynamically. That is, I create a JFrame object, paint it, then convert to JPeg with the JPeg encoder, then send it back on the Output stream of the response object.
What I want to do now is to be able to load a gif/jpeg image, draw on it, and then send the combination back on the Output stream as an image (preferably gif, but will accept anything for now).
I would appreciate any help in this matter. I would really prefer a end-to-end example, as supposed to some code tid-bits, because i'm still not completely familiar with all the different paint/paintComponents/.... methods (as far as who to call, and when, and why).
Thanks for any help
Marwan