mkvmuxer: Add Init method to Cluster and Segment.
Remove asserts on the MkvWriter pointer in each constructor, and assign the pointer in each Init method. Update Segment::Init usage site in sample_muxer. Change-Id: Id940f76b50dc15603742e76afc04cdffe0ec4990
This commit is contained in:
@@ -171,7 +171,13 @@ int main(int argc, char* argv[]) {
|
||||
}
|
||||
|
||||
// Set Segment element attributes
|
||||
mkvmuxer::Segment muxer_segment(&writer);
|
||||
mkvmuxer::Segment muxer_segment;
|
||||
|
||||
if (!muxer_segment.Init(&writer)) {
|
||||
printf("\n Could not initialize muxer segment!\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (live_mode)
|
||||
muxer_segment.set_mode(mkvmuxer::Segment::kLive);
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user