resize image and memory limits

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Bob Bedford

    resize image and memory limits

    Hi all,

    I've to resize uploaded images with the "imagecopyresam pled" but when I've
    images quite large (common those days) I reach the 16mb limits of the ISP.

    How can I fix this ? I absolutely need to resize such images.

    Bob


  • none

    #2
    Re: resize image and memory limits

    Bob Bedford wrote:
    Hi all,
    >
    I've to resize uploaded images with the "imagecopyresam pled" but when I've
    images quite large (common those days) I reach the 16mb limits of the ISP.
    >
    How can I fix this ? I absolutely need to resize such images.
    >
    Bob
    >
    >
    Iirc Imagemagick handles these resizes more memory efficiently

    Check Imagick in php>5

    Arjen

    Comment

    • Bob Bedford

      #3
      Re: resize image and memory limits

      "none" <""arjen\"@(non e)"a écrit dans le message de news:
      4684f2a2$0$2372 4$dbd45001@news .wanadoo.nl...
      Bob Bedford wrote:
      >Hi all,
      >>
      >I've to resize uploaded images with the "imagecopyresam pled" but when
      >I've images quite large (common those days) I reach the 16mb limits of
      >the ISP.
      >>
      >How can I fix this ? I absolutely need to resize such images.
      >>
      >Bob
      Iirc Imagemagick handles these resizes more memory efficiently
      >
      Check Imagick in php>5
      >
      Thanks for replying Arjen,

      for what I've readed, it needs to install something on the server. I've no
      access to the server neither command line or exec functions.
      It's there any way to use it or maybe I'm wrong (I've checked the site
      http://www.imagemagick.org/ and http://www.magickwand.org/)

      Bob


      Comment

      • none

        #4
        Re: resize image and memory limits

        Bob Bedford wrote:
        "none" <""arjen\"@(non e)"a écrit dans le message de news:
        4684f2a2$0$2372 4$dbd45001@news .wanadoo.nl...
        >Bob Bedford wrote:
        >>Hi all,
        >>>
        >>I've to resize uploaded images with the "imagecopyresam pled" but when
        >>I've images quite large (common those days) I reach the 16mb limits of
        >>the ISP.
        >>>
        >>How can I fix this ? I absolutely need to resize such images.
        >>>
        >>Bob
        >Iirc Imagemagick handles these resizes more memory efficiently
        >>
        >Check Imagick in php>5
        >>
        Thanks for replying Arjen,
        >
        for what I've readed, it needs to install something on the server. I've no
        access to the server neither command line or exec functions.
        It's there any way to use it or maybe I'm wrong (I've checked the site
        http://www.imagemagick.org/ and http://www.magickwand.org/)
        >
        Bob
        >
        >
        see phpinfo() and check for imagick and on the shell try #locate convert
        to see if imagemagicks convert has been installed.

        Otherwise tell your provider he's an idiot and ask for imagemagick :-)

        Arjen

        Comment

        • Richard

          #5
          Re: resize image and memory limits


          "Bob Bedford" <bob@bedford.co mwrote in message
          news:4684e4db$0 $3784$5402220f@ news.sunrise.ch ...
          Hi all,
          >
          I've to resize uploaded images with the "imagecopyresam pled" but when I've
          images quite large (common those days) I reach the 16mb limits of the ISP.
          >
          How can I fix this ? I absolutely need to resize such images.
          >
          Bob
          Hi Bob,

          maybe you can resize them first to an intermediate size using
          'imagecopyresiz ed', hoping that resizing takes up less memory than
          resampled.

          Richard




          Comment

          • Bob Bedford

            #6
            Re: resize image and memory limits


            "Richard" <root@localhost a écrit dans le message de news:
            46853375$0$2235 9$dbd45001@news .euronet.nl...
            >
            "Bob Bedford" <bob@bedford.co mwrote in message
            news:4684e4db$0 $3784$5402220f@ news.sunrise.ch ...
            >Hi all,
            >>
            >I've to resize uploaded images with the "imagecopyresam pled" but when
            >I've images quite large (common those days) I reach the 16mb limits of
            >the ISP.
            >>
            >How can I fix this ? I absolutely need to resize such images.
            >>
            >Bob
            >
            Hi Bob,
            >
            maybe you can resize them first to an intermediate size using
            'imagecopyresiz ed', hoping that resizing takes up less memory than
            resampled.
            >
            Richard
            >
            The memory limit is reached when "loading" the pixels in memory before
            resizing so this solution won't work


            Comment

            • Richard

              #7
              Re: resize image and memory limits


              "Bob Bedford" <bob@bedford.co mwrote in message
              news:4685790f$0 $3782$5402220f@ news.sunrise.ch ...
              >
              "Richard" <root@localhost a écrit dans le message de news:
              46853375$0$2235 9$dbd45001@news .euronet.nl...
              >>
              >"Bob Bedford" <bob@bedford.co mwrote in message
              >news:4684e4db$ 0$3784$5402220f @news.sunrise.c h...
              >>Hi all,
              >>>
              >>I've to resize uploaded images with the "imagecopyresam pled" but when
              >>I've images quite large (common those days) I reach the 16mb limits of
              >>the ISP.
              >>>
              >>How can I fix this ? I absolutely need to resize such images.
              >>>
              >>Bob
              >>
              >Hi Bob,
              >>
              >maybe you can resize them first to an intermediate size using
              >'imagecopyresi zed', hoping that resizing takes up less memory than
              >resampled.
              >>
              >Richard
              >>
              The memory limit is reached when "loading" the pixels in memory before
              resizing so this solution won't work
              Bob,
              I dont know about that...
              It should be possible to resize an image without loading it completely into
              memory.
              You just dont need the full image all the time.

              Did you try it?

              Also there are some upload java applets, that can do some resizing BEFORE
              upload.
              Maybe that way you can get things working?

              If you really need to deal with images that large, then you are probably on
              the wrong webhost.....
              :(

              Richard.


              Comment

              Working...