Justin 

Thanks I was aware of this, I thought there were some other advantages
over AWT.

Kola

>> -----Original Message-----
>> From: Justin [mailto:[EMAIL PROTECTED]
>> Sent: 05 February 2004 12:56
>> To: [EMAIL PROTECTED]
>> Subject: RE: [ cf-dev ] java image manipulation on RH7.2
>> 
>> 
>> AWT is a windows toolkit, which you can use indirectly to do image
stuff.
>> It
>> abstracts the windowing system of the host platform (AWT = Abstract
>> Windowing Toolkit)
>> 
>> JIA on the otherhand is a native image manipulation lib. that doesn't
>> rely
>> on any windowing system being installed on the host.
>> 
>> 
>> 
>> Justin
>> 
>> -----Original Message-----
>> From: Kola Oyedeji [mailto:[EMAIL PROTECTED]
>> Sent: 05 February 2004 12:29
>> To: [EMAIL PROTECTED]
>> Subject: RE: [ cf-dev ] java image manipulation on RH7.2
>> 
>> 
>> 
>> Could you elaborate on this Steven?
>> 
>> Any particular reason why?
>> 
>> Kola
>> 
>> >> -----Original Message-----
>> >> From: Steven Harper [mailto:[EMAIL PROTECTED]
>> >> Sent: 05 February 2004 09:08
>> >> To: [EMAIL PROTECTED]
>> >> Subject: RE: [ cf-dev ] java image manipulation on RH7.2
>> >>
>> >> Don't use AWT, use JAI
>> >>
>> >> -----Original Message-----
>> >> From: Stephen Moretti [mailto:[EMAIL PROTECTED]
>> >> Sent: 04 February 2004 15:41
>> >> To: [EMAIL PROTECTED]
>> >> Subject: [ cf-dev ] java image manipulation on RH7.2
>> >>
>> >>
>> >> How do I get myself into these situations???!!!
>> >>
>> >> I've got some code that accesses various java objects to resize
>> images.
>> >>   It all seems about right, but I'm getting:
>> >>
>> >> "This graphics environment can be used only in the software
emulation
>> >> mode"
>> >>
>> >> Now I know that this is related to the server being a "headless"
>> graphic
>> >> environment and have seen the MM article :
>> >>
>>
http://www.macromedia.com/support/coldfusion/ts/documents/graphics_unix_
>> 1
>> >> 41jvm.htm#
>> >> and made the appropriate changes to the jvm.config
>> >>
>> >> Thing is I'm still getting the same error.  If anyone has any
ideas
>> why
>> >> this might be I'd appreciate the help.
>> >>
>> >> The box is running cfmx6.1 on RH 7.2 using Sun JVM 1.4.2-b28
>> >>
>> >> The code for the image manipulation is below.  Let me know if I've
>> >> knacked something....
>> >>
>> >> TIA
>> >>
>> >> Stephen
>> >>
>> >> <cfscript>
>> >> newfile = variables.profileimagepath&CFFile.ServerFile;
>> >> imageObject = CreateObject("java", "javax.imageio.ImageIO");
>> fileObject =
>> >> CreateObject("java", "java.io.File"); fileObject.init(newfile);
>> thisImage
>> >> = imageObject.read(fileObject); width = thisImage.getWidth();
height
>> =
>> >> thisImage.getHeight(); if (width gt variables.imagewidth) {
>> >>   scale = height/width;
>> >>   newheight = variables.imagewidth*scale;
>> >>   BufferedImage =
>> >> CreateObject("java","java.awt.image.BufferedImage");
>> >>   BufferedImage.init(JavaCast("int",variables.imagewidth),
>> >> JavaCast("int", newheight), JavaCast("int", 1));
>> >>   geoAffTransform =
>> >> createObject("java","java.awt.geom.AffineTransform");
>> >>   geoAffTransform.init();
>> >>   geoAffTransform.scale(scale, scale);
>> >>   newimage = BufferedImage.createGraphics();
>> >>          newimage.drawRenderedImage(thisImage, geoAffTransform);
>> >>          newimage.dispose();
>> >>
>>
outputfile=fileObject.init("#variables.profileimagepath##request.LoggedI
>> n
>> >> #.jpeg");
>> >>          imageObject.write(newimage, "jpeg", outputfile);
>> >> }
>> >> </cfscript>
>> >>
>> >> --
>> >> ** Archive:
>> http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
>> >>
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
For
>> >> human help, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >> --
>> >> ** Archive:
>> http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
>> >>
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >> For human help, e-mail: [EMAIL PROTECTED]
>> 
>> 
>> --
>> ** Archive:
http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
>> 
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>> For human help, e-mail: [EMAIL PROTECTED]
>> 
>> 
>> 
>> --
>> ** Archive:
http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
>> 
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>> For human help, e-mail: [EMAIL PROTECTED]


-- 
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]

Reply via email to