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

@rtzh/engine

v0.0.11

Published

CesiumJS is a JavaScript library for creating 3D globes and 2D maps in a web browser without a plugin.

Readme

@rtzh/engine

⚠️ 本项目是基于 CesiumJS 的 @cesium/engine 22.1.0 包修改而来的定制版本。

原始项目来源:CesiumGS/cesium

License

Apache 2.0. CesiumJS is free for both commercial and non-commercial use.

变更日志

功能新增(Features)

模型及3D图块线框显示功能

  • Model 类中新增 showWireframehideWireframetoggleWireframe 方法,实现模型的线框渲染切换
  • Cesium3DTileset 类中新增对应的线框显示方法,支持对整个3D图块集切换线框模式
  • 支持设置线框颜色及颜色混合模式
  • 支持链式调用以方便设置和切换线框状态
  • 对WebGL1环境添加提示,需启用 enableDebugWireframe 才能生效

基于重心坐标的线框调试模式支持

  • ModelCesium3DTileset 中新增 debugWireframeMode 属性,支持 "lines""barycentric" 两种模式切换
  • 新增 debugWireframeColordebugWireframeFillAlphadebugWireframeLineWidthdebugWireframeOverlay 属性,丰富线框渲染配置
  • 实现基于重心坐标的线框渲染管线,添加 BarycentricWireframePipelineStage
  • 修改顶点着色器(ModelVS.glsl)和片段着色器(ModelFS.glsl)以支持重心线框效果及叠加选项
  • WireframePipelineStage 中增加对 barycentric 模式的跳过逻辑,避免重复渲染和冲突
  • Model3DTileContent 中同步新线框调试属性,保证瓦片模型线框一致性
  • 兼容WebGL1和WebGL2环境,lines模式需启用 enableDebugWireframe,barycentric模式无需

线框扫描线和发光效果支持

  • ModelCesium3DTileset 中添加 effects 参数支持扫描线和发光配置
  • 实现扫描线方向、速度和发光强度的计算逻辑
  • 根据扫描线方向计算扫描范围和模型高度范围
  • Model3DTileContent 中传递相关有线框效果参数
  • 修改片段着色器(ModelFS.glsl)添加扫描线高亮和发光效果的计算与混合
  • 修改顶点着色器(ModelVS.glsl)传递模型世界坐标,支持扫描线效果

点光源照明支持

  • 新增 PointLight 类描述点光源属性及构造方法
  • Scene 中添加点光数组以支持额外光照
  • UniformState 中添加点光相关状态及自动uniform支持
  • LightingPipelineStage 新增点光相关宏定义和光照计算逻辑
  • Model 增加点光变化检测并触发绘制命令重建
  • 实现点光位置、颜色及范围等数据上传至GPU uniform数组
  • 维护点光数量限制为8并确保对应uniform数组长度匹配
  • 优化点光范围衰减和平滑过渡计算保障渲染效果
  • AutomaticUniforms.js 中新增自动uniform以支持点光源数据传递到GLSL着色器
  • LightingStageFS.glsl 中实现点光源光照计算代码,支持范围衰减和距离衰减
  • FrameState 中新增 pointLights 字段以传递点光源信息

Bug修复(Fixes)

  • 优化 Model 的调试线框属性设置逻辑
    • 修正 debugWireframeColor 赋值时避免无效克隆和重复设置
    • 添加 debugWireframeFillAlpha 赋值的重复值检测以减少无谓重绘
    • Model3DTileContent 中仅当 debugWireframe 开启时赋值相关调试线框属性
    • 移除未启用 debugWireframe 时对 model.color 的无效赋值
    • 统一默认的 _debugWireframeScanAxisCartesian3(0, 0, 1) 实例

重构(Refactors)

  • 优化多个模块的代码结构和逻辑
  • 修正 Model 加载中 Feature ID 属性的类名称
  • 移除调试扫描线相关的多余高度变量和优化着色器逻辑