[][src]Struct rips::Image

pub struct Image(_);

Methods

impl Image[src]

pub fn width(&self) -> i32[src]

pub fn height(&self) -> i32[src]

pub fn from_file<S: Into<Vec<u8>>>(path: S) -> Result<Image>[src]

pub fn from_memory(
    buf: Vec<u8>,
    width: i32,
    height: i32,
    bands: i32,
    format: VipsBandFormat
) -> Result<Image>
[src]

pub fn resize(
    &self,
    scale: f64,
    vscale: Option<f64>,
    kernel: Option<VipsKernel>
) -> Result<Image>
[src]

pub fn resize_to(
    &self,
    width: Option<i32>,
    height: Option<i32>
) -> Result<Image>
[src]

pub fn crop(
    &self,
    left: i32,
    top: i32,
    width: i32,
    height: i32
) -> Result<Image>
[src]

pub fn rotate(&self, angle: VipsAngle) -> Result<Image>[src]

pub fn write_to_file<S: Into<Vec<u8>>>(&self, path: S) -> Result<()>[src]

pub fn to_buffer(&self, suffix: &str) -> Result<Vec<u8>>[src]

pub fn to_bytes(&self) -> Vec<u8>[src]

Trait Implementations

impl Send for Image[src]

impl Sync for Image[src]

impl Drop for Image[src]

Auto Trait Implementations

impl Unpin for Image

impl UnwindSafe for Image

impl RefUnwindSafe for Image

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]