Commit 888519a8 authored by Luca Barbato's avatar Luca Barbato Committed by Luca Barbato

Make some struct usable from the C api

parent 8d0e891b
......@@ -17,6 +17,7 @@ use std::sync::Arc;
// TODO: use the num crate?
#[derive(Clone, Copy, Debug)]
#[repr(C)]
pub struct Ratio {
pub num: usize,
pub den: usize
......
......@@ -95,6 +95,7 @@ const PRIMARY_REF_BITS: u32 = 3;
arg_enum!{
#[derive(Copy, Clone, Debug, PartialEq)]
#[repr(C)]
pub enum Tune {
Psnr,
Psychovisual
......@@ -108,6 +109,7 @@ impl Default for Tune {
}
#[derive(Copy, Clone, Debug, PartialEq)]
#[repr(C)]
pub enum ChromaSampling {
Cs420,
Cs422,
......@@ -446,6 +448,7 @@ impl fmt::Display for FrameInvariants{
#[allow(dead_code,non_camel_case_types)]
#[derive(Debug,PartialEq,Clone,Copy)]
#[repr(C)]
pub enum FrameType {
KEY,
INTER,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment