|
3 | 3 |  |
4 | 4 |
|
5 | 5 | [](https://github.com/webarkit/WebARKitLib-rs/actions/workflows/ci.yml) |
| 6 | +[](https://codecov.io/gh/webarkit/WebARKitLib-rs) |
6 | 7 | [](https://crates.io/crates/webarkitlib-rs) |
7 | 8 | [](https://www.npmjs.com/package/@webarkit/webarkitlib-wasm) |
8 | 9 | [](https://github.com/webarkit/WebARKitLib-rs/stargazers) |
@@ -38,14 +39,14 @@ Add `webarkitlib-rs` to your `Cargo.toml`: |
38 | 39 |
|
39 | 40 | ```toml |
40 | 41 | [dependencies] |
41 | | -webarkitlib-rs = "0.5" |
| 42 | +webarkitlib-rs = "0.6" |
42 | 43 | ``` |
43 | 44 |
|
44 | 45 | To enable the C++ FFI backend for KPM (Natural Feature Tracking): |
45 | 46 |
|
46 | 47 | ```toml |
47 | 48 | [dependencies] |
48 | | -webarkitlib-rs = { version = "0.5", features = ["ffi-backend"] } |
| 49 | +webarkitlib-rs = { version = "0.6", features = ["ffi-backend"] } |
49 | 50 | ``` |
50 | 51 |
|
51 | 52 | > When installing from crates.io, no extra setup is required — the C++ |
@@ -204,7 +205,7 @@ Enable the `log-helpers` feature and call the bundled initializer once in your b |
204 | 205 |
|
205 | 206 | ```toml |
206 | 207 | [dependencies] |
207 | | -webarkitlib-rs = { version = "0.5", features = ["log-helpers"] } |
| 208 | +webarkitlib-rs = { version = "0.6", features = ["log-helpers"] } |
208 | 209 | ``` |
209 | 210 |
|
210 | 211 | ```rust |
@@ -263,6 +264,36 @@ Because it's the `log` crate facade, any compatible backend works: |
263 | 264 |
|
264 | 265 | No library code change is needed — pick the backend in your application's entry point. |
265 | 266 |
|
| 267 | +## 📈 Code Coverage |
| 268 | + |
| 269 | +Coverage reports are generated automatically on every push and pull request via the [coverage workflow](.github/workflows/coverage.yml) using [cargo-tarpaulin](https://github.com/xd009642/tarpaulin) and uploaded to [Codecov](https://codecov.io/gh/webarkit/WebARKitLib-rs). |
| 270 | + |
| 271 | +### Generate a Coverage Report Locally |
| 272 | + |
| 273 | +```bash |
| 274 | +# Install tarpaulin (once) |
| 275 | +cargo install cargo-tarpaulin |
| 276 | + |
| 277 | +# Run the helper script — produces coverage/index.html |
| 278 | +./scripts/coverage.sh |
| 279 | +``` |
| 280 | + |
| 281 | +Or run tarpaulin directly: |
| 282 | + |
| 283 | +```bash |
| 284 | +cargo tarpaulin --workspace --out Html --output-dir coverage --timeout 300 |
| 285 | +``` |
| 286 | + |
| 287 | +### Coverage Targets |
| 288 | + |
| 289 | +| Area | Target | |
| 290 | +|------|--------| |
| 291 | +| Minimum overall | 75 % | |
| 292 | +| Desirable overall | 85 %+ | |
| 293 | +| Marker tracking (critical path) | 95 %+ | |
| 294 | + |
| 295 | +--- |
| 296 | + |
266 | 297 | ## 📊 Benchmarking |
267 | 298 |
|
268 | 299 | We maintain a strict performance comparison with the original C library to ensure our Rust port remains competitive. |
|
0 commit comments