当前位置:网站首页>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
边栏推荐
- PCL之滤波
- 2021-09-12
- [Fantasy 4] the transformation from U3D to UE4
- Postman--使用
- [unity3d] nested use layout group to make scroll view with dynamic sub object height
- [pit avoidance guide] pit encountered using ugui: the text component cannot indent the first line by two spaces
- Pytest learning --base
- PCL 点云转深度图像
- Beautiful and intelligent, Haval H6 supreme+ makes Yuanxiao travel safer
- 高考的意义是什么
猜你喜欢

(五)APA场景搭建之挡位控制设置

Operator-1 first acquaintance with operator

Basic usage of mock server

从MediaRecord录像中读取H264参数
![[Fantasy 4] introduction and use of UMG components (under update...)](/img/33/7e3b74192b7fd73d5145f85e061d1f.png)
[Fantasy 4] introduction and use of UMG components (under update...)
![[unity3d] nested use layout group to make scroll view with dynamic sub object height](/img/b2/edab4ab48e1401934dcce7218df662.png)
[unity3d] nested use layout group to make scroll view with dynamic sub object height

shell编程01_Shell基础

使用sqlcipher打开加密的sqlite方法

Postman -- use

Mongodb quickly get started with some simple operations of mongodb command line
随机推荐
[TS] 1368 seconds understand typescript generic tool types!
面对不确定性,供应链的作用
UVM learning - build a simple UVM verification platform
传输优化抽象
UVM factory mechanism
Test -- Summary of interview questions
Retrofit's callback hell is really vulnerable in kotlin synergy mode!
01安装虚拟机
02-taildir source
《MySQL 8 DBA基础教程》简介
ERROR 1118 (42000): Row size too large (> 8126)
[tutorial] how to make the Helpviewer help document of VisualStudio run independently
MYSQL关键字
测试--面试题总结
Pywin32 opens the specified window
VLAN experiment
1287_ Implementation analysis of prvtaskistasksuspended() interface in FreeRTOS
PCL Eigen介绍及简单使用
MPLS experiment
[unity3d] nested use layout group to make scroll view with dynamic sub object height