82 Star 396 Fork 151

Kay / pano

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

(作者比较懒,该文档已长期未更新,请暂时无视接口列表 23333)

项目描述

全景图Demo(包添功能有:根据已有空间创建场景;增、删、改空间中的热点,修改空间底部logo,兼容移动端浏览,横屏VR模式)

ps:仅供学习参考,很多接口并不完善,后台也有不少bug,欢迎fork。换工作中,近期并不打算维护,抱歉23333

运行

视频预览

  1. 场景切换
  2. 材质切换
  3. 编辑热点

panorama.js插件接口列表:

1. 初始化参数

属性名 类型 说明 默认值
container DOM document.body 场景显示的容器,必须是非static
smoothStart boolean false 是否平滑进入
autoPlay boolean false 是否自动播放
autoRotate boolean false 是否自动旋转
logoUrl string 场景logo
hotImg string /pano/static/panorama/img/foot_step.png 热点图片
debug boolean false 进入编辑模式
fps boolean false 显示帧速

2. 实例属性

属性名 类型 说明
stage DOM 添加到容器下的canvas标签 r
spaceCount number 场景中的空间数量 r
spacesDict json对象 空间字典 r
spaceId string 当前显示的空间编号 r
stereoMode boolean VR模式 r / w
walkMode boolean 步行模式 r / w
addingHot boolean 选择热点模式 r / w
lockScene boolean 锁定场景 r / w

3. 实例方法

方法名 概述
play 播放场景
showSpace 切换场景

4. 事件

事件名 概述
onOverHot 选择器在热点上移动时
onLeaveHot 选择器离开热点时
onAddingHot 添加热点时点击container的回调
onLoad 首屏加载完毕
onShowing 下一个场景载入中
onShown 场景切换完毕
onHotAdd 热点添加前

接口描述

play

  • 播放场景

showSpace

  • 切换场景
  • 参数
MIT License Copyright (c) 2022 Kay Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

基于webgl(threejs)技术的室内街景 / 全景图 demo,前后端(python)完整实现,功能主要包括:添加、编辑热点,材质切换,修改logo,移动端浏览、VR模式。 展开 收起
Python 等 4 种语言
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
Python
1
https://gitee.com/kaysama/pano.git
git@gitee.com:kaysama/pano.git
kaysama
pano
pano
master

搜索帮助