py-img-processor 1.3.2__tar.gz → 1.3.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. {py_img_processor-1.3.2/py_img_processor.egg-info → py_img_processor-1.3.3}/PKG-INFO +1 -1
  2. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/__init__.py +1 -1
  3. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/enums.py +1 -1
  4. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/blur.py +1 -1
  5. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/processor.py +1 -1
  6. {py_img_processor-1.3.2 → py_img_processor-1.3.3/py_img_processor.egg-info}/PKG-INFO +1 -1
  7. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/LICENSE +0 -0
  8. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/MANIFEST.in +0 -0
  9. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/README.md +0 -0
  10. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/exceptions.py +0 -0
  11. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/main.py +0 -0
  12. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/__init__.py +0 -0
  13. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/alpha.py +0 -0
  14. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/base.py +0 -0
  15. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/circle.py +0 -0
  16. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/crop.py +0 -0
  17. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/gray.py +0 -0
  18. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/merge.py +0 -0
  19. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/resize.py +0 -0
  20. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/rotate.py +0 -0
  21. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/parsers/watermark.py +0 -0
  22. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/imgprocessor/utils.py +0 -0
  23. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/py_img_processor.egg-info/SOURCES.txt +0 -0
  24. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/py_img_processor.egg-info/dependency_links.txt +0 -0
  25. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/py_img_processor.egg-info/entry_points.txt +0 -0
  26. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/py_img_processor.egg-info/not-zip-safe +0 -0
  27. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/py_img_processor.egg-info/requires.txt +0 -0
  28. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/py_img_processor.egg-info/top_level.txt +0 -0
  29. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/setup.cfg +0 -0
  30. {py_img_processor-1.3.2 → py_img_processor-1.3.3}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: py-img-processor
3
- Version: 1.3.2
3
+ Version: 1.3.3
4
4
  Summary: Image editor using Python and Pillow.
5
5
  Home-page: https://github.com/SkylerHu/py-img-processor.git
6
6
  Author: SkylerHu
@@ -7,7 +7,7 @@ from PIL import Image
7
7
 
8
8
 
9
9
  __all__ = ["settings", "VERSION"]
10
- __version__ = "1.3.2"
10
+ __version__ = "1.3.3"
11
11
 
12
12
 
13
13
  VERSION = __version__
@@ -8,7 +8,7 @@ class ImageFormat(ChoiceEnum):
8
8
 
9
9
  JPEG = ("JPEG", "JPEG")
10
10
  PNG = ("PNG", "PNG")
11
- WEBP = ("WebP", "WebP")
11
+ WEBP = ("WEBP", "WebP")
12
12
 
13
13
 
14
14
  class ImageOrientation(ChoiceEnum):
@@ -13,7 +13,7 @@ class BlurParser(BaseParser):
13
13
  KEY = enums.OpAction.BLUR.value
14
14
  ARGS = {
15
15
  # 模糊半径,值越大,图片越模糊
16
- "r": {"type": enums.ArgType.INTEGER.value, "required": True, "min": 1, "max": 50},
16
+ "r": {"type": enums.ArgType.INTEGER.value, "required": True, "min": 1, "max": 512},
17
17
  }
18
18
 
19
19
  def __init__(
@@ -31,7 +31,7 @@ class ProcessorCtr(object):
31
31
  ) -> typing.Optional[typing.ByteString]:
32
32
  fmt = kwargs.get("format") or im.format
33
33
 
34
- if fmt and fmt.upper() == enums.ImageFormat.JPEG.value and im.mode == "RGBA":
34
+ if fmt and fmt.upper() == enums.ImageFormat.JPEG.value and im.mode not in ["GBA", "L"]:
35
35
  im = im.convert("RGB")
36
36
 
37
37
  if not kwargs.get("quality"):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: py-img-processor
3
- Version: 1.3.2
3
+ Version: 1.3.3
4
4
  Summary: Image editor using Python and Pillow.
5
5
  Home-page: https://github.com/SkylerHu/py-img-processor.git
6
6
  Author: SkylerHu