maraiah: make mediaflags u8 to fix incorrect flags
parent
9dcf487d18
commit
80295108b7
|
@ -13,7 +13,7 @@ pub fn read(b: &[u8]) -> ResultS<(Media, usize)>
|
||||||
read_data! {
|
read_data! {
|
||||||
endian: BIG, buf: b, size: 32, start: 0, data {
|
endian: BIG, buf: b, size: 32, start: 0, data {
|
||||||
let mtype = u16[0] enum MediaType;
|
let mtype = u16[0] enum MediaType;
|
||||||
let flags = u16[2] flag MediaFlags;
|
let flags = u8[3] flag MediaFlags;
|
||||||
let control = u16[4];
|
let control = u16[4];
|
||||||
let dir = Angle[6];
|
let dir = Angle[6];
|
||||||
let mag = Unit[8];
|
let mag = Unit[8];
|
||||||
|
@ -63,7 +63,7 @@ c_enum! {
|
||||||
bitflags! {
|
bitflags! {
|
||||||
/// Flags for `Media`.
|
/// Flags for `Media`.
|
||||||
#[cfg_attr(feature = "serde_obj", derive(serde::Serialize))]
|
#[cfg_attr(feature = "serde_obj", derive(serde::Serialize))]
|
||||||
pub struct MediaFlags: u16 {
|
pub struct MediaFlags: u8 {
|
||||||
const OBSTRUCT = 1;
|
const OBSTRUCT = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue