Skip to content

Commit

Permalink
fix ptr align (#302)
Browse files Browse the repository at this point in the history
  • Loading branch information
theomonnom authored Feb 6, 2024
1 parent 4ca4129 commit 32035af
Show file tree
Hide file tree
Showing 4 changed files with 539 additions and 366 deletions.
5 changes: 2 additions & 3 deletions livekit-ffi/protocol/video_frame.proto
Original file line number Diff line number Diff line change
Expand Up @@ -100,16 +100,15 @@ enum VideoBufferType {

message VideoBufferInfo {
message ComponentInfo {
uint32 offset = 1;
uint64 data_ptr = 1;
uint32 stride = 2;
uint32 size = 3;
}
VideoBufferType type = 1;
uint32 width = 2;
uint32 height = 3;
uint64 data_ptr = 4;
uint32 data_len = 5;
uint32 stride = 6; // for packed formats
uint32 stride = 6; // only for packed formats
repeated ComponentInfo components = 7;
}

Expand Down
8 changes: 3 additions & 5 deletions livekit-ffi/src/livekit.proto.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1619,9 +1619,7 @@ pub struct VideoBufferInfo {
pub height: u32,
#[prost(uint64, tag="4")]
pub data_ptr: u64,
#[prost(uint32, tag="5")]
pub data_len: u32,
/// for packed formats
/// only for packed formats
#[prost(uint32, tag="6")]
pub stride: u32,
#[prost(message, repeated, tag="7")]
Expand All @@ -1632,8 +1630,8 @@ pub mod video_buffer_info {
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct ComponentInfo {
#[prost(uint32, tag="1")]
pub offset: u32,
#[prost(uint64, tag="1")]
pub data_ptr: u64,
#[prost(uint32, tag="2")]
pub stride: u32,
#[prost(uint32, tag="3")]
Expand Down
Loading

0 comments on commit 32035af

Please sign in to comment.