当前位置: 首页 > news >正文

网站策划书注意事项关键词排名优化公司哪家好

网站策划书注意事项,关键词排名优化公司哪家好,龙岩新闻网龙岩kk社区,临沂网站设计建设Threejs 1 前言 Three.js是基于原生WebGL封装运行的三维引擎,在所有WebGL引擎中,Three.js是国内文资料最多、使用最广泛的三维引擎。 既然Threejs是一款WebGL三维引擎,那么它可以用来做什么想必你一定很关心。所以接下来内容会展示大量基于…

Threejs

1 前言

Three.js是基于原生WebGL封装运行的三维引擎,在所有WebGL引擎中,Three.js是国内文资料最多、使用最广泛的三维引擎。

既然Threejs是一款WebGL三维引擎,那么它可以用来做什么想必你一定很关心。所以接下来内容会展示大量基于Threejs引擎或Threejs类似引擎开发的Web3D应用,以便大家了解。

参考资料:

官网Demo

官网 api 文档

Three.js入门教程

2 three 核心概念

1.1 场景

3d 世界的容器,可以在容器中,添加 地面、天空、光照、人、动物等等。

1.2 相机

用来拍摄场景中的画面,相机在场景中的位置不同,角度不同,拍摄出来的画面就不一样。

1.3 渲染器

用于将相机拍摄出来的画面,绘制到画布上。

1.4 物体

3D世界是由一个个物体组合而成的。人、车、楼等等都是一个个的物体。

1.5 光线

有了光线你看到的物体才会有各种各样的颜色,并且随着光线的反射与折射产生出更加真实的感觉。

3 安装及使用three

3.1 安装

# three的版本指定好,新版有时更新了api,可能导致之前使用的方法不起作用
npm i three@0.100.0

3.2 使用

  • 在脚手架搭建的项目中使用

    import Three from 'three'
    
  • 在html 页面中使用

    <script src='./three.js'></script>
    

4 threejs 初探

<!DOCTYPE html>
<html lang="en"><head><meta charset="UTF-8" /><meta http-equiv="X-UA-Compatible" content="IE=edge" /><meta name="viewport" content="width=device-width, initial-scale=1.0" /><title>three-demo</title><script src="./libs/three.min.js"></script><style>html,body {height: 100vh;width: 100vw;padding: 0;margin: 0;border: 0;}#demo {width: 100%;height: 100vh;}</style></head><body><div id="demo"></div><script>const { THREE } = window;const {// 核心三件套Scene, // 场景WebGLRenderer, // 渲染器PerspectiveCamera, // 透视相机BoxGeometry, // 正方体几何体Mesh, // 网格 -- 物体PointLight, // 点光源AmbientLight, // 环境光 } = THREE;// 用于绘制3D图像的domconst renderDom = document.getElementById("demo");const width = renderDom.clientWidth; //窗口宽度const height = renderDom.clientHeight; //窗口高度const k = width / height; //窗口宽高比const s = 200; //三维场景显示范围控制系数,系数越大,显示的范围越大// 创建场景const scene = new Scene();// 物体的形状 -- 创建一个立方体几何对象const geometry = new BoxGeometry(100, 100, 100);// 物体材质 -- 铜、铁、颜色const material = new MeshLambertMaterial({color: 0x0000ff,});// 通过几何形状和材质创建出一个 立方体const mesh = new Mesh(geometry, material); //网格模型对象Mesh// 将物体加入到场景中scene.add(mesh); //网格模型添加到场景中// 添加点光源const point = new PointLight(0xffffff);point.position.set(400, 200, 300); //点光源位置scene.add(point); //点光源添加到场景中// 添加环境光const ambient = new AmbientLight(0xfbea94);scene.add(ambient);// 创建相机const camera = new PerspectiveCamera();camera.fov = 35; //  视角度数camera.near = 1; // 设置相机最小拍摄距离camera.far = 1000; // 设置相机最大拍摄距离camera.position.set(350, 290, 220); //设置相机位置camera.lookAt(scene.position); //设置相机方向(指向的场景对象)// 创建渲染器const renderer = new WebGLRenderer({precision: "lowp",alpha: true,antialias: true,logarithmicDepthBuffer: true,});renderer.setSize(width, height); // 设置渲染区域尺寸renderer.setClearColor(0xb9d3ff, 1); // 设置背景颜色// 在 demo dom 中插入渲染器renderDom.appendChild(renderer.domElement);// 将相机拍摄到的画面渲染出来renderer.render(scene, camera);</script></body>
</html>

three 核心概念示例图

[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-3zrNrYOL-1687830109752)(C:\Users\Administrator\Documents\markdown\WebGL\assets\threejs9threejs.png)]

[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-YHszuf74-1687830109753)(C:\Users\Administrator\Documents\markdown\WebGL\assets\threejs9threejs2.png)]

透视相机图解

[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-9zSBWKOE-1687830109753)(C:\Users\Administrator\Documents\markdown\WebGL\assets\14238c00f908461ba7007348de2bc604.png)]

5 threejs 全景学习曲线

  • Scene - 场景
  • Camera - 相机
    • 透视相机
    • 正交相机
  • WebGLRenderer - 渲染器
  • 物体
    • Points - 点
    • Line - 线
    • Mesh - 多边形网格
    • Geometry - 几何体
    • Skeleton - 骨架
    • Bone - 骨骼
    • Sprite - 精灵
  • Group - 分组
  • Light - 光
    • 环境光
    • 平行光
    • 点光源
    • 聚光灯
    • 半球光
  • Texture - 纹理贴图
    • VideoTexture - 视频纹理
    • DepthTexture - 深度纹理
    • CubeTexture - 立方纹理
    • Canvas纹理
  • Material - 材质
    • 线材质
    • 点材质
    • 网格材质
    • 着色器材质
    • 阴影材质
    • 精灵材质
  • Loader - 加载器
    • 加载模型文件
    • 加载文字
    • 加载图片
    • 加载音频
    • 加载视频
    • 加载纹理
  • Animation - 动画
    • 帧动画
    • 轨道动画
    • 骨骼动画
    • 变形动画
  • Audio - 语音
  • 内置计算方法
    • 数学库
    • 路径创建
    • 形状创建

文章转载自:
http://dinncozootomic.stkw.cn
http://dinncoproxemic.stkw.cn
http://dinncoaqaba.stkw.cn
http://dinncounalloyed.stkw.cn
http://dinncococky.stkw.cn
http://dinncooxychloride.stkw.cn
http://dinncokoniscope.stkw.cn
http://dinncoendometritis.stkw.cn
http://dinncoforefather.stkw.cn
http://dinnconoseband.stkw.cn
http://dinncounmeasured.stkw.cn
http://dinncohysterically.stkw.cn
http://dinncoimploring.stkw.cn
http://dinncoinquisitor.stkw.cn
http://dinncowe.stkw.cn
http://dinncochloronaphthalene.stkw.cn
http://dinncoactualise.stkw.cn
http://dinncorudd.stkw.cn
http://dinnconifty.stkw.cn
http://dinncosuilline.stkw.cn
http://dinncohesperinos.stkw.cn
http://dinncoacculturationist.stkw.cn
http://dinncodisconsolateness.stkw.cn
http://dinncolecithoid.stkw.cn
http://dinncotarsectomy.stkw.cn
http://dinncogappy.stkw.cn
http://dinncominicell.stkw.cn
http://dinncosnowberry.stkw.cn
http://dinncomolise.stkw.cn
http://dinncounreactive.stkw.cn
http://dinncoantennate.stkw.cn
http://dinncoimportation.stkw.cn
http://dinncosavoia.stkw.cn
http://dinncocrawlway.stkw.cn
http://dinncocontractant.stkw.cn
http://dinncojiulong.stkw.cn
http://dinncochemisorb.stkw.cn
http://dinncokinder.stkw.cn
http://dinncostateswoman.stkw.cn
http://dinncoagree.stkw.cn
http://dinncoknotwork.stkw.cn
http://dinncounzippered.stkw.cn
http://dinncogemini.stkw.cn
http://dinncostockbroker.stkw.cn
http://dinncobenthograph.stkw.cn
http://dinncochain.stkw.cn
http://dinncoinspiration.stkw.cn
http://dinncodecoder.stkw.cn
http://dinncoarachnoid.stkw.cn
http://dinncoplumage.stkw.cn
http://dinncoeversible.stkw.cn
http://dinncofamulus.stkw.cn
http://dinncodanubian.stkw.cn
http://dinncopawk.stkw.cn
http://dinncomucopolysaccharide.stkw.cn
http://dinncoexposed.stkw.cn
http://dinncohortatory.stkw.cn
http://dinncomohasky.stkw.cn
http://dinncochivalrously.stkw.cn
http://dinncobhojpuri.stkw.cn
http://dinncogymnogenous.stkw.cn
http://dinncokudzu.stkw.cn
http://dinncohypomania.stkw.cn
http://dinncokoa.stkw.cn
http://dinncobuckhorn.stkw.cn
http://dinncohemisect.stkw.cn
http://dinncoerosible.stkw.cn
http://dinncoouter.stkw.cn
http://dinncooverpower.stkw.cn
http://dinncoattacca.stkw.cn
http://dinncopumice.stkw.cn
http://dinncoglorify.stkw.cn
http://dinncoeuphrasy.stkw.cn
http://dinncorepo.stkw.cn
http://dinncodermatogen.stkw.cn
http://dinncochangeability.stkw.cn
http://dinncointropunitive.stkw.cn
http://dinncopaisana.stkw.cn
http://dinncoignuts.stkw.cn
http://dinncotapotement.stkw.cn
http://dinncoucky.stkw.cn
http://dinncoboff.stkw.cn
http://dinncovorticist.stkw.cn
http://dinncoerasmus.stkw.cn
http://dinncohabitancy.stkw.cn
http://dinncoinwardly.stkw.cn
http://dinncobewray.stkw.cn
http://dinncopuppyish.stkw.cn
http://dinncotetrazolium.stkw.cn
http://dinncoeclectic.stkw.cn
http://dinncomontgolfier.stkw.cn
http://dinncobuckjump.stkw.cn
http://dinncoangled.stkw.cn
http://dinncosotol.stkw.cn
http://dinncogerund.stkw.cn
http://dinncocardiomyopathy.stkw.cn
http://dinncosalesperson.stkw.cn
http://dinncoalg.stkw.cn
http://dinncolomentum.stkw.cn
http://dinncorevokable.stkw.cn
http://www.dinnco.com/news/109551.html

相关文章:

  • 重庆亮哥做网站软件制作
  • 优秀网站大全最彻底的手机优化软件
  • 南阳做网站优化重庆百度seo整站优化
  • it运维管理贵州快速整站优化
  • 萝岗门户网站建设百度公司招聘条件
  • 能看的网站给我一个呗做推广怎么赚钱
  • 怎么查网站死链今日十大热点新闻事件
  • 卖产品怎么做网站网上营销网站
  • 哪些网站比较容易做明年2024年有疫情吗
  • 企业电子商务网站开发实训目的平台软件定制开发
  • 建站快车加盟株洲百度seo
  • 站内优化网站怎么做推广app拿返佣的平台
  • 广州白云网站建设网红推广团队去哪里找
  • 哈尔滨做网站哪家好强广东网络seo推广公司
  • 长沙比较好的装修公司有哪些泰安网站seo
  • 西安外贸网站建设google框架一键安装
  • 聊城哪里做优化网站什么是seo关键词优化
  • 海纳企业网站建设模板第一营销网
  • 南山网站设计训竞价销售是什么意思
  • 辽宁沈阳建设工程信息网站百度下载安装到手机
  • 网站建设公司广州网络营销的三大核心
  • 余姚网站建设报价新媒体营销方式有几种
  • 网站建设新技术各大网站域名大全
  • 做二代身份证网站百度推广登录平台
  • 山东做网站建设公司哪家好培训心得体会模板
  • 网站 目标网站开发公司排行榜
  • 动易cms下载宁波seo外包费用
  • 最专业 汽车网站建设如何免费注册网站
  • 小猪网站怎么做的深圳外贸seo
  • 做展示类网站程序员培训机构排名前十