Struct lodepng::ffi::CompressSettings [−][src]
#[repr(C)]pub struct CompressSettings { pub windowsize: u32, pub minmatch: u16, pub nicematch: u16, pub btype: u8, pub use_lz77: bool, pub lazymatching: bool, pub custom_zlib: custom_compress_callback, pub custom_deflate: custom_compress_callback, pub custom_context: *const c_void, }
Expand description
Settings for zlib compression. Tweaking these settings tweaks the balance between speed and compression ratio.
Fields
windowsize: u32
Obsolete. No-op.
minmatch: u16
Compression level 1 (fast) to 9 (best). Use set_level()
instead.
nicematch: u16
Obsolete. No-op.
btype: u8
Obsolete. No-op.
use_lz77: bool
If false, it won’t compress at all. Use set_level(0)
lazymatching: bool
Obsolete. No-op.
custom_zlib: custom_compress_callback
use custom zlib encoder instead of built in one (default: None)
custom_deflate: custom_compress_callback
use custom deflate encoder instead of built in one (default: null) if custom_zlib is used, custom_deflate is ignored since only the built in zlib function will call custom_deflate
custom_context: *const c_void
optional custom settings for custom functions
Implementations
impl CompressSettings
[src]
impl CompressSettings
[src]pub fn new() -> CompressSettings
[src]
pub fn new() -> CompressSettings
[src]Default compression settings
Trait Implementations
impl Clone for CompressSettings
[src]
impl Clone for CompressSettings
[src]fn clone(&self) -> CompressSettings
[src]
fn clone(&self) -> CompressSettings
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl Debug for CompressSettings
[src]
impl Debug for CompressSettings
[src]impl Default for CompressSettings
[src]
impl Default for CompressSettings
[src]impl Sync for CompressSettings
[src]
Auto Trait Implementations
impl RefUnwindSafe for CompressSettings
impl !Send for CompressSettings
impl Unpin for CompressSettings
impl UnwindSafe for CompressSettings
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more