diff options
author | Jeff Vander Stoep <jeffv@google.com> | 2024-02-05 09:38:17 +0100 |
---|---|---|
committer | Jeff Vander Stoep <jeffv@google.com> | 2024-02-05 09:38:18 +0100 |
commit | 0c14e3f5b575d149a082fb7923d698364c998006 (patch) | |
tree | 8c89bf77d2750b00466b529246e42ce880404c5e | |
parent | bfa5b4f8a812c0b6e429ef07173a2f96dbd68971 (diff) | |
download | plotters-backend-0c14e3f5b575d149a082fb7923d698364c998006.tar.gz |
Upgrade plotters-backend to 0.3.5
This project was upgraded with external_updater.
Usage: tools/external_updater/updater.sh update external/rust/crates/plotters-backend
For more info, check https://cs.android.com/android/platform/superproject/+/main:tools/external_updater/README.md
Test: TreeHugger
Change-Id: I27a03fb4ba1f480f6e3134b3024f38bcb6172fad
-rw-r--r-- | .cargo_vcs_info.json | 2 | ||||
-rw-r--r-- | Android.bp | 2 | ||||
-rw-r--r-- | Cargo.toml | 2 | ||||
-rw-r--r-- | Cargo.toml.orig | 2 | ||||
-rw-r--r-- | LICENSE | 22 | ||||
-rw-r--r-- | METADATA | 25 | ||||
-rw-r--r-- | README.md | 2 | ||||
-rw-r--r-- | src/rasterizer/mod.rs | 2 | ||||
-rw-r--r-- | src/rasterizer/path.rs | 4 |
9 files changed, 20 insertions, 43 deletions
diff --git a/.cargo_vcs_info.json b/.cargo_vcs_info.json index 08b1a92..4b494bf 100644 --- a/.cargo_vcs_info.json +++ b/.cargo_vcs_info.json @@ -1,6 +1,6 @@ { "git": { - "sha1": "6bd30045e545e7308b1349c6ffaaa22a4c6eeb94" + "sha1": "73663bf8f9a5151c02e28bfbdab3e240bb8c1811" }, "path_in_vcs": "plotters-backend" }
\ No newline at end of file @@ -25,7 +25,7 @@ rust_library { host_supported: true, crate_name: "plotters_backend", cargo_env_compat: true, - cargo_pkg_version: "0.3.4", + cargo_pkg_version: "0.3.5", srcs: ["src/lib.rs"], edition: "2018", apex_available: [ @@ -12,7 +12,7 @@ [package] edition = "2018" name = "plotters-backend" -version = "0.3.4" +version = "0.3.5" authors = ["Hao Hou <haohou302@gmail.com>"] description = "Plotters Backend API" homepage = "https://plotters-rs.github.io" diff --git a/Cargo.toml.orig b/Cargo.toml.orig index 9a2ba85..c3aa8cb 100644 --- a/Cargo.toml.orig +++ b/Cargo.toml.orig @@ -1,6 +1,6 @@ [package] name = "plotters-backend" -version = "0.3.4" +version = "0.3.5" authors = ["Hao Hou <haohou302@gmail.com>"] edition = "2018" license = "MIT" @@ -1,21 +1 @@ -MIT License - -Copyright (c) 2019 Hao Hou <haohou302@gmail.com> - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +../LICENSE
\ No newline at end of file @@ -1,23 +1,20 @@ # This project was upgraded with external_updater. -# Usage: tools/external_updater/updater.sh update rust/crates/plotters-backend -# For more info, check https://cs.android.com/android/platform/superproject/+/master:tools/external_updater/README.md +# Usage: tools/external_updater/updater.sh update external/rust/crates/plotters-backend +# For more info, check https://cs.android.com/android/platform/superproject/+/main:tools/external_updater/README.md name: "plotters-backend" description: "Plotters Backend API" third_party { - url { - type: HOMEPAGE - value: "https://crates.io/crates/plotters-backend" - } - url { - type: ARCHIVE - value: "https://static.crates.io/crates/plotters-backend/plotters-backend-0.3.4.crate" - } - version: "0.3.4" license_type: NOTICE last_upgrade_date { - year: 2022 - month: 12 - day: 13 + year: 2024 + month: 2 + day: 5 + } + homepage: "https://crates.io/crates/plotters-backend" + identifier { + type: "Archive" + value: "https://static.crates.io/crates/plotters-backend/plotters-backend-0.3.5.crate" + version: "0.3.5" } } @@ -3,6 +3,6 @@ This is a part of plotters project. For more details, please check the following links: - For high-level intro of Plotters, see: [Plotters on crates.io](https://crates.io/crates/plotters) -- Check the main repo at [Plotters repo](https://github.com/38/plotters.git) +- Check the main repo at [Plotters repo](https://github.com/plotters-rs/plotters.git) - For detailed documentation about this crate, check [plotters-backend on docs.rs](https://docs.rs/plotters-backend/) - You can also visit Plotters [Homepage](https://plotters-rs.github.io) diff --git a/src/rasterizer/mod.rs b/src/rasterizer/mod.rs index d322391..b475acd 100644 --- a/src/rasterizer/mod.rs +++ b/src/rasterizer/mod.rs @@ -10,7 +10,7 @@ // the question mark operator has a huge performance impact due to LLVM unable to handle it. // So the question is if this trick is still useful, or LLVM is smart enough to handle it since // then. -// +// // -- // Original comment: // diff --git a/src/rasterizer/path.rs b/src/rasterizer/path.rs index 35ae604..eae0bfe 100644 --- a/src/rasterizer/path.rs +++ b/src/rasterizer/path.rs @@ -34,8 +34,8 @@ fn compute_polygon_vertex(triple: &[BackendCoord; 3], d: f64, buf: &mut Vec<Back f64::from(triple[1].1) + d * b_n.1, ); - // If they are actually the same point, then the 3 points are colinear, so just emit the point. - if a_p.0 as i32 == b_p.0 as i32 && a_p.1 as i32 == b_p.1 as i32 { + // Check if 3 points are colinear. If so, just emit the point. + if a_t.1 * b_t.0 == a_t.0 * b_t.1 { buf.push((a_p.0 as i32, a_p.1 as i32)); return; } |