Shaka Packager SDK
Loading...
Searching...
No Matches
two_pass_single_segment_segmenter.h
1// Copyright 2015 Google LLC. All rights reserved.
2//
3// Use of this source code is governed by a BSD-style
4// license that can be found in the LICENSE file or at
5// https://developers.google.com/open-source/licenses/bsd
6
7#ifndef PACKAGER_MEDIA_FORMATS_WEBM_TWO_PASS_SINGLE_SEGMENT_SEGMENTER_H_
8#define PACKAGER_MEDIA_FORMATS_WEBM_TWO_PASS_SINGLE_SEGMENT_SEGMENTER_H_
9
10#include <cstdint>
11#include <memory>
12#include <string>
13
14#include <packager/macros/classes.h>
15#include <packager/media/formats/webm/mkv_writer.h>
16#include <packager/media/formats/webm/single_segment_segmenter.h>
17#include <packager/status.h>
18
19namespace shaka {
20namespace media {
21
22struct MuxerOptions;
23
24namespace webm {
25
29 public:
30 explicit TwoPassSingleSegmentSegmenter(const MuxerOptions& options);
32
33 // Segmenter implementation overrides.
34 Status DoInitialize() override;
35 Status DoFinalize() override;
36
37 private:
42 bool CopyFileWithClusterRewrite(File* source,
43 MkvWriter* dest,
44 uint64_t last_size);
45
46 std::string temp_file_name_;
47
48 DISALLOW_COPY_AND_ASSIGN(TwoPassSingleSegmentSegmenter);
49};
50
51} // namespace webm
52} // namespace media
53} // namespace shaka
54
55#endif // PACKAGER_MEDIA_FORMATS_WEBM_TWO_PASS_SINGLE_SEGMENT_SEGMENTER_H_
An implementation of IMkvWriter using our File type.
Definition mkv_writer.h:23
All the methods that are virtual are virtual for mocking.
This structure contains the list of configuration options for Muxer.