#[repr(C)]pub struct SwsContext {Show 21 fields
pub av_class: *const AVClass,
pub opaque: *mut c_void,
pub flags: c_uint,
pub scaler_params: [f64; 2],
pub threads: c_int,
pub dither: SwsDither,
pub alpha_blend: SwsAlphaBlend,
pub gamma_flag: c_int,
pub src_w: c_int,
pub src_h: c_int,
pub dst_w: c_int,
pub dst_h: c_int,
pub src_format: c_int,
pub dst_format: c_int,
pub src_range: c_int,
pub dst_range: c_int,
pub src_v_chr_pos: c_int,
pub src_h_chr_pos: c_int,
pub dst_v_chr_pos: c_int,
pub dst_h_chr_pos: c_int,
pub intent: c_int,
}展开描述
Main external API structure. New fields can be added to the end with minor version bumps. Removal, reordering and changes to existing fields require a major version bump. sizeof(SwsContext) is not part of the ABI.
Fields§
§av_class: *const AVClass§opaque: *mut c_voidPrivate data of the user, can be used to carry app specific stuff.
flags: c_uintBitmask of SWS_*. See SwsFlags for details.
scaler_params: [f64; 2]Extra parameters for fine-tuning certain scalers.
threads: c_intHow many threads to use for processing, or 0 for automatic selection.
dither: SwsDitherDither mode.
alpha_blend: SwsAlphaBlendAlpha blending mode. See SwsAlphaBlend for details.
gamma_flag: c_intUse gamma correct scaling.
src_w: c_int< Width and height of the source frame
src_h: c_int< Width and height of the source frame
dst_w: c_int< Width and height of the destination frame
dst_h: c_int< Width and height of the destination frame
src_format: c_int< Source pixel format
dst_format: c_int< Destination pixel format
src_range: c_int< Source is full range
dst_range: c_int< Destination is full range
src_v_chr_pos: c_int< Source vertical chroma position in luma grid / 256
src_h_chr_pos: c_int< Source horizontal chroma position
dst_v_chr_pos: c_int< Destination vertical chroma position
dst_h_chr_pos: c_int< Destination horizontal chroma position
intent: c_intDesired ICC intent for color space conversions.
trait 实现§
源代码§impl Clone for SwsContext
impl Clone for SwsContext
源代码§fn clone(&self) -> SwsContext
fn clone(&self) -> SwsContext
1.0.0 · 源代码§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source 执行拷贝赋值。 阅读更多