Open WebRTC Toolkit Client Windows SDK 文档

  • 来源
  • 在这里插入图片描述

Open WebRTC Toolkit Client Windows SDK Documentation

===============================

1 Introduction {#section1}

Open WebRTC Toolkit Client SDK for Windows provides the tools for developing Windows native WebRTC
applications using C++ APIs. This document describes all the APIs available in the SDK and how to use them.
This SDK is interoperable with Open WebRTC Toolkit Client SDK for JavaScript*, iOS* and Android*.
Refer to the Release Notes for the latest information in the SDK release package, including features,
bug fixes and known issues.
cpp 的api,由js ios android 的sdk

2 Supported platforms {#section2}

Open WebRTC Toolkit Client SDK for Windows supports Windows 7 and later versions.

3 Getting started {#section3}

Application on Open WebRTC Toolkit Client SDK for Windows should be built with Microsoft Visual Studio* 2017 or 2019. Running time library for linking should be Multi-threaded Debug (/MTd) for debug version or Multi-threaded (/MT) for release version. Supported platform is x64.
The release package includes one sample application to get you started quickly with the SDK. The following two static libraries are provided in the SDK for only x64, along with their headers:

  • owt-debug.lib - this library includes all the WebRTC features for debug usages.
  • owt-release.lib - this library includes all the WebRTC features for release usages.
    owt-debug.lib|owt-release references libraries in Windows SDK for DXVA support. Your application must statically link
    mfuuid.lib, mf.lib, mfplat.lib, d3d9.lib, dxgi.lib, d3d11.lib and dxva2.lib to build. Depending on your signaling
    channel implementation, you can optionally link sioclient.lib or sioclient_tls.lib if neccessary.
    需要由DXVA 支持
    d3d的支持
    sioclient 用于信令

4 Socket.IO {#section4}

Socket.IO cpp client is an open source project hosted on Github.
The Socket.IO TLS feature is determined at compile time and cannot be switched at runtime. If you are using secure
connections, link your application statically with sioclient_tls.lib; otherwise, link it with sioclient.lib. Please be noted the SDK library is linking to SSL1.1.0l, so sioclient_tls.lib must be compiled using the same SSL version.
tls是用于安全链接的

5 NAT and firewall traversal {#section5}

Open WebRTC Toolkit Client SDK for Windows fully supports NAT and firewall traversal with STUN / TURN / ICE. The Coturn TURN server from https://github.com/coturn/coturn can be one choice.
支持所有的nat类型和防火墙类型
通过 stun turn 和ice 技术。
coturn turn 服务器够用

6 Customize signaling channel {#section6}

Signaling channel is an implementation to transmit signaling data for creating a WebRTC session. Signaling channel
for P2P sessions can be customized by implementing P2PSignalingChannelInterface. A default
P2PSocketSignalingChannel implementation is provided in the sample, which works with PeerServer.
PeerClient implements P2PSignalingChannelInterfaceObserver and will be registered into signaling channel, so you
can invoke its methods to notify PeerClient during your customized signaling channel implementation when a new
message is coming or connection is lost.
定制信令channel
信令channel是通过创建一个webrtc的session 传递信令数据的。
信令channel用于p2p 会话时,你需要自己实现p2psignalingchannelinterface
默认的p2psocketsignalingchannel实现在例子里,与peerserver搭配。
peerclient 实现了p2psignalingchannelinterfaceobserver 并且注册到信令channel中。所以当一个消息来或者链接丢失后,你定制信令channel的实现的时候,可以调用里面的方法通知peerclient

7 Video codecs {#section7}

For the decoder, if hardware acceleration is not enabled, only VP8/VP9 is supported. If hardware acceleration is enabled, VP8,
VP9, H.264 and HEVC are supported, but it will fallback to VP8 software decoder if GPU does not supports VP8 hardware decoding.
Most of the 5th/6th/7th/8th Generation Intel® Core™ Processor platforms support VP8 hardware decoding, refer to their specific documentation for details.
Starting from 6th Generation Intel® Core™ Processor platforms, hardware encoding and decoding of HEVC is supported.
You can turn off video encoding/decoding hardware acceleration via {@link owt.base.GlobalConfiguration GlobalConfiguration} API,
by passing “false” to SetVideoHardwareAccelerationEnabled API before creating conferenceclient or peerclient.
解码器,如果硬件加速不支持,那么仅仅支持vp8和vp9
如果硬件加速支持,那么vp9 vp9 h264 和hevc都支持,
如果gpu不支持vp8硬解码,那么会变为vp8 软解码。
大多数的intel 处理器都支持vp8 硬解码。
第六代的core开始,硬件编解码的hevc都支持。
通过owt.base.GlobalConfiguration GlobalConfiguration,传递一个SetVideoHardwareAccelerationEnabled 为false,来关闭视频的硬件编解码。

8 Publish streams with customized frames {#section8}

Customized video frames can be I420 frame from yuv file, or encoded H.264/VP8/VP9/HEVC frames.
定制的视频帧是i420的,来自于yuv。或者来自于编码后的h264 vp8 vp9 hevc 帧。
For raw YUV frame input, the customized video frame provider needs to implement its own frame generator extending from
{@link owt.base.VideoFrameGeneratorInterface VideoFrameGeneratorInterface}, which generates customized frames as our sample code and feeds the frame generator to
{@link owt.base.LocalCustomizedStream LocalCustomizedStream} for stream publishing.
对于raw 的yuv帧的输入,定制化的视频帧provider需要实现自己的帧生产器,即扩展 owt base videoframe generator ,这个类是产生定制化的帧,就像我们例子代码做的那样,然后喂给帧产生器 送到 owt base local ustomized stream 的本地定制化流 用于流的发布。
For encoded frame input, application is required to implement the customized encoder that inherits
{@link owt.base.VideoEncoderInterface VideoEncoderInterface}, and is required to pass an AU to SDK according to the frame type requested per
{@link owt.base.VideoEncoderInterface.EncodeOneFrame EncodeOneFrame} call.
对于编码后的帧输入,app 要求实现定制化的编码器,继承video encoder interface 的videoencoderinterface 即可。并且要求在每次 owt base video encoder interface 的encodeoneframe 调用时,根据帧的类型,传递一个AU 到 SDK,
Customized audio frames provider should implement {@link owt.base.AudioFrameGeneratorInterface AudioFrameGeneratorInterface}. Currently, 16-bit little-endian PCM is supported. Please use {@link owt.base.GlobalConfiguration.SetCustomizedAudioInputEnabled GlobalConfiguration.SetCustomizedAudioInputEnabled} to enable customized audio input.
定制化的音频帧产生器 需要实现 audioframegeneratorinterface 。一般来说,16位的 小端pcm 是都支持的。
需要设置全局配置。设置定制化的音频输入 激活位true来定制化 音频输入。

9 Known issues {#section9}

Here is a list of known issues:

  • Conference recording from Windows SDK is not supported.
  • If you create multiple LocalCameraStreams with different resolutions, previous streams will be black.
  • 不支持windows端的会议录制。
  • 如果以不同的分辨率创建多个本地camera流,前面的流会黑

10 Privacy and security {#section10}

SDK will send operation system’s name and version, libwebrtc version and abilities, SDK name and version to conference server and P2P endpoints it tries to make connection. SDK does not store this information on disk.

Note: * Other names and brands may be claimed as the property of others.

SDK 会发送os的名字和版本,libwebrtc的版本和能力,sdk的名字和版本给 会议服务器,p2p端点会尝试创建连接。SDK不会在disk存储这些信息。

发布了664 篇原创文章 · 获赞 55 · 访问量 217万+

猜你喜欢

转载自blog.csdn.net/commshare/article/details/104012825
今日推荐