feat: refactor prudp code and start working on refactoring rmc
This commit is contained in:
parent
7d24a71f09
commit
3ea7c7e671
37 changed files with 2029 additions and 456 deletions
|
|
@ -96,10 +96,11 @@ impl Debug for TypesFlags {
|
|||
}
|
||||
|
||||
#[repr(transparent)]
|
||||
#[derive(PartialEq, Eq, Copy, Clone, Pod, Zeroable, SwapEndian, Hash)]
|
||||
#[derive(PartialEq, Eq, Ord, PartialOrd, Copy, Clone, Pod, Zeroable, SwapEndian, Hash)]
|
||||
pub struct VirtualPort(pub(crate) u8);
|
||||
|
||||
impl VirtualPort {
|
||||
|
||||
#[inline]
|
||||
pub const fn get_stream_type(self) -> u8 {
|
||||
(self.0 & 0xF0) >> 4
|
||||
|
|
@ -236,7 +237,7 @@ impl PacketOption{
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Eq, PartialEq)]
|
||||
#[derive(Debug, Default, Clone, Eq, PartialEq)]
|
||||
pub struct PRUDPPacket {
|
||||
pub header: PRUDPHeader,
|
||||
pub packet_signature: [u8; 16],
|
||||
|
|
@ -375,6 +376,7 @@ impl PRUDPPacket {
|
|||
types_and_flags: flags,
|
||||
sequence_id: self.header.sequence_id,
|
||||
substream_id: self.header.substream_id,
|
||||
session_id: self.header.session_id,
|
||||
..base.header
|
||||
},
|
||||
options,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue