| | |
| | | |
| | | import cn.hutool.core.io.FileUtil; |
| | | import com.ruoyi.common.core.utils.StringUtils; |
| | | import com.ruoyi.system.service.ICarService; |
| | | import org.bytedeco.ffmpeg.global.avcodec; |
| | | import org.bytedeco.ffmpeg.global.avutil; |
| | | import org.bytedeco.javacv.*; |
| | | import org.springframework.data.redis.core.RedisTemplate; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Map; |
| | | import java.util.concurrent.ConcurrentHashMap; |
| | | |
| | |
| | | |
| | | private static Map<Integer, Boolean> statusMap = new ConcurrentHashMap<>(); |
| | | |
| | | @Resource |
| | | private RedisTemplate redisTemplate; |
| | | |
| | | @Resource |
| | | private ICarService carService; |
| | | public static void main(String[] args) { |
| | | String url = "rtmp://127.0.0.1:1935/flv/test"; |
| | | JavaCVStreamUtil.push_flv("C:\\Users\\39373\\Desktop\\图片\\trailer.mp4", url, 0); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | /** |
| | |
| | | OpenCVFrameGrabber openCVFrameGrabber = grabberMap1.get(deviceNumber); |
| | | if (null != openCVFrameGrabber) { |
| | | openCVFrameGrabber.close(); |
| | | ; |
| | | } |
| | | FFmpegFrameRecorder fFmpegFrameRecorder = frameRecorderMap.get(deviceNumber); |
| | | if (null != fFmpegFrameRecorder) { |