1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
// This file was generated by gir (https://github.com/gtk-rs/gir)
// from gir-files (https://github.com/gtk-rs/gir-files)
// from gst-gir-files (https://gitlab.freedesktop.org/gstreamer/gir-files-rs.git)
// DO NOT EDIT

use glib::translate::*;

glib::wrapper! {
    #[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Hash)]
    pub struct GLAllocationParams(Boxed<ffi::GstGLAllocationParams>);

    match fn {
        copy => |ptr| ffi::gst_gl_allocation_params_copy(mut_override(ptr)),
        free => |ptr| ffi::gst_gl_allocation_params_free(ptr),
        type_ => || ffi::gst_gl_allocation_params_get_type(),
    }
}

impl GLAllocationParams {
    /// Copies the dynamically allocated data from `self` to `dest`. Direct subclasses
    /// should call this function in their own overridden copy function.
    /// ## `dest`
    /// the destination [`GLAllocationParams`][crate::GLAllocationParams]
    #[doc(alias = "gst_gl_allocation_params_copy_data")]
    pub fn copy_data(&self, dest: &mut GLAllocationParams) {
        unsafe {
            ffi::gst_gl_allocation_params_copy_data(
                mut_override(self.to_glib_none().0),
                dest.to_glib_none_mut().0,
            );
        }
    }

    //#[doc(alias = "gst_gl_allocation_params_init")]
    //pub fn init<P: Fn(&GLAllocationParams, &GLAllocationParams) + Send + Sync + 'static, Q: IsA<GLContext>>(&mut self, struct_size: usize, alloc_flags: u32, copy: P, free: /*Unimplemented*/Fn(/*Unimplemented*/Option<Fundamental: Pointer>), context: &Q, alloc_size: usize, alloc_params: Option<&gst::AllocationParams>, wrapped_data: /*Unimplemented*/Option<Fundamental: Pointer>, gl_handle: /*Unimplemented*/Option<Fundamental: Pointer>, user_data: /*Unimplemented*/Option<Fundamental: Pointer>) -> bool {
    //    unsafe { TODO: call ffi:gst_gl_allocation_params_init() }
    //}
}

unsafe impl Send for GLAllocationParams {}
unsafe impl Sync for GLAllocationParams {}