blob: f3c2fba960c6fa66d7ba8c2a16ae5b8ce5543eb5 [file] [log] [blame]
danilchapf8385ad2015-11-27 05:36:09 -08001/*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
3 *
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
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
danilchapf8385ad2015-11-27 05:36:09 -08009 */
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020010#ifndef MODULES_RTP_RTCP_SOURCE_RTCP_PACKET_PLI_H_
11#define MODULES_RTP_RTCP_SOURCE_RTCP_PACKET_PLI_H_
danilchapf8385ad2015-11-27 05:36:09 -080012
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020013#include "modules/rtp_rtcp/source/rtcp_packet/psfb.h"
14#include "rtc_base/basictypes.h"
danilchapf8385ad2015-11-27 05:36:09 -080015
16namespace webrtc {
17namespace rtcp {
danilchapf752f852016-03-23 08:25:25 -070018class CommonHeader;
danilchapf8385ad2015-11-27 05:36:09 -080019// Picture loss indication (PLI) (RFC 4585).
20class Pli : public Psfb {
21 public:
danilchap2f255d82016-10-17 02:07:54 -070022 static constexpr uint8_t kFeedbackMessageType = 1;
danilchapf8385ad2015-11-27 05:36:09 -080023
24 Pli() {}
danilchapf752f852016-03-23 08:25:25 -070025 ~Pli() override {}
danilchapf8385ad2015-11-27 05:36:09 -080026
danilchapf752f852016-03-23 08:25:25 -070027 bool Parse(const CommonHeader& packet);
danilchapf8385ad2015-11-27 05:36:09 -080028
eladalon8fa21c42017-06-16 07:07:47 -070029 size_t BlockLength() const override;
30
danilchapf8385ad2015-11-27 05:36:09 -080031 bool Create(uint8_t* packet,
32 size_t* index,
33 size_t max_length,
34 RtcpPacket::PacketReadyCallback* callback) const override;
danilchapf8385ad2015-11-27 05:36:09 -080035};
36
37} // namespace rtcp
38} // namespace webrtc
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020039#endif // MODULES_RTP_RTCP_SOURCE_RTCP_PACKET_PLI_H_