使用ImageProcessor.Web(http://imageprocessor.org/imageprocessor-web/imageprocessingmodule/resize/)调整大小模块,我可以将图像裁剪为定义的大小,例如:
<img src="~/Content/img/fiji-01.jpg?width=500&height=500&mode=crop¢er=0.1,0.1"/>
但是如何将图片放大两倍大小和裁剪?
尝试过类似的事情:
<img src="~/Content/img/fiji-01.jpg?mode=crop¢er=0.9,0.9&heightratio=3&widthratio=3&height=500" />
没有用。
答案 0 :(得分:1)
我必须设置Umbraco并使用GetCroppedUrl方法来查看它是如何工作的。碰巧我们使用crop模块后跟resize模块,如:
.buildout/eggs/ZConfig-2.9.0-py2.7.egg/ZConfig/loader.py", line 217, in schemaComponentSource
package=package)
ZConfig.SchemaResourceError: could not load package ZServer:
.buildout/eggs/zope.security-3.7.4-py2.7-linux-x86_64.egg/zope/security/_proxy.so: undefined symbol: SSLv2_method
Package name: 'ZServer'
File name: 'component.xml'
Package path: None
或
<img src="~/Content/img/fiji-01.jpg?crop=0.23159636062861869,0.061207609594706371,0.023986765922249794,0.19437551695616212&cropmode=percentage&width=500&height=500" />