当前位置:网站首页>Read H264 parameters from mediarecord recording
Read H264 parameters from mediarecord recording
2022-07-02 10:46:00 【Small waves-】
explain :
Many used to do a test project , Want to put android Mobile video access video server , This is how it works :
hold android The real-time video of the mobile phone is uploaded to the background forwarding server , The forwarding server packages the audio and video streams into IPC rtsp Server form , Streaming media connecting to mobile forwarding server is like connecting IPC The equipment is the same , Use rtsp Pull stream mode to get video stream .
So as to realize the mobile phone --- Forwarding server --- Video server —PC Two way communication of client .
This scheme is a simplified scheme , The mobile terminal is only responsible for packet capture playback and remote playback , The forwarding server only implements one rtsp Encapsulation does not have any other functions , Other modules are unchanged . The mobile terminal uses the top mediarecorder object , While recording echo , Pass audio and video on one side .
The mobile terminal needs to use a custom protocol to communicate with the forwarding server , Inform the server of audio and video parameters , Among them, it is very important to obtain video parameters .
how Get video parameters ? Actually ,mediarecorder(H264) The beginning of the recorded data of contains SPS and pps Parameters , Analyze it and take it out , And the same equipment 、 Obtained with the same configuration sps,pps It's all the same , Just get it when you start the interface , You don't need to get it later .
How to get H264 What about parameters? ?
Solution :
1、 Set the video decoding parameter of the recording to H264

2、 Skip the file header after obtaining the video data :
3、 The back is SPS and PPS:
This will find the video parameters , And then it's packaged , Tell the server .
Reference resources :
I seem to have written an article about sps,pps, At that time, I was doing h264 Slice transmission .
About :
qq:9611153 WeChat lgs9611153
边栏推荐
- webUI自动化学习
- Postman--使用
- Mysql database remote access permission settings
- stm32和电机开发(上位系统)
- stm32和電機開發(上比特系統)
- 2021-09-12
- KS009基于SSH实现宠物管理系统
- Stm32 et développement de moteurs (système supérieur)
- Understand the composition of building energy-saving system
- [visual studio] visual studio 2019 community version cmake development environment installation (download | install relevant components | create compilation execution project | error handling)
猜你喜欢

allure--常用配置项

flink 提交程序

Sum the two numbers to find the target value

Pytest learning --base

对话吴纲:我为什么笃信“大国品牌”的崛起?

1287_FreeRTOS中prvTaskIsTaskSuspended()接口实现分析

Session cookies and tokens

Shutter - canvas custom graph

Use WinDbg to statically analyze dump files (summary of practical experience)

简洁、快速、节约内存的Excel处理工具EasyExcel
随机推荐
Sus system availability scale
Internet News: Tencent conference application market was officially launched; Soul went to Hong Kong to submit the listing application
flume 190 INSTALL
Use WinDbg to statically analyze dump files (summary of practical experience)
SUS系统可用性量表
Beautiful and intelligent, Haval H6 supreme+ makes Yuanxiao travel safer
01安装虚拟机
Importing tables from sqoop
4.随机变量
[visual studio] visual studio 2019 community version cmake development environment installation (download | install relevant components | create compilation execution project | error handling)
Nonlinear optimization: steepest descent method, Newton method, Gauss Newton method, Levenberg Marquardt method
MySQL数据库远程访问权限设置
合并有序数列
Understand the composition of building energy-saving system
AttributeError: type object ‘Image‘ has no attribute ‘fromarray‘
PCL 投影点云
(五)APA场景搭建之挡位控制设置
PCL Eigen介绍及简单使用
Kustomize user manual
UVM - usage of common TLM port