[gstreamer-bugs] [Bug 619292] [API] add chunk writer

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Sat May 22 13:53:11 PDT 2010


https://bugzilla.gnome.org/show_bug.cgi?id=619292
  GStreamer | gstreamer (core) | git

--- Comment #7 from Benjamin Otte (Company) <otte at gnome.org> 2010-05-22 20:53:06 UTC ---
If I were to do something like this, I'd have an API that hands you a new
bytewriter object that writes a subpart of the parent bytewriter. But this is
not really what you want for the chunked files use case - all you want here is
write the size of a chunk later.
And I think rewind(), put_uint32(), back_to_end() - style API is very suitable
for that. And you can support that very well with offsets, which are basically
the same thing as marks.

A different API would probably make sense if you wanted to reserve a fixed-size
section of more than 4 bytes and write them later or maybe even interchangably
with the rest of the byte writer (dunno, maybe an index?), where it'd be nice
to be able to create a fixed size byte writer ala
  subsection_writer = gst_byte_writer_new_for_section (parent_writer,
num_bytes);
but that is hard to do with the current bytewriter API (due to resizes
invalidating the pointer) and I don't think we have any use cases for it.

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.




More information about the Gstreamer-bugs mailing list