Forum OpenACS Development: Re: Image resizing, exec and server problems

Collapse
Posted by Tom Jackson on
I'm not sure how much help is available for ns_proxy, but this should be fixed. Obviously you need AOLserver 4.5, and there is a new pools.tcl file in CVS which can be used to adjust the base number of threadpools.

I just posted the htmlized man page for nsproxy:

http://junom.com/document/aolserver/nsproxy/ns_proxy.html

Collapse
Posted by Malte Sussdorff on
I stuffed the pools.tcl into acs-tcl/packages/tcl/pools-init.tcl as I am fairly certain most people will forget that when they download AOLserver and most wont download the latest CVS checkout anyway, but the release.

Alternatively I can use the one provided by AOLserver now and put it into my install directions, which is probably preferred. Tom, if you look at http://cognovis.de/developer/en/aolserver_install would it be included by default or would I need to get it separately (which is what I assume)? If yes, where from and where to put it to? Additionally does it need special treatment in the config.tcl file?

Collapse
Posted by Tom Jackson on
I don't think the ns_pools has anything to do with ns_proxy. I haven't used ns_proxy, but just provided a link to the manpage.

I have some scripts for image resizing if there is an interest.

Collapse
Posted by Malte Sussdorff on
Just for clarification. The pools-init.tcl has nothing to do with the resizing issue. It was just a reply to Tom's comment and badly connected as such. Just in case people get confused.

Tom, have you had a look at the image:: procedures written by Dave? I think a comparison what they do and at which level (inside TCL or outside with imagemagick, alternatives) they interface would be interesting.

Collapse
Posted by Tom Jackson on
Malte, Dave:

I haven't seen how the image procedures work here. I wrote a module for AOLserver which allows upload of a gzip file of original images and extracts them. Then creates a series of smaller versions of each image. You can specify the sizes and a number of other options.

Most of it is not useful outside of the package, but I noticed a single procedure which takes some options for convert and creates a conversion string. There are a lot of options and you can't just plug them in, they have to be calculated. It also detects the orientation of the image.

The proc is ::qphoto::photo::convertOptions and is available in this page, near the bottom:

http://rmadilo.com/m2/servers/rmadilo/modules/tcl/twt/packages/quick-photo/tcl/quick-photo-procs.tcl

When working on this I tried Imagemagick loaded into Tcl. It was a shared library and didn't require exec. However I fould it to be significantly slower at conversions than simply exec'ing convert.

An example of the data used as input is in:
http://rmadilo.com/albums/tom/IHD2005/series.rdl

The output data is in:
http://rmadilo.com/albums/tom/IHD2005/photo.rdl

There is a form for testing out the conversion proc here:
http://rmadilo.com/albums/tom/coptions-form