Metadata-Version: 2.4
Name: pdf-image-kit
Version: 0.1.0
Summary: Extract embedded, inline, rendered, and vector-backed images from PDF files
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: PyMuPDF<2,>=1.26

# pdf-image-kit

`pdf-image-kit` 是一个独立的 PDF 图片提取包，专注于把 PDF 里的候选图片提取出来。

## 能力

- 提取嵌入位图
- 提取内联图片块
- 在必要时渲染页面片段作为回退
- 提取大块矢量图区域
- 支持导出到磁盘或直接返回内存结果

## 安装

```bash
pip install pdf-image-kit
```

## 作为 Python 包调用

安装包名是 `pdf-image-kit`，导入模块名仍然是 `pdf_image_extractor`。

```python
from pdf_image_extractor import extract_images, extract_images_from_bytes

manifest = extract_images(
    pdf_path="/path/to/demo.pdf",
    output_dir="./out/demo",
    min_width=1,
    min_height=1,
    render_dpi=216,
    dedupe=True,
    vector_min_width=80,
    vector_min_height=60,
    vector_padding=6,
)

print(manifest["exported_images"])
```

## CLI

```bash
pdf-image-extract /path/to/demo.pdf -o ./out
```
