mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-30 05:31:15 +00:00
qtmux: for fixed-sample size streams (PCM audio, etc) don't allocate an enormous
buffer that we then won't use at all.
This commit is contained in:
parent
d784a8da6a
commit
3c0e4d8267
1 changed files with 2 additions and 2 deletions
|
@ -1742,9 +1742,9 @@ atom_stsz_copy_data (AtomSTSZ * stsz, guint8 ** buffer, guint64 * size,
|
||||||
|
|
||||||
prop_copy_uint32 (stsz->sample_size, buffer, size, offset);
|
prop_copy_uint32 (stsz->sample_size, buffer, size, offset);
|
||||||
prop_copy_uint32 (stsz->table_size, buffer, size, offset);
|
prop_copy_uint32 (stsz->table_size, buffer, size, offset);
|
||||||
/* minimize realloc */
|
|
||||||
prop_copy_ensure_buffer (buffer, size, offset, 4 * stsz->table_size);
|
|
||||||
if (stsz->sample_size == 0) {
|
if (stsz->sample_size == 0) {
|
||||||
|
/* minimize realloc */
|
||||||
|
prop_copy_ensure_buffer (buffer, size, offset, 4 * stsz->table_size);
|
||||||
/* entry count must match sample count */
|
/* entry count must match sample count */
|
||||||
g_assert (atom_array_get_len (&stsz->entries) == stsz->table_size);
|
g_assert (atom_array_get_len (&stsz->entries) == stsz->table_size);
|
||||||
for (i = 0; i < atom_array_get_len (&stsz->entries); i++) {
|
for (i = 0; i < atom_array_get_len (&stsz->entries); i++) {
|
||||||
|
|
Loading…
Reference in a new issue