diff options
author | Wim Taymans <wim.taymans@collabora.co.uk> | 2013-03-27 17:08:51 +0100 |
---|---|---|
committer | Wim Taymans <wim.taymans@collabora.co.uk> | 2013-03-27 17:08:51 +0100 |
commit | 21851c0e04b9d4196bc44e35a4e241878837920e (patch) | |
tree | d413d38b5a83953f020425844606a261dcf3d14a | |
parent | 700be18f11ea3639a226321d6d3d839f9055b394 (diff) |
porting: hopefully clarify a little
-rw-r--r-- | docs/random/porting-to-1.0.txt | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/docs/random/porting-to-1.0.txt b/docs/random/porting-to-1.0.txt index 9d22b147f..0d96fe710 100644 --- a/docs/random/porting-to-1.0.txt +++ b/docs/random/porting-to-1.0.txt @@ -233,16 +233,17 @@ CHANGES a GstBuffer that can then be retrieved with gst_buffer_peek_memory(). GST_BUFFER_DATA(), GST_BUFFER_MALLOCDATA(), GST_BUFFER_FREE_FUNC() and - GST_BUFFER_SIZE() are gone, along with the fields in GstBuffer. Use the - memory API to get access to the buffer data. GST_BUFFER_SIZE() can be - replaced with gst_buffer_get_size() but if also access to the data is - required, gst_buffer_map() can return both the size and data in one go. + GST_BUFFER_SIZE() are gone, along with the fields in GstBuffer. The most common way to access all the data in a buffer is by using gst_buffer_map() and gst_buffer_unmap(). These calls require you to specify the access mode required to the data and will automatically merge and return a writable copy of the data. + GST_BUFFER_SIZE() can be replaced with gst_buffer_get_size() but if also + access to the data is required, gst_buffer_map() can return both the size + and data in one go. + The buffer must be writable (gst_buffer_is_writable()) in order to modify the fields, metadata or buffer memory. gst_buffer_make_writable() will not automatically make a writable copy of the memory but will instead increase |