CGSmartImage filter_croptofit problem

The place to talk about things that are related to CMS Made simple, but don't fit anywhere else.
Post Reply
User avatar
hgpdesign
Forum Members
Forum Members
Posts: 47
Joined: Wed Jul 09, 2008 7:06 am

CGSmartImage filter_croptofit problem

Post by hgpdesign »

Hello everyone,

I have a small problem using CGSmartImage. I want to perform a croptofit action on a image that has only to be cropped in height. F.i. my image is now 924x616px and it has to be cropped to 924x520px. I therefor use this code:

Code: Select all

{CGSmartImage src=$file filter_croptofit='924,520,c' quality=100 noembed=1}
The result I get is an image which is 924px wide but the height is scaled down to 520px instead of cropped to 520px.

I can't see what I am doing wrong. Can someone help me out?

Thanks in advance.

Kind Regards,

Ron Hoenson
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3497
Joined: Mon Nov 28, 2011 9:29 am

Re: CGSmartImage filter_croptofit problem

Post by velden »

could it be that the height is scaled due to stylesheet rules or height attribute in img tag?

In that case it might be possible that cgsi did not change the image file.
User avatar
hgpdesign
Forum Members
Forum Members
Posts: 47
Joined: Wed Jul 09, 2008 7:06 am

Re: CGSmartImage filter_croptofit problem

Post by hgpdesign »

Thanks for your replies.

So, if I understand it correctly there is no way to crop an image from 924x616px to 924x520px with GCSmartImage?

If I do a 'croptofit from f.e. 924x616 to 922x520px is works perfectly fine...).

Thanks again and kind regards,

Ron Hoenson
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm

Re: CGSmartImage filter_croptofit problem

Post by calguy1000 »

So, if I understand it correctly there is no way to crop an image from 924x616px to 924x520px with GCSmartImage?
Not currently. Besides your 'crop' would result in an upscale, which CropToFit won't allow by default.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Post Reply

Return to “The Lounge”