• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: GC Scale
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GC Scale


  • Subject: Re: GC Scale
  • From: Michelle Steiner <email@hidden>
  • Date: Sun, 27 Jan 2002 07:06:32 -0700

On 1/26/02 10:51 PM, John McAdams <email@hidden> wrote:

>the res stays at 72 and the print doesn't come out so good. I cannot
>find an equivalent for "size" in GC's dictionary. Anyone have a way to
>reduce the dimensions of an image and increase the resolution? I'd be
>happy to hear it.

This is what I do; I haven't tried to print any of the photos, though.
This routine is designed to make a picture no wider than 640 or no higher
than 480, whichever is smaller, while keeping the same proportions as the
original.

--Michelle

(code to select photo goes here)

tell application "GraphicConverter"
open the photo as alias
set the imageDims to the image dimension of window 1
set scaleFactor to my setScaleFactor(imageDims)
scale window 1 horizontal scaleFactor vertical scaleFactor
save window 1 as JPEG with wwwready without makeCopy
close window 1
end tell

on setScaleFactor(imageDims)
set the scaleFactor to 1
set the horiz to item 1 of the imageDims
set the vert to item 2 of the imageDims
if the horiz is greater than the vert then
if the horiz is greater than 640 then set the scaleFactor to 640 / horiz
else
if the vert is greater than 480 then set the scaleFactor to 480 / vert
end if
return the scaleFactor
end setScaleFactor

----------------------------------------------------------------------
| Michelle Steiner | We're not human beings having a spiritual |
| | experience. We're spiritual beings |
| email@hidden | having a human experience. |
----------------------------------------------------------------------


  • Prev by Date: Re: Problems with speed & issues with coercion in OS 9.2.2 (App
  • Next by Date: Thanks: Newbie. How do I count "i"
  • Previous by thread: Re: GC Scale
  • Next by thread: Re: GC Scale
  • Index(es):
    • Date
    • Thread