框架地址:
https://github.com/ZLMediaKit/ZLMediaKit/wiki/MediaServer%E6%94%AF%E6%8C%81%E7%9A%84HTTP-API
部署ZLMediaKit解码器
在springboot中使用api进行代理 和关流 使用 addStreamProxy 和 close_streams 接口
/** * 获取电网容量数据 * * @param playType play type * @param stream stream * @param url url * @return the string * @since 3.0.0 */ @Get("/index/api/addStreamProxy?vhost=https://nvr.minexiot.com&secret=crRbv1YruHIdUkp8GoBYElXI3152HlAF&app={playType}&stream={stream}&url={url}") String addStream(@Var("playType") String playType, @Var("stream") String stream, @Var("url") String url); /** * Close stream * * @param playType play type * @param stream stream * @return the string * @since 3.5.0 */ @Get("/index/api/close_streams?secret=crRbv1YruHIdUkp8GoBYElXI3152HlAF&schema=rtsp&vhost=__defaultVhost__&app={playType}&stream={stream}&force=1") String closeStream(@Var("playType") String playType, @Var("stream") String stream);
标签:ZLMediaKit,String,stream,url,RTSP,MP4,Var,playType From: https://www.cnblogs.com/guanxiaohe/p/17988884