Comments (9)
@astrowq We've released 0.11.0 https://github.com/webp-sh/webp_server_go/releases/tag/0.11.0, please check it out! 😃
from webp_server_go.
A side note: the extra parameters of width and height do not seem to be always working when the values are greater than the original dimension.
e.g. for https://inspirehep.net/files/b5df560358b1bec3f11047cad9bb7bdd, when setting width to be 300px, it's enlarged properly; but not when the width is 600px.
from webp_server_go.
Thanks for your feedback, I understand that there are two parts of information in this issue:
- A feature request that is similar to previous issue/pr: #268 and #270
- Bug that for given example image https://inspirehep.net/files/b5df560358b1bec3f11047cad9bb7bdd, if width set to 600px, the image is not enlarged.
To clarify my understanding on the first one, if there are configs called maxWidth
and maxHeight
set to 500(px), then for a request with get params: some-image.jpg?width=600
A small image with 400x400px will not be stretched to 600x600px
A larger image with 1200x1200px will be resized to 500x500px
A image with 550x550px will be stretched to 600x600px
Did I grasp this correctly?
from webp_server_go.
Not really the same as the issue 268 where they are talking about final file size. I am interested in the dimensions of the converted images, i.e. width and height.
For your example, the maxWidth and maxHeight are supposed to be a hard limit, so a image with 550×550px will be scaled down to 500×500px too, as far as I would like it to be.
from webp_server_go.
For the side note, I will test on more images. If it persists, I can open another issue.
from webp_server_go.
For the side note, I will test on more images. If it persists, I can open another issue.
Do you have any update on this issue?
so a image with 550×550px will be scaled down to 500×500px too,
Sorry I've missed request parameter.
in your issue content, so this feature is to ensure that all images should below the given dimension, so given it's a "request parameter.", assume some requests are made to: /path/image_<id>.jpg?max_width=500&max_height=500
, then
- image_1.jpg with 400x400px will not be resized and will be rendered in 400x400px
- image_2.jpg with 600x600px will be resized to 500x500px
- image_3.jpg with 400x1000px will be resized to 200x500px
- image_4.jpg with 1000x1000px will be resized to 500x500px
Am I getting it right?
from webp_server_go.
Yes, you are right!
Unfortunately, the issue appears for some images but works fine for others. I can't really find any pattern. I will open an issue when I find time to do it.
Also, there was another weird problem when I tried to migrate to a new server: it stops for no reason and restarts. I will report it later!
from webp_server_go.
@astrowq We're planning to include this feature in our next major version, draft PR #321
BTW, is there any update on theses two issues:
- "the issue appears for some images but works fine for others. I can't really find any pattern. I will open an issue when I find time to do it."
- "there was another weird problem when I tried to migrate to a new server: it stops for no reason and restarts. I will report it later!"
from webp_server_go.
Many thanks for the work!
Regarding the two possible issues, I haven't got time to investigate them
But will report if they appear again and persist.
from webp_server_go.
Related Issues (20)
- Clear older files autometically HOT 2
- Image not found! HOT 2
- Readme broken link HOT 1
- Exclude certain sub folder HOT 1
- A problem converting GIF images to AVIF format HOT 6
- When the instantaneous request volume is large, a large amount of CPU and memory will be consumed. HOT 1
- Couldn't load xx.ico file HOT 3
- How do I configure and exclude links in MP4 format? HOT 5
- Server don't conversions images to jxl format in Firefox Nightly HOT 3
- Cropping mode environment variable HOT 4
- Directory traversal with malformed HTTP request HOT 3
- Webp Cloud是不是比开源的这个支持更多功能? HOT 1
- 多路径域名识别错误 HOT 6
- file without extension HOT 6
- 如何限制硬盘的使用 HOT 15
- MultiPath(IMG_MAP) not working HOT 2
- 关于非图片资源自动回源的问题 HOT 2
- Image conversion to webp failed HOT 2
- 图片缓存问题 HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from webp_server_go.