一、Miracast结构体
二、miracast涉及:wifi P2P(TDLS和Infrastructure是可选的)、DHCP、RTSP、RTP、UIBC、HDCP、A/V解码、A/V播放、Remote I2C R/W
三、WFD Source、WFD Sink
简单来说WFD Source就是提供AV stream、接收uibc数据的一端
WFD Sink分为两种,一种是Primary Sink(可以接受Audio和Video流,Video是必须要支持的,Audio是可选的),一种是Secondary Sink(只接收Audio流),我们做的是Primary Sink,可以接收Audio和Video流。
四、WFD Session
1、目前我们使用的是wifi P2P,拓扑结构如下:
如果chip支持concurrent,则可能连接miracast的同时还连接AP,如图所示:
2、wifi P2P具体参考wifi P2P协议,我们是直接使用的wpa_supplicant来实现P2P的连接
3、Sink端Audio/Video支持的格式(我们只是R1,所以下面的表格是R1 device支持的)
Audio/Video | |||||
Audio | Format type | Sampling rate (ksps) | Bits per sample | Supported number of channels | Mandatory/Optional |
LPCM | 48ksps | 16bits per sample | 2 channels | M | |
LPCM | 44.1ksps | 16bits per sample | 2 channels | O | |
AAC-LC | 48ksps | 16bits per sample | 2 channels | O | |
AAC-LC | 48ksps | 16bits per sample | 4 channels | O | |
AAC-LC | 48ksps | 16bits per sample | 6 channels | O | |
AAC-LC | 48ksps | 16bits per sample | 8 channels | O | |
AC-34 | 8ksps | 16bits per sample | 2 channels | O | |
AC-34 | 8ksps | 16bits per sample | 4 channels | O | |
AC-34 | 8ksps | 16bits per sample | 6 channels | O | |
Video(H.264) | Profiles | Mandatory/Optional | Tools | ||
CBP | M | I and P Slices | |||
In-Loop Deblocking Filter | |||||
CAVLC Entropy Coding | |||||
4:2:0 Chroma Format | |||||
8 Bit Sample Depth | |||||
RHP | O | I and P Slices | |||
Multiple Reference Frames | |||||
In-Loop Deblocking Filter | |||||
CAVLC Entropy Coding | |||||
Interlaced Coding (PicAFF, MBAFF) | |||||
4:2:0 Chroma Format | |||||
Monochrome Video Format (4:0:0) | |||||
8 Bit Sample Depth | |||||
8x8 vs. 4x4 Transform Adaptivity | |||||
Quantization Scaling Matrices | |||||
Separate Cb and Cr QP control | |||||
Resolution | Frames/Fields per second, (i) interlaced or (p) progressive | Description | Required minimum H.264 Level | ||
640x480 | p60 | Standard Definition, CEA format. | 3.1 | ||
720x480 | p60 | Standard Definition, CEA format. | 3.1 | ||
720x480 | i60 | Standard Definition, CEA format. | 3.1 | ||
720x576 | p50 | Standard Definition, CEA format. | 3.1 | ||
720x576 | i50 | Standard Definition, CEA format. | 3.1 | ||
1280x720 | p30 | High Definition, CEA format. | 3.1 | ||
1280x720 | p60 | High Definition, CEA format. | 3.2 | ||
1920x1080 | p30 | High Definition, CEA format. | 4 | ||
1920x1080 | p60 | High Definition, CEA format. | 4.2 | ||
1920x1080 | i60 | High Definition, CEA format. | 4 | ||
1280x720 | p25 | High Definition, CEA format. | 3.1 | ||
1280x720 | p50 | High Definition, CEA format. | 3.2 | ||
1920x1080 | p25 | High Definition, CEA format. | 3.2 | ||
1920x1080 | p50 | High Definition, CEA format. | 4.2 | ||
1920x1080 | i50 | High Definition, CEA format. | 3.2 | ||
1280x720 | p24 | High Definition, CEA format. | 3.1 | ||
1920x1080 | p24 | High Definition, CEA format. | 3.2 | ||
800x600 | p30 | SVGA; VESA format. | 3.1 | ||
800x600 | p60 | SVGA; VESA format. | 3.2 | ||
1024x768 | p30 | XGA; VESA format. | 3.1 | ||
1024x768 | p60 | XGA; VESA format. | 3.2 | ||
1152x864 | p30 | XGA+; VESA format. | 3.2 | ||
1152x864 | p60 | XGA+; VESA format. | 4 | ||
1280x768 | p30 | WXGA; VESA format. | 3.2 | ||
1280x768 | p60 | WXGA; VESA format. | 4 | ||
1280x800 | p30 | WXGA; VESA format. | 3.2 | ||
1280x800 | p60 | WXGA; VESA format. | 4 | ||
1360x768 | p30 | WXGA; VESA format. | 3.2 | ||
1360x768 | p60 | WXGA; VESA format. | 4 | ||
1366x768 | p30 | WXGA; VESA format. | 3.2 | ||
1366x768 | p60 | WXGA; VESA format. | 4.2 | ||
1280x1024 | p30 | SXGA (17” and 19” LCD); VESA format. | 3.2 | ||
1280x1024 | p60 | SXGA (17” and 19” LCD); VESA format. | 4.2 | ||
1400x1050 | p30 | SXGA+ (14” and 15” PC); VESA format. | 3.2 | ||
1400x1050 | p60 | SXGA+ (14” and 15” PC); VESA format. | 4.2 | ||
1440x900 | p30 | WXGA+ (19” LCD); VESA format. | 3.2 | ||
1440x900 | p60 | WXGA+ (19” LCD); VESA format. | 4.2 | ||
1600x900 | p30 | VESA format. | 3.2 | ||
1600x900 | p60 | VESA format. | 4.2 | ||
1600x1200 | p30 | UXGA (20” LCD); VESA format. | 4 | ||
1600x1200 | p60 | UXGA (20” LCD); VESA format. | 4.2 | ||
1680x1024 | p30 | WSXGA (19” LCD); VESA format. | 3.2 | ||
1680x1024 | p60 | WSXGA (19” LCD); VESA format. | 4.2 | ||
1680x1050 | p30 | SXGA (22” LCD); VESA format. | 3.2 | ||
1680x1050 | p60 | SXGA (22” LCD); VESA format. | 4.2 | ||
1920x1200 | p30 | WUXGA; VESA format. | 4.2 | ||
800x480 | p30 | Handheld devices | 3.1 | ||
800x480 | p60 | Handheld devices | 3.1 | ||
854x480 | p30 | Handheld devices | 3.1 | ||
854x480 | p60 | Handheld devices | 3.1 | ||
864x480 | p30 | Handheld devices | 3.1 | ||
864x480 | p60 | Handheld devices | 3.1 | ||
640x360 | p30 | Handheld devices | 3.1 | ||
640x360 | p60 | Handheld devices | 3.1 | ||
960x540 | p30 | Handheld devices | 3.1 | ||
960x540 | p60 | Handheld devices | 3.1 | ||
848x480 | p30 | Handheld devices | 3.1 | ||
848x480 | p60 | Handheld devices | 3.1 |