Skip to content

Use default generic float set to Scalar #968

@bvssvni

Description

@bvssvni

Instead of setting the float type to Scalar explicitly, we might be able to use a default generic and lets you use the library with f32.

  • math::Matrix2d => math::Matrix2d<T=Scalar>
  • math::Vec2d => math::Vec2d<T=Scalar>
  • math::Vec3d => math::Vec3d<T=Scalar>
  • math::perp => math::perp<T=Scalar> where T: Float
  • math::abs_transform => math::abs_transform<T=Scalar> whereT: Float`
  • math::translate => math::translate<T=Scalar> where T: Float
  • math::rotate_radians => math::rotate_radians<T=Scalar> where T: Float
  • math::orient => math::orient<T=Scalar> where T: Float
  • math::scale => math::scale<T=Scalar> where T: Float
  • math::shear => math::shear<T=Scalar> where T: Float
  • math::identity => math::identity<T=Scalar> where T: Float
  • math::get_scale => math::get_scale<T=Scalar> where T: Float
  • math::separation => math::separation<T=Scalar> where T: Float
  • math::least_separation_4 => math::least_separation_4<T=Scalar> where T: Float
  • math::margin_rectangle => math::margin_rectangle<T=Scalar> where T: Float
  • math::relative_rectangle => math::relative_rectangle<T=Scalar> where T: Float
  • math::overlap_rectangle => math::overlap_rectangle<T=Scalar> where T: Float
  • math::area_centroid => math::area_centroid<T=Scalar> where T: Float
  • math::area => math::area<T=Scalar> where T: Float
  • math::centroid => math::centroid<T=Scalar> where T: Float
  • math::line_side => math::line_side<T=Scalar> where T: Float
  • math::inside_triangle => math::inside_triangle<T=Scalar> where T: Float
  • math::triangle_face => math::triangle_face<T=Scalar> where T: Float
  • math::to_barycentric => math::to_barycentric<T=Scalar> where T: Float
  • math::from_barycentric => math::from_barycentric<T=Scalar> where T: Float
  • types::Ray => types::Ray<T=Scalar>
  • types::Rectangle => types::Rectangle<T=Scalar>
  • types::Line => types::Line<T=Scalar>
  • types::Polygon<'a> => types::Polygon<'a, T=Scalar>
  • types::Polygons<'a> => types::Polygons<'a, T=Scalar>
  • types::Radius => types::Radius<T=Scalar>
  • types::Triangle => types::Triangle<T=Scalar>
  • types::Width => types::Width<T=Scalar>

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions