Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an SLConfigDescriptor to the ES_Descriptor #36

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion minimp4.h
Original file line number Diff line number Diff line change
Expand Up @@ -1445,7 +1445,9 @@ static int mp4e_flush_index(MP4E_mux_t *mux)
int dsi_size_size = od_size_of_size(dsi_bytes);
int dcd_bytes = dsi_bytes + dsi_size_size + 1 + (1 + 1 + 3 + 4 + 4);
int dcd_size_size = od_size_of_size(dcd_bytes);
int esd_bytes = dcd_bytes + dcd_size_size + 1 + 3;
int slc_size_size = od_size_of_size(1);
int slc_bytes = slc_size_size + 1 + 1;
int esd_bytes = dcd_bytes + dcd_size_size + 1 + 3 + slc_bytes;

#define WRITE_OD_LEN(size) if (size > 0x7F) do { size -= 0x7F; WRITE_1(0x00ff); } while (size > 0x7F); WRITE_1(size)
WRITE_1(3); // OD_ESD
Expand Down Expand Up @@ -1475,6 +1477,10 @@ static int mp4e_flush_index(MP4E_mux_t *mux)
{
WRITE_1(tr->vsps.data[2 + i]);
}

WRITE_1(6); // OD_SLC
WRITE_OD_LEN(slc_size_size);
WRITE_1(2);
}
END_ATOM;
END_ATOM;
Expand Down