Older/MediaServer/Rtp/ProcessInterface.h

53 lines
1.4 KiB
C
Raw Normal View History

2024-09-28 23:55:00 +08:00
/*
* Copyright (c) 2016-present The ZLMediaKit project authors. All Rights Reserved.
*
* This file is part of ZLMediaKit(https://github.com/ZLMediaKit/ZLMediaKit).
*
* Use of this source code is governed by MIT-like license that can be found in the
* LICENSE file in the root of the source tree. All contributing project authors
* may be found in the AUTHORS file in the root of the source tree.
*/
#ifndef ZLMEDIAKIT_PROCESSINTERFACE_H
#define ZLMEDIAKIT_PROCESSINTERFACE_H
#include <stdint.h>
#include <memory>
namespace mediakit {
class ProcessInterface {
public:
using Ptr = std::shared_ptr<ProcessInterface>;
virtual ~ProcessInterface() = default;
/**
* rtp
* @param is_udp udp模式
* @param data rtp数据指针
* @param data_len rtp数据长度
* @return
* Input rtp
* @param is_udp Whether it is udp mode
* @param data rtp data pointer
* @param data_len rtp data length
* @return Whether the parsing is successful
* [AUTO-TRANSLATED:7d5b06f0]
*/
virtual bool inputRtp(bool is_udp, const char *data, size_t data_len) = 0;
/**
*
* Refresh and output all caches
* [AUTO-TRANSLATED:4509b01f]
*/
virtual void flush() {}
};
}//namespace mediakit
#endif //ZLMEDIAKIT_PROCESSINTERFACE_H