gstreamer_gl/auto/gl_allocation_params.rs
1// This file was generated by gir (https://github.com/gtk-rs/gir)
2// from gir-files (https://github.com/gtk-rs/gir-files)
3// from gst-gir-files (https://gitlab.freedesktop.org/gstreamer/gir-files-rs.git)
4// DO NOT EDIT
5
6use crate::ffi;
7use glib::translate::*;
8
9glib::wrapper! {
10 #[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Hash)]
11 pub struct GLAllocationParams(Boxed<ffi::GstGLAllocationParams>);
12
13 match fn {
14 copy => |ptr| ffi::gst_gl_allocation_params_copy(mut_override(ptr)),
15 free => |ptr| ffi::gst_gl_allocation_params_free(ptr),
16 type_ => || ffi::gst_gl_allocation_params_get_type(),
17 }
18}
19
20impl GLAllocationParams {
21 /// Copies the dynamically allocated data from `self` to `dest`. Direct subclasses
22 /// should call this function in their own overridden copy function.
23 /// ## `dest`
24 /// the destination [`GLAllocationParams`][crate::GLAllocationParams]
25 #[doc(alias = "gst_gl_allocation_params_copy_data")]
26 pub fn copy_data(&self, dest: &mut GLAllocationParams) {
27 unsafe {
28 ffi::gst_gl_allocation_params_copy_data(
29 mut_override(self.to_glib_none().0),
30 dest.to_glib_none_mut().0,
31 );
32 }
33 }
34
35 //#[doc(alias = "gst_gl_allocation_params_init")]
36 //pub fn init<P: Fn(&GLAllocationParams) + Send + Sync + 'static, Q: Fn() + Send + Sync + 'static>(&mut self, struct_size: usize, alloc_flags: u32, copy: P, free: Q, context: &impl IsA<GLContext>, alloc_size: usize, alloc_params: Option<&gst::AllocationParams>, wrapped_data: /*Unimplemented*/Option<Basic: Pointer>, gl_handle: /*Unimplemented*/Option<Basic: Pointer>) -> bool {
37 // unsafe { TODO: call ffi:gst_gl_allocation_params_init() }
38 //}
39}
40
41unsafe impl Send for GLAllocationParams {}
42unsafe impl Sync for GLAllocationParams {}