Skip to content

Commit

Permalink
Add low level LrmScale implementation
Browse files Browse the repository at this point in the history
Closes #3
  • Loading branch information
Tristramg committed Apr 5, 2024
1 parent 6d96c8d commit be62df9
Show file tree
Hide file tree
Showing 4 changed files with 398 additions and 2 deletions.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,10 @@ The schema is described in [schema/lrs.fbs](schema/lrs.fbs). The library is writ

If your contribution changes the schema, you will need to generate the file with flatc. The version must be the release 23.5.26. Do not use a version built from master.

`flatc -o src --rust schema/lrs.fbs`
`flatc -o src --rust schema/lrs.fbs`

## Norms

### Comment convention

See [How to write documentation in Rust](https://doc.rust-lang.org/rustdoc/how-to-write-documentation.html) to keep the code clean and clear (also [this](https://github.com/rust-lang/rfcs/blob/master/text/1574-more-api-documentation-conventions.md#appendix-a-full-conventions-text) for other examples).
2 changes: 1 addition & 1 deletion src/curves.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use thiserror::Error;
/// It provides basic primitives to locate/project points on it
/// A curve can be part of a larger curve (e.g. for optimisation purpurses and have better bounding boxes)
/// The curve can be implemented
trait Curve {
pub trait Curve {
/// Project the point to the closest position on the curve
/// Will fail if the curve is invalid (e.g. no points on it)
/// or if the point is to far away
Expand Down
2 changes: 2 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ mod lrs_generated;

#[deny(missing_docs)]
pub mod curves;
#[deny(missing_docs)]
pub mod lrm_scale;
pub use lrs_generated::*;

#[test]
Expand Down
Loading

0 comments on commit be62df9

Please sign in to comment.