npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

ue-live-audio-container

v1.1.0

Published

ue-live-audio-container

Readme

BIM图形使用说明

安装:

npm install ue-live-audio-container

使用方法:`

import * as bimer from 'LiveRTCClientContainer'

组件参数传递:
<LiveRTCClientContainer liveRTCData={{ liveRTCData }} />
> ````
参数传入

viewToken 调用后台接口获取, *号为必传参数, 否则会报错

  const liveRTCData =  {
    mode: 'live',
    sdkAppId: 1400635722,
    userId: '12345',
    userSig: 'eJwtzMEKgkAUheF3mXXodcY7DUILCRKjXS4q3FgzyUWmRjMVonfP1OX5Dvwflh2OXmcaFjHuAVtNm7R5tHSniQMuQlyOl64K50izKAgBpMA15-NjBkeNGR0ROQDM2pL9m5TAhRBKLRUqx*7*XIfVhegal6cksXGa*7J-Z4qszf1b7gfbpu6eg0DcpUW-Yd8fNRwxcQ__',
    roomId: 12345, //用后台生成的
    role: 'anchor', //角色:用户角色 anchor:主播,audience:观众
    player: 'adviser', // 主播要用adviser,观众用:user
    audio: true, //固定 true
    video: false, //固定false
    projectName:"liveRTC"
  };
模型加载状态:

userSig: 请求后台接口,获取用户sig (https://3d.vanke.com/api/vbim-ue4-server/trtc/getUserSig)

组件初始化后,全局对象是:await window.liveTRTCClient

ps: 1)如果用户是主播,那默认打开了语音讲话功能,可以看到浏览器有红色的icon,手机上有语音icon 2)如果用户是观众,那用户进来,只能听主播讲话

模型API调用:

组件初始化后,全局对象是:await window.liveTRTCClient

API

观众要进行语音上麦

await window.liveTRTCClient.switchRole(“anchor”) //设成主播,才可以上麦

设置本地流:

await window.liveTRTCClient.localStreamInit()

发布本地流

await window.liveTRTCClient.publishLocalStream() 执行完:1,2,3步骤后,观众上麦成功,可以进行讲话

离开直播间:

await window.liveTRTCClient.leave()

主播或观众进行静音:

await window.liveTRTCClient.audioMute(true) //true:表示静音,false 表示非静音

获取谁在讲话中:

api: websocket sendWSPush({ type: 'liveAudio', userId: userId, audioVolume: audioVolume });