djvu-rs 0.28.0 → 0.30.0

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.
package/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  # djvu-rs
2
2
 
3
3
  [![Crates.io](https://badgen.net/crates/v/djvu-rs)](https://crates.io/crates/djvu-rs)
4
+ [![PyPI](https://img.shields.io/pypi/v/djvu-rs)](https://pypi.org/project/djvu-rs/)
5
+ [![npm](https://img.shields.io/npm/v/djvu-rs)](https://www.npmjs.com/package/djvu-rs)
4
6
  [![docs.rs](https://docs.rs/djvu-rs/badge.svg)](https://docs.rs/djvu-rs)
5
7
  [![CI](https://github.com/matyushkin/djvu-rs/actions/workflows/ci.yml/badge.svg)](https://github.com/matyushkin/djvu-rs/actions/workflows/ci.yml)
6
8
  [![Benchmarks](https://img.shields.io/badge/benchmarks-dashboard-blue)](https://matyushkin.github.io/djvu-rs/dev/bench/)
@@ -8,8 +10,10 @@
8
10
  [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
9
11
 
10
12
  Read, render, convert, and create DjVu files. Pure-Rust library with a CLI,
11
- WebAssembly, and Python bindings — MIT licensed, no GPL dependencies, written
12
- from the public DjVu v3 specification.
13
+ WebAssembly, and Python bindings — on [crates.io](https://crates.io/crates/djvu-rs),
14
+ [PyPI](https://pypi.org/project/djvu-rs/), and [npm](https://www.npmjs.com/package/djvu-rs)
15
+ as `djvu-rs`. MIT licensed, no GPL dependencies, written from the public DjVu v3
16
+ specification.
13
17
 
14
18
  | Your task | How |
15
19
  |-----------|-----|
@@ -17,7 +21,7 @@ from the public DjVu v3 specification.
17
21
  | Extract text (plain, hOCR, ALTO XML) | [`djvu text`](#cli) or [`page.text()`](#text-extraction), [`to_hocr` / `to_alto`](#hocr-and-alto-xml-export) |
18
22
  | Render pages to RGBA pixels | [`render_pixmap`](#quick-start) — sync, [async](#async-render), or [parallel](#feature-flags) |
19
23
  | Show DjVu in the browser | [WebAssembly bindings](#webassembly), incl. lazy HTTP-Range loading |
20
- | Read DjVu from Python | [PyO3 bindings, built from source](#python) |
24
+ | Read DjVu from Python | `pip install djvu-rs` — [PyO3 bindings](#python) |
21
25
  | Create DjVu from images (PNG/JPEG/TIFF) | [`djvu encode`](#cli) or [`PageEncoder`](#encoding--low-level-api) |
22
26
  | Add an OCR text layer to a scan | [`djvu ocr`](#ocr-recognition-backends) (Tesseract) |
23
27
  | Merge, split, edit documents | [`djvu merge` / `djvu split`](#cli), `DocumentEditor`, `DjVuDocumentMut` |
@@ -155,6 +159,12 @@ djvu encode scan.png --quality quality --binarization sauvola --bg-inpaint --out
155
159
  # Cap the IW44 background at a bits-per-pixel budget (smaller file, lower quality)
156
160
  djvu encode scan.jpg --quality quality --bg-bpp 0.8 --output scan.djvu
157
161
 
162
+ # Composite transparent PNG/TIFF pixels onto a solid colour (hex or white/black)
163
+ djvu encode logo.png --background white --output logo.djvu
164
+
165
+ # Refuse ICC-profiled input instead of silently dropping the profile
166
+ djvu encode scan.png --icc reject --output scan.djvu
167
+
158
168
  # Encode a directory of images into a bundled DJVM with shared Djbz
159
169
  djvu encode pages/ --output book.djvu --shared-dict-pages 2
160
170
 
@@ -666,8 +676,9 @@ Honest boundaries, so you can decide fast:
666
676
 
667
677
  - **Library + CLI, not a viewer.** There is no GUI; the WASM demo is the
668
678
  closest thing to one.
669
- - **Python bindings are source-only for now.** The `djvu-py` package is not
670
- published to PyPI yet install it from the repository checkout.
679
+ - **Python bindings cover the reading surface only.** Open, render, and text
680
+ extraction ship in the PyPI wheels; encode, mutation, and PDF/EPUB/TIFF
681
+ export stay on the Rust crate / CLI for now.
671
682
  - **Indirect DJVM mutation is indirect-only via two paths.**
672
683
  `DjVuDocumentMut::from_bytes` + `page_mut` on an indirect index errors;
673
684
  use `from_indirect_resolved` (rebundles) or `IndirectRewritePlan` (rewrites
@@ -797,7 +808,9 @@ MIT. See [LICENSE](LICENSE).
797
808
 
798
809
  Written from the public DjVu v3 specification:
799
810
  - https://www.sndjvu.org/spec.html
800
- - https://djvu.sourceforge.net/spec/DjVu3Spec.djvu (the spec is itself a DjVu file)
811
+ - https://web.archive.org/web/20251005122807/http://www.djvu.org/docs/DjVu3Spec.djvu
812
+ (the spec is itself a DjVu file; archived copy — djvu.org and
813
+ djvu.sourceforge.net no longer serve the original)
801
814
 
802
815
  No code derived from GPL-licensed DjVuLibre or any other GPL source.
803
816
  All algorithms are independent implementations from the spec.
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "djvu-rs",
3
3
  "type": "module",
4
4
  "description": "Read, render, convert, and create DjVu files. Pure-Rust DjVu decoder/encoder with CLI, WebAssembly, and Python bindings. DjVu to PDF, EPUB, TIFF, PNG, and text. MIT licensed, no GPL dependencies.",
5
- "version": "0.28.0",
5
+ "version": "0.30.0",
6
6
  "license": "MIT",
7
7
  "repository": {
8
8
  "type": "git",
package/scalar/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  # djvu-rs
2
2
 
3
3
  [![Crates.io](https://badgen.net/crates/v/djvu-rs)](https://crates.io/crates/djvu-rs)
4
+ [![PyPI](https://img.shields.io/pypi/v/djvu-rs)](https://pypi.org/project/djvu-rs/)
5
+ [![npm](https://img.shields.io/npm/v/djvu-rs)](https://www.npmjs.com/package/djvu-rs)
4
6
  [![docs.rs](https://docs.rs/djvu-rs/badge.svg)](https://docs.rs/djvu-rs)
5
7
  [![CI](https://github.com/matyushkin/djvu-rs/actions/workflows/ci.yml/badge.svg)](https://github.com/matyushkin/djvu-rs/actions/workflows/ci.yml)
6
8
  [![Benchmarks](https://img.shields.io/badge/benchmarks-dashboard-blue)](https://matyushkin.github.io/djvu-rs/dev/bench/)
@@ -8,8 +10,10 @@
8
10
  [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
9
11
 
10
12
  Read, render, convert, and create DjVu files. Pure-Rust library with a CLI,
11
- WebAssembly, and Python bindings — MIT licensed, no GPL dependencies, written
12
- from the public DjVu v3 specification.
13
+ WebAssembly, and Python bindings — on [crates.io](https://crates.io/crates/djvu-rs),
14
+ [PyPI](https://pypi.org/project/djvu-rs/), and [npm](https://www.npmjs.com/package/djvu-rs)
15
+ as `djvu-rs`. MIT licensed, no GPL dependencies, written from the public DjVu v3
16
+ specification.
13
17
 
14
18
  | Your task | How |
15
19
  |-----------|-----|
@@ -17,7 +21,7 @@ from the public DjVu v3 specification.
17
21
  | Extract text (plain, hOCR, ALTO XML) | [`djvu text`](#cli) or [`page.text()`](#text-extraction), [`to_hocr` / `to_alto`](#hocr-and-alto-xml-export) |
18
22
  | Render pages to RGBA pixels | [`render_pixmap`](#quick-start) — sync, [async](#async-render), or [parallel](#feature-flags) |
19
23
  | Show DjVu in the browser | [WebAssembly bindings](#webassembly), incl. lazy HTTP-Range loading |
20
- | Read DjVu from Python | [PyO3 bindings, built from source](#python) |
24
+ | Read DjVu from Python | `pip install djvu-rs` — [PyO3 bindings](#python) |
21
25
  | Create DjVu from images (PNG/JPEG/TIFF) | [`djvu encode`](#cli) or [`PageEncoder`](#encoding--low-level-api) |
22
26
  | Add an OCR text layer to a scan | [`djvu ocr`](#ocr-recognition-backends) (Tesseract) |
23
27
  | Merge, split, edit documents | [`djvu merge` / `djvu split`](#cli), `DocumentEditor`, `DjVuDocumentMut` |
@@ -155,6 +159,12 @@ djvu encode scan.png --quality quality --binarization sauvola --bg-inpaint --out
155
159
  # Cap the IW44 background at a bits-per-pixel budget (smaller file, lower quality)
156
160
  djvu encode scan.jpg --quality quality --bg-bpp 0.8 --output scan.djvu
157
161
 
162
+ # Composite transparent PNG/TIFF pixels onto a solid colour (hex or white/black)
163
+ djvu encode logo.png --background white --output logo.djvu
164
+
165
+ # Refuse ICC-profiled input instead of silently dropping the profile
166
+ djvu encode scan.png --icc reject --output scan.djvu
167
+
158
168
  # Encode a directory of images into a bundled DJVM with shared Djbz
159
169
  djvu encode pages/ --output book.djvu --shared-dict-pages 2
160
170
 
@@ -666,8 +676,9 @@ Honest boundaries, so you can decide fast:
666
676
 
667
677
  - **Library + CLI, not a viewer.** There is no GUI; the WASM demo is the
668
678
  closest thing to one.
669
- - **Python bindings are source-only for now.** The `djvu-py` package is not
670
- published to PyPI yet install it from the repository checkout.
679
+ - **Python bindings cover the reading surface only.** Open, render, and text
680
+ extraction ship in the PyPI wheels; encode, mutation, and PDF/EPUB/TIFF
681
+ export stay on the Rust crate / CLI for now.
671
682
  - **Indirect DJVM mutation is indirect-only via two paths.**
672
683
  `DjVuDocumentMut::from_bytes` + `page_mut` on an indirect index errors;
673
684
  use `from_indirect_resolved` (rebundles) or `IndirectRewritePlan` (rewrites
@@ -797,7 +808,9 @@ MIT. See [LICENSE](LICENSE).
797
808
 
798
809
  Written from the public DjVu v3 specification:
799
810
  - https://www.sndjvu.org/spec.html
800
- - https://djvu.sourceforge.net/spec/DjVu3Spec.djvu (the spec is itself a DjVu file)
811
+ - https://web.archive.org/web/20251005122807/http://www.djvu.org/docs/DjVu3Spec.djvu
812
+ (the spec is itself a DjVu file; archived copy — djvu.org and
813
+ djvu.sourceforge.net no longer serve the original)
801
814
 
802
815
  No code derived from GPL-licensed DjVuLibre or any other GPL source.
803
816
  All algorithms are independent implementations from the spec.
Binary file
package/simd128/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  # djvu-rs
2
2
 
3
3
  [![Crates.io](https://badgen.net/crates/v/djvu-rs)](https://crates.io/crates/djvu-rs)
4
+ [![PyPI](https://img.shields.io/pypi/v/djvu-rs)](https://pypi.org/project/djvu-rs/)
5
+ [![npm](https://img.shields.io/npm/v/djvu-rs)](https://www.npmjs.com/package/djvu-rs)
4
6
  [![docs.rs](https://docs.rs/djvu-rs/badge.svg)](https://docs.rs/djvu-rs)
5
7
  [![CI](https://github.com/matyushkin/djvu-rs/actions/workflows/ci.yml/badge.svg)](https://github.com/matyushkin/djvu-rs/actions/workflows/ci.yml)
6
8
  [![Benchmarks](https://img.shields.io/badge/benchmarks-dashboard-blue)](https://matyushkin.github.io/djvu-rs/dev/bench/)
@@ -8,8 +10,10 @@
8
10
  [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
9
11
 
10
12
  Read, render, convert, and create DjVu files. Pure-Rust library with a CLI,
11
- WebAssembly, and Python bindings — MIT licensed, no GPL dependencies, written
12
- from the public DjVu v3 specification.
13
+ WebAssembly, and Python bindings — on [crates.io](https://crates.io/crates/djvu-rs),
14
+ [PyPI](https://pypi.org/project/djvu-rs/), and [npm](https://www.npmjs.com/package/djvu-rs)
15
+ as `djvu-rs`. MIT licensed, no GPL dependencies, written from the public DjVu v3
16
+ specification.
13
17
 
14
18
  | Your task | How |
15
19
  |-----------|-----|
@@ -17,7 +21,7 @@ from the public DjVu v3 specification.
17
21
  | Extract text (plain, hOCR, ALTO XML) | [`djvu text`](#cli) or [`page.text()`](#text-extraction), [`to_hocr` / `to_alto`](#hocr-and-alto-xml-export) |
18
22
  | Render pages to RGBA pixels | [`render_pixmap`](#quick-start) — sync, [async](#async-render), or [parallel](#feature-flags) |
19
23
  | Show DjVu in the browser | [WebAssembly bindings](#webassembly), incl. lazy HTTP-Range loading |
20
- | Read DjVu from Python | [PyO3 bindings, built from source](#python) |
24
+ | Read DjVu from Python | `pip install djvu-rs` — [PyO3 bindings](#python) |
21
25
  | Create DjVu from images (PNG/JPEG/TIFF) | [`djvu encode`](#cli) or [`PageEncoder`](#encoding--low-level-api) |
22
26
  | Add an OCR text layer to a scan | [`djvu ocr`](#ocr-recognition-backends) (Tesseract) |
23
27
  | Merge, split, edit documents | [`djvu merge` / `djvu split`](#cli), `DocumentEditor`, `DjVuDocumentMut` |
@@ -155,6 +159,12 @@ djvu encode scan.png --quality quality --binarization sauvola --bg-inpaint --out
155
159
  # Cap the IW44 background at a bits-per-pixel budget (smaller file, lower quality)
156
160
  djvu encode scan.jpg --quality quality --bg-bpp 0.8 --output scan.djvu
157
161
 
162
+ # Composite transparent PNG/TIFF pixels onto a solid colour (hex or white/black)
163
+ djvu encode logo.png --background white --output logo.djvu
164
+
165
+ # Refuse ICC-profiled input instead of silently dropping the profile
166
+ djvu encode scan.png --icc reject --output scan.djvu
167
+
158
168
  # Encode a directory of images into a bundled DJVM with shared Djbz
159
169
  djvu encode pages/ --output book.djvu --shared-dict-pages 2
160
170
 
@@ -666,8 +676,9 @@ Honest boundaries, so you can decide fast:
666
676
 
667
677
  - **Library + CLI, not a viewer.** There is no GUI; the WASM demo is the
668
678
  closest thing to one.
669
- - **Python bindings are source-only for now.** The `djvu-py` package is not
670
- published to PyPI yet install it from the repository checkout.
679
+ - **Python bindings cover the reading surface only.** Open, render, and text
680
+ extraction ship in the PyPI wheels; encode, mutation, and PDF/EPUB/TIFF
681
+ export stay on the Rust crate / CLI for now.
671
682
  - **Indirect DJVM mutation is indirect-only via two paths.**
672
683
  `DjVuDocumentMut::from_bytes` + `page_mut` on an indirect index errors;
673
684
  use `from_indirect_resolved` (rebundles) or `IndirectRewritePlan` (rewrites
@@ -797,7 +808,9 @@ MIT. See [LICENSE](LICENSE).
797
808
 
798
809
  Written from the public DjVu v3 specification:
799
810
  - https://www.sndjvu.org/spec.html
800
- - https://djvu.sourceforge.net/spec/DjVu3Spec.djvu (the spec is itself a DjVu file)
811
+ - https://web.archive.org/web/20251005122807/http://www.djvu.org/docs/DjVu3Spec.djvu
812
+ (the spec is itself a DjVu file; archived copy — djvu.org and
813
+ djvu.sourceforge.net no longer serve the original)
801
814
 
802
815
  No code derived from GPL-licensed DjVuLibre or any other GPL source.
803
816
  All algorithms are independent implementations from the spec.
Binary file