Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(246)

Side by Side Diff: webrtc/modules/video_coding/h264_sps_pps_tracker.h

Issue 2651593004: Reland of "H264SpsPpsTracker.InsertSpsPpsNalus() should accept Nalus with header. (Closed)
Patch Set: Comment. Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | webrtc/modules/video_coding/h264_sps_pps_tracker.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 11 matching lines...) Expand all
22 22
23 class VCMPacket; 23 class VCMPacket;
24 24
25 namespace video_coding { 25 namespace video_coding {
26 26
27 class H264SpsPpsTracker { 27 class H264SpsPpsTracker {
28 public: 28 public:
29 enum PacketAction { kInsert, kDrop, kRequestKeyframe }; 29 enum PacketAction { kInsert, kDrop, kRequestKeyframe };
30 30
31 PacketAction CopyAndFixBitstream(VCMPacket* packet); 31 PacketAction CopyAndFixBitstream(VCMPacket* packet);
32 void InsertSpsPps(const std::vector<uint8_t>& sps, 32
33 const std::vector<uint8_t>& pps); 33 void InsertSpsPpsNalus(const std::vector<uint8_t>& sps,
34 const std::vector<uint8_t>& pps);
34 35
35 private: 36 private:
36 struct PpsInfo { 37 struct PpsInfo {
37 int sps_id = -1; 38 int sps_id = -1;
38 size_t size = 0; 39 size_t size = 0;
39 std::unique_ptr<uint8_t[]> data; 40 std::unique_ptr<uint8_t[]> data;
40 }; 41 };
41 42
42 struct SpsInfo { 43 struct SpsInfo {
43 size_t size = 0; 44 size_t size = 0;
44 std::unique_ptr<uint8_t[]> data; 45 std::unique_ptr<uint8_t[]> data;
45 }; 46 };
46 47
47 std::map<uint32_t, PpsInfo> pps_data_; 48 std::map<uint32_t, PpsInfo> pps_data_;
48 std::map<uint32_t, SpsInfo> sps_data_; 49 std::map<uint32_t, SpsInfo> sps_data_;
49 }; 50 };
50 51
51 } // namespace video_coding 52 } // namespace video_coding
52 } // namespace webrtc 53 } // namespace webrtc
53 54
54 #endif // WEBRTC_MODULES_VIDEO_CODING_H264_SPS_PPS_TRACKER_H_ 55 #endif // WEBRTC_MODULES_VIDEO_CODING_H264_SPS_PPS_TRACKER_H_
OLDNEW
« no previous file with comments | « no previous file | webrtc/modules/video_coding/h264_sps_pps_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698