OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 |
11 #include "webrtc/modules/audio_coding/neteq/payload_splitter.h" | 11 #include "webrtc/modules/audio_coding/neteq/payload_splitter.h" |
12 | 12 |
13 #include <assert.h> | 13 #include <assert.h> |
14 #include <iostream> | |
15 | 14 |
16 #include "webrtc/base/checks.h" | 15 #include "webrtc/base/checks.h" |
17 #include "webrtc/base/logging.h" | 16 #include "webrtc/base/logging.h" |
18 #include "webrtc/modules/audio_coding/neteq/decoder_database.h" | 17 #include "webrtc/modules/audio_coding/neteq/decoder_database.h" |
19 | 18 |
20 namespace webrtc { | 19 namespace webrtc { |
21 | 20 |
22 // The method loops through a list of packets {A, B, C, ...}. Each packet is | 21 // The method loops through a list of packets {A, B, C, ...}. Each packet is |
23 // split into its corresponding RED payloads, {A1, A2, ...}, which is | 22 // split into its corresponding RED payloads, {A1, A2, ...}, which is |
24 // temporarily held in the list |new_packets|. | 23 // temporarily held in the list |new_packets|. |
(...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
428 new_packet->primary = packet->primary; | 427 new_packet->primary = packet->primary; |
429 new_packet->payload.SetData(payload_ptr, bytes_per_frame); | 428 new_packet->payload.SetData(payload_ptr, bytes_per_frame); |
430 payload_ptr += bytes_per_frame; | 429 payload_ptr += bytes_per_frame; |
431 new_packets->push_back(new_packet); | 430 new_packets->push_back(new_packet); |
432 len -= bytes_per_frame; | 431 len -= bytes_per_frame; |
433 } | 432 } |
434 return kOK; | 433 return kOK; |
435 } | 434 } |
436 | 435 |
437 } // namespace webrtc | 436 } // namespace webrtc |
OLD | NEW |