GstBufferPool Create buffers from a pool A bufferpool is used to create buffers in an efficient way. En element can maintain a bufferpool with a fixed number of buffers. This will reduce the g_malloc and g_free overhead. A bufferpool can also be used to implement direct access. A bufferpool can be sent from one element to another so that the latter can directly write into the memory of the element that maintains the bufferpool. This can greatly reduce the number of memcpy operations. A bufferpool is created with gst_buffer_pool_new(). You'll have to set the buffer allocation and destroy function afterwards with gst_buffer_pool_set_create_function() and gst_buffer_pool_set_destroy_function(). To create a buffer from the bufferpool use gst_buffer_pool_new_buffer(), which is functionally equivalent to gst_buffer_new_from_pool(). When the buffer is unreffed and has reached a refcount of 0, the bufferpools destroy function is called with the buffer as an argument. A bufferpool can store private data in the buffer it creates with the GST_BUFFER_POOL_PRIVATE() macro. To check it a buffer was made by a specific bufferpool, use the GST_BUFFER_BUFFERPOOL() macro to get it's bufferpool. Destroy the bufferpool with gst_buffer_pool_destroy(). A bufferpool can be requested from a pad with the gst_pad_get_bufferpool() function. #GstBuffer, #GstPad @lock: @buffer_free: @buffer_copy: @destroy_hook: @user_data: @pool: @location: @size: @user_data: @Returns: @pool: @user_data: Lock the given bufferpool. @pool: The pool to lock. Unlock the given bufferpool. @pool: the bufferpool to unlock. @Returns: @pool: @pool: @count: @pool: @buffer: @pool: @buffer_size: @pool_size: @Returns: @oldpool: @pool: @user_data: @pool: @Returns: @user_data: @pool: @copy: @pool: @destroy: @pool: @create: @pool: @destroy: