pub struct PsdReader {
psd: PsdFile,
encoding: Encoding,
channel_start_indices: Vec<usize>,
}Available on crate feature
utils-psd only.Fields§
§psd: PsdFile§encoding: Encoding§channel_start_indices: Vec<usize>Implementations§
Source§impl PsdReader
impl PsdReader
pub fn new<T: Read + Seek>(reader: T, encoding: Encoding) -> Result<Self>
Sourcepub fn color_mode(&self) -> u16
pub fn color_mode(&self) -> u16
Returns the color mode of the PSD file.
1 = Grayscale, 3 = RGB, etc.
Sourcepub fn read_layers<'a>(&'a self) -> Result<Vec<Layer<'a>>>
pub fn read_layers<'a>(&'a self) -> Result<Vec<Layer<'a>>>
Reads and returns the layers in the PSD file.
Sourcepub fn read_normal_layers<'a>(&'a self) -> Result<Vec<NormalLayer<'a>>>
pub fn read_normal_layers<'a>(&'a self) -> Result<Vec<NormalLayer<'a>>>
Returns the normal layers in the PSD file. This function ignores layer groups.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PsdReader
impl RefUnwindSafe for PsdReader
impl Send for PsdReader
impl Sync for PsdReader
impl Unpin for PsdReader
impl UnwindSafe for PsdReader
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more