Metadata-Version: 2.4
Name: pyxpo-image-manipulator
Version: 0.1.0a1
Summary: On-device image processing for pyxpo apps: info, crop, resize, convert, strip metadata, compress under a size.
Author: Vishal Chaubey
License-Expression: MIT
Project-URL: Homepage, https://github.com/pyxpo/pyxpo/tree/main/packages/image-manipulator
Project-URL: Issues, https://github.com/pyxpo/pyxpo/issues
Keywords: pyxpo,pyxpo-module,mobile,android,ios
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Software Development :: User Interfaces
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pyxpo<0.2,>=0.1.0a1
Dynamic: license-file

# pyxpo-image-manipulator

On-device image processing for pyxpo apps: info, crop, resize, convert, strip metadata, compress under a size.

This is an optional [pyxpo](https://github.com/pyxpo/pyxpo) native module. Apps that do not
list it carry none of its code, permissions or dependencies.

## Install

```bash
pip install pyxpo-image-manipulator
```

Then link it into your app in `pyproject.toml`:

```toml
[tool.pyxpo]
modules = ["image-manipulator"]
```

and rebuild (`pyxpo run ios`, `pyxpo build android`, ...). The build copies the module's Swift and Kotlin
sources into the native project and its Python package into the app.

## Use

```python
from pyxpo_image_manipulator import ImageManipulator

info = await ImageManipulator.getInfo(path)
small = await ImageManipulator.compressToSize(path, maxBytes=200_000)
```

Permissions and Info.plist keys: none.

## What is in the package

- `pyxpo_image_manipulator/__init__.py`: the Python API.
- `pyxpo_image_manipulator/pyxpo-module.json`: autolink metadata (bridge name, Swift and Kotlin classes, Android namespace and dependencies, Info.plist keys).
- `pyxpo_image_manipulator/ios/`: Swift sources compiled into the iOS app.
- `pyxpo_image_manipulator/android/src/main/`: Kotlin sources and the manifest merged into the Android app.
