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 🙏

© 2024 – Pkg Stats / Ryan Hefner

cbim-render-sdk

v1.5.85

Published

渲染SDK

Downloads

174

Readme

渲染SDK

npm i cbim-render-sdk -S
import RenderViewer from 'cbim-render-sdk'

const renderViewer = new RenderViewer('container', {
    api: '/raas',
    itemVersionId: '5253'
}, (responseData) => {
    // recive data from engine
})

参数说明

OptionConfig 引擎参数

| 属性 | 说明 | 类型 | 默认值 | 备注 | 必填 | | :--- | :--- | :---: | :---: | :--- | :---: | |itemVersionId|模型id|Number|-|-|是| |api|引擎服务接口前缀|String|"/raas"|若为内网环境,则此处为内网后端服务地址|否| |env|图形服务分支|String|"/data/autoDeploy/bin/Release/test"|若为内网环境,则此处为内网后端服务地址|否| |webrtc|是否使用webrtc模式|Boolean|true|webrtc开启为视频流模式,关闭则为图片流模式。私有化部署需要关闭|否| |innerNet|内网环境|Boolean|false|-|否| |host|服务器IP|String|-|用于指定服务器|否| |webSocketUrl|固定websocket地址|String|-|用于测试或固定展示模型|否| |configPath|指定配置文件地址|String|-|用于指定图形引擎配置文件|否| |iceServers|RTC ice服务器列表|Array|-|-|否| |exclusive|RTC独占模式|Boolean|false|独占模式,引导到专用服务器|否| |touristTicket|游客令牌|String|-|用于游客免登录访问|否| |customLoading|自定义加载动画|Boolean|false|-|否| |loadingSrc|加载动画(图片)地址|String|"/static/image/loading.png"|-|否| |headers|可用于同一浏览器开启同一模型多个实例|Object|-|设置如下:{'ANO-SID': '区分连接不同实例,值为:数字或者小写字母以及组合。eg: 123'}|否| |measure|设置测量参数|MeasureConfig|-|例: { drawMethod: 'svg', adsorbentRadius: 20}|否| |wasmDecode|是否开启前端解码|wasmDecode|-|例: { enable: true, wasmUrl: 'http://localhost.ren.cbim.org.cn/render_static/lib/Broadway/avc.wasm' }。开启时需要在wasmUrl字段传入sdk提供的解码器wasm文件访问全路径。此文件位于在sdk程序包/lib/wasmDecoder/avc.wasm。使用前请确保将其放置在客户端服务器静态文件夹下,|否|

MeasureConfig 测量参数

| 属性 | 说明 | 类型 | 默认值 | 备注 | 必填 | | :--- | :--- | :---: | :---: | :--- | :---: | |drawMethod|设置测量绘制方式|String|'svg'|可选值: 'svg'、'canvas'|否| |adsorbentRadius|设置测量吸附半径|Number|-|-|否|