# [−][src]Struct nalgebra_glm::DefaultAllocator

An allocator based on `GenericArray`

and `MatrixVec`

for statically-sized and dynamically-sized
matrices respectively.

## Trait Implementations

`impl<N, R, C> Allocator<N, R, C> for DefaultAllocator where`

C: DimName,

N: Scalar,

R: DimName,

<R as DimName>::Value: Mul<<C as DimName>::Value>,

<<R as DimName>::Value as Mul<<C as DimName>::Value>>::Output: ArrayLength<N>,

[src]

`impl<N, R, C> Allocator<N, R, C> for DefaultAllocator where`

C: DimName,

N: Scalar,

R: DimName,

<R as DimName>::Value: Mul<<C as DimName>::Value>,

<<R as DimName>::Value as Mul<<C as DimName>::Value>>::Output: ArrayLength<N>,

`type Buffer = MatrixArray<N, R, C>`

The type of buffer this allocator can instanciate.

`unsafe fn allocate_uninitialized(`

R,

C

) -> <DefaultAllocator as Allocator<N, R, C>>::Buffer

[src]

`unsafe fn allocate_uninitialized(`

R,

C

) -> <DefaultAllocator as Allocator<N, R, C>>::Buffer

Allocates a buffer with the given number of rows and columns without initializing its content.

`fn allocate_from_iterator<I>(`

nrows: R,

ncols: C,

iter: I

) -> <DefaultAllocator as Allocator<N, R, C>>::Buffer where

I: IntoIterator<Item = N>,

[src]

`fn allocate_from_iterator<I>(`

nrows: R,

ncols: C,

iter: I

) -> <DefaultAllocator as Allocator<N, R, C>>::Buffer where

I: IntoIterator<Item = N>,

Allocates a buffer initialized with the content of the given iterator.

`impl<N, R> Allocator<N, R, Dynamic> for DefaultAllocator where`

N: Scalar,

R: DimName,

[src]

`impl<N, R> Allocator<N, R, Dynamic> for DefaultAllocator where`

N: Scalar,

R: DimName,

`type Buffer = MatrixVec<N, R, Dynamic>`

The type of buffer this allocator can instanciate.

`unsafe fn allocate_uninitialized(`

nrows: R,

ncols: Dynamic

) -> <DefaultAllocator as Allocator<N, R, Dynamic>>::Buffer

[src]

`unsafe fn allocate_uninitialized(`

nrows: R,

ncols: Dynamic

) -> <DefaultAllocator as Allocator<N, R, Dynamic>>::Buffer

Allocates a buffer with the given number of rows and columns without initializing its content.

`fn allocate_from_iterator<I>(`

nrows: R,

ncols: Dynamic,

iter: I

) -> <DefaultAllocator as Allocator<N, R, Dynamic>>::Buffer where

I: IntoIterator<Item = N>,

[src]

`fn allocate_from_iterator<I>(`

nrows: R,

ncols: Dynamic,

iter: I

) -> <DefaultAllocator as Allocator<N, R, Dynamic>>::Buffer where

I: IntoIterator<Item = N>,

Allocates a buffer initialized with the content of the given iterator.

`impl<N, C> Allocator<N, Dynamic, C> for DefaultAllocator where`

C: Dim,

N: Scalar,

[src]

`impl<N, C> Allocator<N, Dynamic, C> for DefaultAllocator where`

C: Dim,

N: Scalar,

`type Buffer = MatrixVec<N, Dynamic, C>`

The type of buffer this allocator can instanciate.

`unsafe fn allocate_uninitialized(`

nrows: Dynamic,

ncols: C

) -> <DefaultAllocator as Allocator<N, Dynamic, C>>::Buffer

[src]

`unsafe fn allocate_uninitialized(`

nrows: Dynamic,

ncols: C

) -> <DefaultAllocator as Allocator<N, Dynamic, C>>::Buffer

Allocates a buffer with the given number of rows and columns without initializing its content.

`fn allocate_from_iterator<I>(`

nrows: Dynamic,

ncols: C,

iter: I

) -> <DefaultAllocator as Allocator<N, Dynamic, C>>::Buffer where

I: IntoIterator<Item = N>,

[src]

`fn allocate_from_iterator<I>(`

nrows: Dynamic,

ncols: C,

iter: I

) -> <DefaultAllocator as Allocator<N, Dynamic, C>>::Buffer where

I: IntoIterator<Item = N>,

Allocates a buffer initialized with the content of the given iterator.

`impl<N, R1, R2> SameShapeVectorAllocator<N, R1, R2> for DefaultAllocator where`

N: Scalar,

R1: Dim,

R2: Dim,

DefaultAllocator: Allocator<N, R1, U1>,

DefaultAllocator: Allocator<N, <ShapeConstraint as SameNumberOfRows<R1, R2>>::Representative, U1>,

ShapeConstraint: SameNumberOfRows<R1, R2>,

[src]

`impl<N, R1, R2> SameShapeVectorAllocator<N, R1, R2> for DefaultAllocator where`

N: Scalar,

R1: Dim,

R2: Dim,

DefaultAllocator: Allocator<N, R1, U1>,

DefaultAllocator: Allocator<N, <ShapeConstraint as SameNumberOfRows<R1, R2>>::Representative, U1>,

ShapeConstraint: SameNumberOfRows<R1, R2>,

`impl<N, RFrom, CFrom, RTo, CTo> Reallocator<N, RFrom, CFrom, RTo, CTo> for DefaultAllocator where`

CFrom: Dim,

CTo: DimName,

N: Scalar,

RFrom: Dim,

RTo: DimName,

DefaultAllocator: Allocator<N, RFrom, CFrom>,

<RTo as DimName>::Value: Mul<<CTo as DimName>::Value>,

<<RTo as DimName>::Value as Mul<<CTo as DimName>::Value>>::Output: ArrayLength<N>,

[src]

`impl<N, RFrom, CFrom, RTo, CTo> Reallocator<N, RFrom, CFrom, RTo, CTo> for DefaultAllocator where`

CFrom: Dim,

CTo: DimName,

N: Scalar,

RFrom: Dim,

RTo: DimName,

DefaultAllocator: Allocator<N, RFrom, CFrom>,

<RTo as DimName>::Value: Mul<<CTo as DimName>::Value>,

<<RTo as DimName>::Value as Mul<<CTo as DimName>::Value>>::Output: ArrayLength<N>,

`unsafe fn reallocate_copy(`

rto: RTo,

cto: CTo,

buf: <DefaultAllocator as Allocator<N, RFrom, CFrom>>::Buffer

) -> MatrixArray<N, RTo, CTo>

[src]

`unsafe fn reallocate_copy(`

rto: RTo,

cto: CTo,

buf: <DefaultAllocator as Allocator<N, RFrom, CFrom>>::Buffer

) -> MatrixArray<N, RTo, CTo>

Reallocates a buffer of shape `(RTo, CTo)`

, possibly reusing a previously allocated buffer `buf`

. Data stored by `buf`

are linearly copied to the output: Read more

`impl<N, RFrom, CFrom, RTo> Reallocator<N, RFrom, CFrom, RTo, Dynamic> for DefaultAllocator where`

CFrom: DimName,

N: Scalar,

RFrom: DimName,

RTo: DimName,

<RFrom as DimName>::Value: Mul<<CFrom as DimName>::Value>,

<<RFrom as DimName>::Value as Mul<<CFrom as DimName>::Value>>::Output: ArrayLength<N>,

[src]

`impl<N, RFrom, CFrom, RTo> Reallocator<N, RFrom, CFrom, RTo, Dynamic> for DefaultAllocator where`

CFrom: DimName,

N: Scalar,

RFrom: DimName,

RTo: DimName,

<RFrom as DimName>::Value: Mul<<CFrom as DimName>::Value>,

<<RFrom as DimName>::Value as Mul<<CFrom as DimName>::Value>>::Output: ArrayLength<N>,

`unsafe fn reallocate_copy(`

rto: RTo,

cto: Dynamic,

buf: MatrixArray<N, RFrom, CFrom>

) -> MatrixVec<N, RTo, Dynamic>

[src]

`unsafe fn reallocate_copy(`

rto: RTo,

cto: Dynamic,

buf: MatrixArray<N, RFrom, CFrom>

) -> MatrixVec<N, RTo, Dynamic>

Reallocates a buffer of shape `(RTo, CTo)`

, possibly reusing a previously allocated buffer `buf`

. Data stored by `buf`

are linearly copied to the output: Read more

`impl<N, RFrom, CFrom, CTo> Reallocator<N, RFrom, CFrom, Dynamic, CTo> for DefaultAllocator where`

CFrom: DimName,

CTo: Dim,

N: Scalar,

RFrom: DimName,

<RFrom as DimName>::Value: Mul<<CFrom as DimName>::Value>,

<<RFrom as DimName>::Value as Mul<<CFrom as DimName>::Value>>::Output: ArrayLength<N>,

[src]

`impl<N, RFrom, CFrom, CTo> Reallocator<N, RFrom, CFrom, Dynamic, CTo> for DefaultAllocator where`

CFrom: DimName,

CTo: Dim,

N: Scalar,

RFrom: DimName,

<RFrom as DimName>::Value: Mul<<CFrom as DimName>::Value>,

<<RFrom as DimName>::Value as Mul<<CFrom as DimName>::Value>>::Output: ArrayLength<N>,

`unsafe fn reallocate_copy(`

rto: Dynamic,

cto: CTo,

buf: MatrixArray<N, RFrom, CFrom>

) -> MatrixVec<N, Dynamic, CTo>

[src]

`unsafe fn reallocate_copy(`

rto: Dynamic,

cto: CTo,

buf: MatrixArray<N, RFrom, CFrom>

) -> MatrixVec<N, Dynamic, CTo>

Reallocates a buffer of shape `(RTo, CTo)`

, possibly reusing a previously allocated buffer `buf`

. Data stored by `buf`

are linearly copied to the output: Read more

`impl<N, CFrom, CTo> Reallocator<N, Dynamic, CFrom, Dynamic, CTo> for DefaultAllocator where`

CFrom: Dim,

CTo: Dim,

N: Scalar,

[src]

`impl<N, CFrom, CTo> Reallocator<N, Dynamic, CFrom, Dynamic, CTo> for DefaultAllocator where`

CFrom: Dim,

CTo: Dim,

N: Scalar,

`unsafe fn reallocate_copy(`

rto: Dynamic,

cto: CTo,

buf: MatrixVec<N, Dynamic, CFrom>

) -> MatrixVec<N, Dynamic, CTo>

[src]

`unsafe fn reallocate_copy(`

rto: Dynamic,

cto: CTo,

buf: MatrixVec<N, Dynamic, CFrom>

) -> MatrixVec<N, Dynamic, CTo>

`(RTo, CTo)`

, possibly reusing a previously allocated buffer `buf`

. Data stored by `buf`

are linearly copied to the output: Read more

`impl<N, RFrom, CTo> Reallocator<N, RFrom, Dynamic, Dynamic, CTo> for DefaultAllocator where`

CTo: Dim,

N: Scalar,

RFrom: DimName,

[src]

`impl<N, RFrom, CTo> Reallocator<N, RFrom, Dynamic, Dynamic, CTo> for DefaultAllocator where`

CTo: Dim,

N: Scalar,

RFrom: DimName,

`unsafe fn reallocate_copy(`

rto: Dynamic,

cto: CTo,

buf: MatrixVec<N, RFrom, Dynamic>

) -> MatrixVec<N, Dynamic, CTo>

[src]

`unsafe fn reallocate_copy(`

rto: Dynamic,

cto: CTo,

buf: MatrixVec<N, RFrom, Dynamic>

) -> MatrixVec<N, Dynamic, CTo>

`(RTo, CTo)`

, possibly reusing a previously allocated buffer `buf`

. Data stored by `buf`

are linearly copied to the output: Read more

`impl<N, RFrom, RTo> Reallocator<N, RFrom, Dynamic, RTo, Dynamic> for DefaultAllocator where`

N: Scalar,

RFrom: DimName,

RTo: DimName,

[src]

`impl<N, RFrom, RTo> Reallocator<N, RFrom, Dynamic, RTo, Dynamic> for DefaultAllocator where`

N: Scalar,

RFrom: DimName,

RTo: DimName,

`unsafe fn reallocate_copy(`

rto: RTo,

cto: Dynamic,

buf: MatrixVec<N, RFrom, Dynamic>

) -> MatrixVec<N, RTo, Dynamic>

[src]

`unsafe fn reallocate_copy(`

rto: RTo,

cto: Dynamic,

buf: MatrixVec<N, RFrom, Dynamic>

) -> MatrixVec<N, RTo, Dynamic>

`(RTo, CTo)`

, possibly reusing a previously allocated buffer `buf`

. Data stored by `buf`

are linearly copied to the output: Read more

`impl<N, CFrom, RTo> Reallocator<N, Dynamic, CFrom, RTo, Dynamic> for DefaultAllocator where`

CFrom: Dim,

N: Scalar,

RTo: DimName,

[src]

`impl<N, CFrom, RTo> Reallocator<N, Dynamic, CFrom, RTo, Dynamic> for DefaultAllocator where`

CFrom: Dim,

N: Scalar,

RTo: DimName,

`unsafe fn reallocate_copy(`

rto: RTo,

cto: Dynamic,

buf: MatrixVec<N, Dynamic, CFrom>

) -> MatrixVec<N, RTo, Dynamic>

[src]

`unsafe fn reallocate_copy(`

rto: RTo,

cto: Dynamic,

buf: MatrixVec<N, Dynamic, CFrom>

) -> MatrixVec<N, RTo, Dynamic>

`(RTo, CTo)`

, possibly reusing a previously allocated buffer `buf`

. Data stored by `buf`

are linearly copied to the output: Read more

`impl<N, R1, R2, C1, C2> SameShapeAllocator<N, R1, C1, R2, C2> for DefaultAllocator where`

C1: Dim,

C2: Dim,

N: Scalar,

R1: Dim,

R2: Dim,

DefaultAllocator: Allocator<N, R1, C1>,

DefaultAllocator: Allocator<N, <ShapeConstraint as SameNumberOfRows<R1, R2>>::Representative, <ShapeConstraint as SameNumberOfColumns<C1, C2>>::Representative>,

ShapeConstraint: SameNumberOfRows<R1, R2>,

ShapeConstraint: SameNumberOfColumns<C1, C2>,

[src]

`impl<N, R1, R2, C1, C2> SameShapeAllocator<N, R1, C1, R2, C2> for DefaultAllocator where`

C1: Dim,

C2: Dim,

N: Scalar,

R1: Dim,

R2: Dim,

DefaultAllocator: Allocator<N, R1, C1>,

DefaultAllocator: Allocator<N, <ShapeConstraint as SameNumberOfRows<R1, R2>>::Representative, <ShapeConstraint as SameNumberOfColumns<C1, C2>>::Representative>,

ShapeConstraint: SameNumberOfRows<R1, R2>,

ShapeConstraint: SameNumberOfColumns<C1, C2>,

## Auto Trait Implementations

`impl Send for DefaultAllocator`

`impl Send for DefaultAllocator`

`impl Sync for DefaultAllocator`

`impl Sync for DefaultAllocator`

## Blanket Implementations

`impl<T> From for T`

[src]

`impl<T> From for T`

`impl<T, U> Into for T where`

U: From<T>,

[src]

`impl<T, U> Into for T where`

U: From<T>,

`impl<T, U> TryFrom for T where`

T: From<U>,

[src]

`impl<T, U> TryFrom for T where`

T: From<U>,

`type Error = !`

`try_from`

)The type returned in the event of a conversion error.

`fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>`

[src]

`fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>`

`try_from`

)Performs the conversion.

`impl<T> Borrow for T where`

T: ?Sized,

[src]

`impl<T> Borrow for T where`

T: ?Sized,

`impl<T> Any for T where`

T: 'static + ?Sized,

[src]

`impl<T> Any for T where`

T: 'static + ?Sized,

`fn get_type_id(&self) -> TypeId`

[src]

`fn get_type_id(&self) -> TypeId`

## 🔬 This is a nightly-only experimental API. (`get_type_id`

)

this method will likely be replaced by an associated static

Gets the `TypeId`

of `self`

. Read more

`impl<T, U> TryInto for T where`

U: TryFrom<T>,

[src]

`impl<T, U> TryInto for T where`

U: TryFrom<T>,

`type Error = <U as TryFrom<T>>::Error`

`try_from`

)The type returned in the event of a conversion error.

`fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>`

[src]

`fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>`

`try_from`

)Performs the conversion.

`impl<T> BorrowMut for T where`

T: ?Sized,

[src]

`impl<T> BorrowMut for T where`

T: ?Sized,

`fn borrow_mut(&mut self) -> &mut T`

[src]

`fn borrow_mut(&mut self) -> &mut T`

Mutably borrows from an owned value. Read more

`impl<SS, SP> SupersetOf for SP where`

SS: SubsetOf<SP>,

`impl<SS, SP> SupersetOf for SP where`

SS: SubsetOf<SP>,

`fn to_subset(&self) -> Option<SS>`

`fn to_subset(&self) -> Option<SS>`

The inverse inclusion map: attempts to construct `self`

from the equivalent element of its superset. Read more

`fn is_in_subset(&self) -> bool`

`fn is_in_subset(&self) -> bool`

Checks if `self`

is actually part of its subset `T`

(and can be converted to it).

`unsafe fn to_subset_unchecked(&self) -> SS`

`unsafe fn to_subset_unchecked(&self) -> SS`

Use with care! Same as `self.to_subset`

but without any property checks. Always succeeds.

`fn from_subset(element: &SS) -> SP`

`fn from_subset(element: &SS) -> SP`

The inclusion map: converts `self`

to the equivalent element of its superset.

`impl<T> Same for T`

`impl<T> Same for T`

`type Output = T`

Should always be `Self`