| 1 | use ffi::GstGLMemoryPBO; |
| 2 | use glib::translate::*; |
| 3 | use gst::{Memory, MemoryRef}; |
| 4 | |
| 5 | use crate::{ffi, GLBaseMemory, GLBaseMemoryRef, GLMemory, GLMemoryRef}; |
| 6 | |
| 7 | gst::memory_object_wrapper!( |
| 8 | GLMemoryPBO, |
| 9 | GLMemoryPBORef, |
| 10 | GstGLMemoryPBO, |
| 11 | |mem: &MemoryRef| { unsafe { from_glib(ffi::gst_is_gl_memory_pbo(mem.as_mut_ptr())) } }, |
| 12 | GLMemory, |
| 13 | GLMemoryRef, |
| 14 | GLBaseMemory, |
| 15 | GLBaseMemoryRef, |
| 16 | Memory, |
| 17 | MemoryRef |
| 18 | ); |
| 19 | |
| 20 | impl std::fmt::Debug for GLMemoryPBO { |
| 21 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { |
| 22 | GLMemoryPBORef::fmt(self, f) |
| 23 | } |
| 24 | } |
| 25 | |
| 26 | impl std::fmt::Debug for GLMemoryPBORef { |
| 27 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { |
| 28 | GLMemoryRef::fmt(self, f) |
| 29 | } |
| 30 | } |
| 31 | |