[][src]Trait nifti::volume::RandomAccessNiftiVolume

pub trait RandomAccessNiftiVolume: NiftiVolume {
    pub fn get_f64(&self, coords: &[u16]) -> Result<f64>;

    pub fn get_f32(&self, coords: &[u16]) -> Result<f32> { ... }
pub fn get_u8(&self, coords: &[u16]) -> Result<u8> { ... }
pub fn get_i8(&self, coords: &[u16]) -> Result<i8> { ... }
pub fn get_u16(&self, coords: &[u16]) -> Result<u16> { ... }
pub fn get_i16(&self, coords: &[u16]) -> Result<i16> { ... }
pub fn get_u32(&self, coords: &[u16]) -> Result<u32> { ... }
pub fn get_i32(&self, coords: &[u16]) -> Result<i32> { ... }
pub fn get_u64(&self, coords: &[u16]) -> Result<u64> { ... }
pub fn get_i64(&self, coords: &[u16]) -> Result<i64> { ... } }

Public API for a NIFTI volume with full random access to data.

This API is currently experimental and will likely be subjected to various changes and additions in future versions.

Required methods

pub fn get_f64(&self, coords: &[u16]) -> Result<f64>[src]

Fetch a single voxel's value in the given voxel index coordinates as a double precision floating point value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.
Loading content...

Provided methods

pub fn get_f32(&self, coords: &[u16]) -> Result<f32>[src]

Fetch a single voxel's value in the given voxel index coordinates as a single precision floating point value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_u8(&self, coords: &[u16]) -> Result<u8>[src]

Fetch a single voxel's value in the given voxel index coordinates as an unsigned 8-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_i8(&self, coords: &[u16]) -> Result<i8>[src]

Fetch a single voxel's value in the given voxel index coordinates as a signed 8-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_u16(&self, coords: &[u16]) -> Result<u16>[src]

Fetch a single voxel's value in the given voxel index coordinates as an unsigned 16-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_i16(&self, coords: &[u16]) -> Result<i16>[src]

Fetch a single voxel's value in the given voxel index coordinates as a signed 16-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_u32(&self, coords: &[u16]) -> Result<u32>[src]

Fetch a single voxel's value in the given voxel index coordinates as an unsigned 32-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_i32(&self, coords: &[u16]) -> Result<i32>[src]

Fetch a single voxel's value in the given voxel index coordinates as a signed 32-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_u64(&self, coords: &[u16]) -> Result<u64>[src]

Fetch a single voxel's value in the given voxel index coordinates as an unsigned 64-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.

pub fn get_i64(&self, coords: &[u16]) -> Result<i64>[src]

Fetch a single voxel's value in the given voxel index coordinates as a signed 64-bit value. All necessary conversions and transformations are made when reading the voxel, including scaling. Note that using this function continuously to traverse the volume is inefficient. Prefer using iterators or the ndarray API for volume traversal.

Errors

  • NiftiError::OutOfBounds if the given coordinates surpass this volume's boundaries.
Loading content...

Implementors

impl RandomAccessNiftiVolume for InMemNiftiVolume[src]

impl<'a> RandomAccessNiftiVolume for &'a InMemNiftiVolume[src]

impl<V> RandomAccessNiftiVolume for SliceView<V> where
    V: RandomAccessNiftiVolume
[src]

Loading content...