Add bytemuck impls to points.
This commit is contained in:
parent
0b1e6f0b05
commit
af448d2c70
|
@ -65,6 +65,24 @@ where
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[cfg(feature = "bytemuck")]
|
||||||
|
unsafe impl<N: Scalar, D: DimName> bytemuck::Zeroable for Point<N, D>
|
||||||
|
where
|
||||||
|
VectorN<N, D>: bytemuck::Zeroable,
|
||||||
|
DefaultAllocator: Allocator<N, D>,
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(feature = "bytemuck")]
|
||||||
|
unsafe impl<N: Scalar, D: DimName> bytemuck::Pod for Point<N, D>
|
||||||
|
where
|
||||||
|
N: Copy,
|
||||||
|
VectorN<N, D>: bytemuck::Pod,
|
||||||
|
DefaultAllocator: Allocator<N, D>,
|
||||||
|
<DefaultAllocator as Allocator<N, D>>::Buffer: Copy,
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
#[cfg(feature = "serde-serialize")]
|
#[cfg(feature = "serde-serialize")]
|
||||||
impl<N: Scalar, D: DimName> Serialize for Point<N, D>
|
impl<N: Scalar, D: DimName> Serialize for Point<N, D>
|
||||||
where
|
where
|
||||||
|
|
Loading…
Reference in New Issue