代码拉取完成,页面将自动刷新
同步操作将从 474807898/rv1106_1103_rtsp模块 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
// Copyright 2020 Fuzhou Rockchip Electronics Co., Ltd. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef __RTSP_DEMO_H__
#define __RTSP_DEMO_H__
/*
* a simple RTSP server demo
* RTP over UDP/TCP H264/G711a
* */
#include <stdint.h>
#ifdef __cplusplus
extern "C" {
#endif
enum rtsp_codec_id {
RTSP_CODEC_ID_NONE = 0,
RTSP_CODEC_ID_VIDEO_H264 = 0x0001, /*codec_data is SPS + PPS frames*/
RTSP_CODEC_ID_VIDEO_H265, /*codec_data is VPS + SPS + PPS frames*/
RTSP_CODEC_ID_VIDEO_MPEG4, /*now not support*/
RTSP_CODEC_ID_AUDIO_G711A = 0x4001, /*codec_data is NULL*/
RTSP_CODEC_ID_AUDIO_G711U, /*codec_data is NULL*/
RTSP_CODEC_ID_AUDIO_G726, /*codec_data is bitrate (int)*/
RTSP_CODEC_ID_AUDIO_MP3, /*codec_data is audio specific config (2bytes). frame
type is MP3*/
};
typedef void *rtsp_demo_handle;
typedef void *rtsp_session_handle;
rtsp_demo_handle rtsp_new_demo(int port);
rtsp_demo_handle create_rtsp_demo(int port);
int rtsp_do_event(rtsp_demo_handle demo);
rtsp_session_handle rtsp_new_session(rtsp_demo_handle demo, const char *path);
rtsp_session_handle create_rtsp_session(rtsp_demo_handle demo,
const char *path);
int rtsp_set_video(rtsp_session_handle session, int codec_id,
const uint8_t *codec_data, int data_len);
int rtsp_set_audio(rtsp_session_handle session, int codec_id,
const uint8_t *codec_data, int data_len);
int rtsp_sever_tx_video(rtsp_demo_handle demo, rtsp_session_handle session,
const uint8_t *frame, int len, uint64_t ts);
int rtsp_tx_video(rtsp_session_handle session, const uint8_t *frame, int len,
uint64_t ts);
int rtsp_tx_audio(rtsp_session_handle session, const uint8_t *frame, int len,
uint64_t ts);
void rtsp_del_session(rtsp_session_handle session);
void rtsp_del_demo(rtsp_demo_handle demo);
uint64_t rtsp_get_reltime(void);
uint64_t rtsp_get_ntptime(void);
int rtsp_sync_video_ts(rtsp_session_handle session, uint64_t ts,
uint64_t ntptime);
int rtsp_sync_audio_ts(rtsp_session_handle session, uint64_t ts,
uint64_t ntptime);
#ifdef __cplusplus
}
#endif
#endif
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。