X-Git-Url: https://git.nihav.org/?a=blobdiff_plain;f=nihav-core%2Fsrc%2Fformats.rs;h=ffacb128e04598f36a73965cfaf6c3a6ad1fdbf0;hb=8ea7e3064452b84ba3428de3c6f88b834a66b78c;hp=bb47838c252018d497e509f970d64acd7cc9da4e;hpb=237cc1f9576ed23c7a2f9bb34b43e5d07e93f710;p=nihav.git diff --git a/nihav-core/src/formats.rs b/nihav-core/src/formats.rs index bb47838..ffacb12 100644 --- a/nihav-core/src/formats.rs +++ b/nihav-core/src/formats.rs @@ -114,7 +114,7 @@ impl fmt::Display for NASoniton { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { let fmt = if self.float { "float" } else if self.signed { "int" } else { "uint" }; let end = if self.be { "BE" } else { "LE" }; - write!(f, "({} bps, {} planar: {} packed: {} {})", self.bits, end, self.packed, self.planar, fmt) + write!(f, "({} bps, {} planar: {} packed: {} {})", self.bits, end, self.planar, self.packed, fmt) } } @@ -961,18 +961,18 @@ fn parse_yuv_format(s: &str) -> Result { return Ok(NAPixelFormaton { model: ColorModel::YUV(YUVSubmodel::YUVJ), components: 1, comp_info: [ - Some(NAPixelChromaton{ h_ss: 0, v_ss: 0, packed: true, depth: 8, shift: 0, comp_offs: 0, next_elem: 1 }), + Some(NAPixelChromaton{ h_ss: 0, v_ss: 0, packed: false, depth: 8, shift: 0, comp_offs: 0, next_elem: 1 }), None, None, None, None], - elem_size: 1, be: false, alpha: false, palette: false }); + elem_size: 1, be: true, alpha: false, palette: false }); }, "y8a" | "y400a" | "graya" => { return Ok(NAPixelFormaton { model: ColorModel::YUV(YUVSubmodel::YUVJ), components: 2, comp_info: [ - Some(NAPixelChromaton{ h_ss: 0, v_ss: 0, packed: true, depth: 8, shift: 0, comp_offs: 0, next_elem: 2 }), - Some(NAPixelChromaton{ h_ss: 0, v_ss: 0, packed: true, depth: 8, shift: 0, comp_offs: 1, next_elem: 2 }), + Some(NAPixelChromaton{ h_ss: 0, v_ss: 0, packed: false, depth: 8, shift: 0, comp_offs: 0, next_elem: 2 }), + Some(NAPixelChromaton{ h_ss: 0, v_ss: 0, packed: false, depth: 8, shift: 0, comp_offs: 1, next_elem: 2 }), None, None, None], - elem_size: 1, be: false, alpha: true, palette: false }); + elem_size: 1, be: true, alpha: true, palette: false }); }, "uyvy" | "y422" => { return Ok(NAPixelFormaton {