> -----Original Message-----
> From: Kamal Bhatt [mailto:[EMAIL PROTECTED]
> Sent: woensdag 10 mei 2006 4:19
> To: [email protected]
> Subject: Apologies
> 
> 
> 
>  I need to be more careful. Obviously, the above email was 
> not meant for 
> the mailing list. But now my mistake has been made:
> 
> I had the following pipeline:
> 
> <map:match pattern="images/*/**/*">
>   <map:read src="/data/content/tsg/cmsblocks/holidayImg/{2}/{3}" 
> mime-type="image/jpeg" type="image-op-resize">
>     <map:parameter name="size-width" value="{1}"/>
>     <map:parameter name="size-preserve-ratio" value="true"/>
>   </map:read>
> </map:match>
> 
> Now, this does not preserve ratio, but this does:
> 
> <map:match pattern="images/*/**/*">
>   <map:read src="/data/content/tsg/cmsblocks/holidayImg/{2}/{3}" 
> mime-type="image/jpeg" type="image-op-resize">
>     <map:parameter name="size-width" value="{1}"/>
>     <map:parameter name="size-height" value="1"/>
>     <map:parameter name="size-preserve-ratio" value="true"/>
>   </map:read>
> </map:match>
> 
> I have had a look for the ResizeOperation, and it looks like 
> it doesn't 
> need a height. Am I missing something?
> 

I once used this to resize jpegs (and it worked):

The reader:
<map:reader logger="sitemap.reader.ImageReader" name="imageresource" 
pool-max="32"
        src="org.apache.cocoon.reading.ImageReader"/>

The pipeline:
      <map:match pattern="/binaries/**.jpg"> <!-- so it won't match .gif or 
.png etc -->
        <map:read type="image" 
          mime-type="image/jpg"
          src="/my-path-to-binaries/{1}.jpg">
          <map:parameter name="width" value="50%"/>
        </map:read>
      </map:match> 

You use size-width as parameter, I used width. Maybe that's the difference? Or 
are you using an other reader?


Jasha Joachimsthal

---------

Hippo
Oosteinde 11
1017 WT Amsterdam
The Netherlands
+31 (0)20 5224466 

[EMAIL PROTECTED]
www.hippo.nl

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

Reply via email to