1 Star 3 Fork 2

cedar12 / tezero

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

介绍

基于threejs

  • 支持快捷键
  • 支持自定义物体组件
  • 支持拖动添加物体组件到场景中
  • 内置场景大纲视图
  • 支持.dae.fbx.glb.gltf等模型导入

安装

通过 yarn

yarn add git+https://gitee.com/cedar12/tezero.git

通过 npm

npm install git+https://gitee.com/cedar12/tezero.git

使用

浏览器

<div id="container"></div>
<script>
// 实例化编辑器核心
const tz = new Tezero(document.getElementBy('container'));
</script>

内置编辑器布局

需要引入样式tezero/dist/style.css

// 实例化编辑器
const tl=new TezeroLayout(document.querySelector('#container'),/*物体组件数据*/,{theme:'light'});
// 编辑器核心
const tz=tl.tezero;

Vue3

<template>
<div id="container"></div>
</template>
<script setup>
import {ref,onMounted} from 'vue';
import {Tezero} from 'tezero';

const containerRef=ref(null);
onMounted(()=>{
  // 实例化编辑器核心 用于自定义编辑器布局
  const tz = new Tezero(containerRef.value);
})
</script>

快捷键

说明
Ctrl + c 复制选中物体
Ctrl + v 粘贴物体
Ctrl + z 撤销
Ctrl + y 重做
T 切换到移动物体模式
S 切换到缩放物体模式
R 切换到旋转物体模式
Delete Backspace

预览

image.png

MIT License Copyright (c) 2023 cedar12 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.

简介

tezero是一个可以使用非常简单的方式调用并实例化三维组态编辑器 展开 收起
TypeScript 等 3 种语言
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
TypeScript
1
https://gitee.com/cedar12/tezero.git
git@gitee.com:cedar12/tezero.git
cedar12
tezero
tezero
master

搜索帮助

344bd9b3 5694891 D2dac590 5694891