Janus源码分析(7)——videoroom分析

1. 运行效果

https://janus.conf.meetecho.com/videoroomtest.html?simulcast=true

包含:Simulcast功能

  • 视频高等质量(分辨率:1280*720,带宽1.5M+)
    在这里插入图片描述

  • 视频中等质量(分辨率:640*360,带宽500K左右)
    在这里插入图片描述

  • 视频低等质量(分辨率:320*180,带宽150K左右)
    在这里插入图片描述

2. VideoRoom插件API分析

2.1 会议配置信息及API分类

1、插件配置文件位置 conf/janus.plugin.videoroom.jcfg,会议配置格式如下:

room-<unique room ID>: {
    description = This is my awesome room
    is_private = true|false (private rooms don't appear when you do a 'list' request)
    secret = <optional password needed for manipulating (e.g. destroying) the room>
    pin = <optional password needed for joining the room>
    require_pvtid = true|false (whether subscriptions are required to provide a valid
                 a valid private_id to associate with a publisher, default=false)
    publishers = <max number of concurrent senders> (e.g., 6 for a video
                 conference or 1 for a webinar, default=3)
    bitrate = <max video bitrate for senders> (e.g., 128000)
    fir_freq = <send a FIR to publishers every fir_freq seconds> (0=disable)
    audiocodec = opus|g722|pcmu|pcma|isac32|isac16 (audio codec to force on publishers, default=opus
                can be a comma separated list in order of preference, e.g., opus,pcmu)
    videocodec = vp8|vp9|h264 (video codec to force on publishers, default=vp8
                can be a comma separated list in order of preference, e.g., vp9,vp8,h264)
    opus_fec = true|false (whether inband FEC must be negotiated; only works for Opus, default=false)
    video_svc = true|false (whether SVC support must be enabled; only works for VP9, default=false)
    audiolevel_ext = true|false (whether the ssrc-audio-level RTP extension must be
        negotiated/used or not for new publishers, default=true)
    audiolevel_event = true|false (whether to emit event to other users or not)
    audio_active_packets = 100 (number of packets with audio level, default=100, 2 seconds)
    audio_level_average = 25 (average value of audio level, 127=muted, 0='too loud', default=25)
    videoorient_ext = true|false (whether the video-orientation RTP extension must be
        negotiated/used or not for new publishers, default=true)
    playoutdelay_ext = true|false (whether the playout-delay RTP extension must be
        negotiated/used or not for new publishers, default=true)
    transport_wide_cc_ext = true|false (whether the transport wide CC RTP extension must be
        negotiated/used or not for new publishers, default=true)
    record = true|false (whether this room should be recorded, default=false)
    rec_dir = <folder where recordings should be stored, when enabled>
    notify_joining = true|false (optional, whether to notify all participants when a new
                participant joins the room. The Videoroom plugin by design only notifies
                new feeds (publishers), and enabling this may result extra notification
                traffic. This flag is particularly useful when enabled with \c require_pvtid
                for admin to manage listening only participants. default=false)
}

2、VideoRoom插件分3种类型API:会议、发布者、订阅者

2.2 会议API

在这里插入图片描述

2.3 会议发布者API

在这里插入图片描述

2.4 会议订阅者API

在这里插入图片描述

3. 主要API处理分析(待完善)

3.1 发布者join

3.2 发布者configure

3.3 发布者publish

3.4 发布者unpublish

3.5 订阅者join

3.6 订阅者start

3.7 订阅者configure

3.8 订阅者switch

4. 参考资料

  • 官网VideoRoom插件API文档
    https://janus.conf.meetecho.com/docs/videoroom.html在这里插入图片描述
  • 2
    点赞
  • 10
    收藏
    觉得还不错? 一键收藏
  • 5
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 5
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值