Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
车家大少爷
three.js
提交
8c218910
T
three.js
项目概览
车家大少爷
/
three.js
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
three.js
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
未验证
提交
8c218910
编写于
5月 05, 2021
作者:
M
Michael Herzog
提交者:
GitHub
5月 05, 2021
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Material: Remove skinning. (#21788)
上级
773a5c74
变更
59
隐藏空白更改
内联
并排
Showing
59 changed file
with
25 addition
and
229 deletion
+25
-229
docs/api/en/materials/MeshBasicMaterial.html
docs/api/en/materials/MeshBasicMaterial.html
+0
-3
docs/api/en/materials/MeshDepthMaterial.html
docs/api/en/materials/MeshDepthMaterial.html
+0
-3
docs/api/en/materials/MeshDistanceMaterial.html
docs/api/en/materials/MeshDistanceMaterial.html
+0
-3
docs/api/en/materials/MeshLambertMaterial.html
docs/api/en/materials/MeshLambertMaterial.html
+0
-3
docs/api/en/materials/MeshMatcapMaterial.html
docs/api/en/materials/MeshMatcapMaterial.html
+0
-3
docs/api/en/materials/MeshNormalMaterial.html
docs/api/en/materials/MeshNormalMaterial.html
+0
-3
docs/api/en/materials/MeshPhongMaterial.html
docs/api/en/materials/MeshPhongMaterial.html
+0
-4
docs/api/en/materials/MeshStandardMaterial.html
docs/api/en/materials/MeshStandardMaterial.html
+0
-3
docs/api/en/materials/MeshToonMaterial.html
docs/api/en/materials/MeshToonMaterial.html
+0
-3
docs/api/en/materials/ShaderMaterial.html
docs/api/en/materials/ShaderMaterial.html
+0
-5
docs/api/en/objects/SkinnedMesh.html
docs/api/en/objects/SkinnedMesh.html
+1
-2
docs/api/zh/materials/MeshBasicMaterial.html
docs/api/zh/materials/MeshBasicMaterial.html
+0
-3
docs/api/zh/materials/MeshDepthMaterial.html
docs/api/zh/materials/MeshDepthMaterial.html
+0
-3
docs/api/zh/materials/MeshDistanceMaterial.html
docs/api/zh/materials/MeshDistanceMaterial.html
+0
-3
docs/api/zh/materials/MeshLambertMaterial.html
docs/api/zh/materials/MeshLambertMaterial.html
+0
-3
docs/api/zh/materials/MeshMatcapMaterial.html
docs/api/zh/materials/MeshMatcapMaterial.html
+0
-3
docs/api/zh/materials/MeshNormalMaterial.html
docs/api/zh/materials/MeshNormalMaterial.html
+0
-3
docs/api/zh/materials/MeshPhongMaterial.html
docs/api/zh/materials/MeshPhongMaterial.html
+0
-4
docs/api/zh/materials/MeshStandardMaterial.html
docs/api/zh/materials/MeshStandardMaterial.html
+0
-3
docs/api/zh/materials/MeshToonMaterial.html
docs/api/zh/materials/MeshToonMaterial.html
+0
-3
docs/api/zh/materials/ShaderMaterial.html
docs/api/zh/materials/ShaderMaterial.html
+0
-5
docs/api/zh/objects/SkinnedMesh.html
docs/api/zh/objects/SkinnedMesh.html
+0
-1
docs/manual/ar/introduction/How-to-update-things.html
docs/manual/ar/introduction/How-to-update-things.html
+0
-1
docs/manual/en/introduction/How-to-update-things.html
docs/manual/en/introduction/How-to-update-things.html
+0
-1
docs/manual/ja/introduction/How-to-update-things.html
docs/manual/ja/introduction/How-to-update-things.html
+1
-2
docs/manual/ko/introduction/How-to-update-things.html
docs/manual/ko/introduction/How-to-update-things.html
+0
-1
docs/manual/zh/introduction/How-to-update-things.html
docs/manual/zh/introduction/How-to-update-things.html
+0
-1
docs/scenes/bones-browser.html
docs/scenes/bones-browser.html
+0
-1
editor/js/Sidebar.Material.js
editor/js/Sidebar.Material.js
+0
-23
editor/js/Strings.js
editor/js/Strings.js
+0
-3
editor/js/libs/tern-threejs/threejs.js
editor/js/libs/tern-threejs/threejs.js
+0
-16
examples/js/effects/OutlineEffect.js
examples/js/effects/OutlineEffect.js
+0
-1
examples/js/loaders/ColladaLoader.js
examples/js/loaders/ColladaLoader.js
+1
-12
examples/js/loaders/FBXLoader.js
examples/js/loaders/FBXLoader.js
+0
-5
examples/js/loaders/GLTFLoader.js
examples/js/loaders/GLTFLoader.js
+1
-4
examples/js/loaders/MMDLoader.js
examples/js/loaders/MMDLoader.js
+0
-1
examples/jsm/effects/OutlineEffect.js
examples/jsm/effects/OutlineEffect.js
+0
-1
examples/jsm/loaders/ColladaLoader.js
examples/jsm/loaders/ColladaLoader.js
+0
-10
examples/jsm/loaders/FBXLoader.js
examples/jsm/loaders/FBXLoader.js
+0
-6
examples/jsm/loaders/GLTFLoader.js
examples/jsm/loaders/GLTFLoader.js
+1
-4
examples/jsm/loaders/MMDLoader.js
examples/jsm/loaders/MMDLoader.js
+0
-1
examples/jsm/nodes/materials/NodeMaterial.js
examples/jsm/nodes/materials/NodeMaterial.js
+0
-1
examples/webgl_loader_vrm.html
examples/webgl_loader_vrm.html
+0
-2
src/loaders/MaterialLoader.js
src/loaders/MaterialLoader.js
+0
-1
src/materials/Material.js
src/materials/Material.js
+0
-1
src/materials/MeshBasicMaterial.js
src/materials/MeshBasicMaterial.js
+0
-3
src/materials/MeshDepthMaterial.js
src/materials/MeshDepthMaterial.js
+0
-2
src/materials/MeshDistanceMaterial.js
src/materials/MeshDistanceMaterial.js
+0
-3
src/materials/MeshLambertMaterial.js
src/materials/MeshLambertMaterial.js
+0
-3
src/materials/MeshMatcapMaterial.js
src/materials/MeshMatcapMaterial.js
+0
-3
src/materials/MeshNormalMaterial.js
src/materials/MeshNormalMaterial.js
+0
-3
src/materials/MeshPhongMaterial.js
src/materials/MeshPhongMaterial.js
+0
-3
src/materials/MeshStandardMaterial.js
src/materials/MeshStandardMaterial.js
+0
-3
src/materials/MeshToonMaterial.js
src/materials/MeshToonMaterial.js
+0
-3
src/materials/ShaderMaterial.js
src/materials/ShaderMaterial.js
+0
-4
src/objects/Mesh.js
src/objects/Mesh.js
+1
-1
src/renderers/WebGLRenderer.js
src/renderers/WebGLRenderer.js
+11
-2
src/renderers/webgl/WebGLPrograms.js
src/renderers/webgl/WebGLPrograms.js
+1
-1
src/renderers/webgl/WebGLShadowMap.js
src/renderers/webgl/WebGLShadowMap.js
+7
-27
未找到文件。
docs/api/en/materials/MeshBasicMaterial.html
浏览文件 @
8c218910
...
...
@@ -109,9 +109,6 @@
The refraction ratio should not exceed 1. Default is *0.98*.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Texture specularMap]
</h3>
<p>
Specular map used by the material. Default is null.
</p>
...
...
docs/api/en/materials/MeshDepthMaterial.html
浏览文件 @
8c218910
...
...
@@ -87,9 +87,6 @@
<h3>
[property:Boolean morphTargets]
</h3>
<p>
Define whether the material uses morphTargets. Default is false.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Boolean wireframe]
</h3>
<p>
Render geometry as wireframe. Default is false (i.e. render as smooth shaded).
</p>
...
...
docs/api/en/materials/MeshDistanceMaterial.html
浏览文件 @
8c218910
...
...
@@ -108,9 +108,6 @@
The position of the point light in world space.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h2>
Methods
</h2>
<p>
See the base [page:Material] class for common methods.
</p>
...
...
docs/api/en/materials/MeshLambertMaterial.html
浏览文件 @
8c218910
...
...
@@ -138,9 +138,6 @@
The refraction ratio should not exceed 1. Default is *0.98*.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Texture specularMap]
</h3>
<p>
Specular map used by the material. Default is null.
</p>
...
...
docs/api/en/materials/MeshMatcapMaterial.html
浏览文件 @
8c218910
...
...
@@ -136,9 +136,6 @@
Default is a [page:Vector2] set to (1,1).
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h2>
Methods
</h2>
<p>
See the base [page:Material] class for common methods.
</p>
...
...
docs/api/en/materials/MeshNormalMaterial.html
浏览文件 @
8c218910
...
...
@@ -113,9 +113,6 @@
Default is a [page:Vector2] set to (1,1).
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Boolean wireframe]
</h3>
<p>
Render geometry as wireframe. Default is false (i.e. render as smooth shaded).
...
...
docs/api/en/materials/MeshPhongMaterial.html
浏览文件 @
8c218910
...
...
@@ -203,10 +203,6 @@
<h3>
[property:Float shininess]
</h3>
<p>
How shiny the [page:.specular] highlight is; a higher value gives a sharper highlight. Default is *30*.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Color specular]
</h3>
<p>
Specular color of the material. Default is a [page:Color] set to *0x111111* (very dark grey).
<br
/><br
/>
...
...
docs/api/en/materials/MeshStandardMaterial.html
浏览文件 @
8c218910
...
...
@@ -242,9 +242,6 @@
<h3>
[property:Texture roughnessMap]
</h3>
<p>
The green channel of this texture is used to alter the roughness of the material.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Boolean vertexTangents]
</h3>
<p>
Defines whether precomputed vertex tangents, which must be provided in a vec4 "tangent" attribute,
...
...
docs/api/en/materials/MeshToonMaterial.html
浏览文件 @
8c218910
...
...
@@ -163,9 +163,6 @@
Default is a [page:Vector2] set to (1,1).
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Boolean wireframe]
</h3>
<p>
Render geometry as wireframe. Default is *false* (i.e. render as flat polygons).
</p>
...
...
docs/api/en/materials/ShaderMaterial.html
浏览文件 @
8c218910
...
...
@@ -383,11 +383,6 @@ this.extensions = {
Define whether the material is rendered with flat shading. Default is false.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning; true to pass skinning attributes to the shader. Default is false.
</p>
<h3>
[property:Object uniforms]
</h3>
<p>
An object of the form:
...
...
docs/api/en/objects/SkinnedMesh.html
浏览文件 @
8c218910
...
...
@@ -13,7 +13,6 @@
<p
class=
"desc"
>
A mesh that has a [page:Skeleton] with [page:Bone bones] that can then be used to animate the vertices of the geometry.
The material must support skinning and have skinning enabled - see [page:MeshStandardMaterial.skinning].
</p>
<iframe
id=
"scene"
src=
"scenes/bones-browser.html"
></iframe>
...
...
@@ -157,7 +156,7 @@
<p>
Calculates the position of the vertex at the given index relative to the current bone transformations.
</p>
<h2>
Source
</h2>
<p>
...
...
docs/api/zh/materials/MeshBasicMaterial.html
浏览文件 @
8c218910
...
...
@@ -98,9 +98,6 @@
折射率不应超过1。默认值为*0.98*。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h3>
[property:Texture specularMap]
</h3>
<p>
材质使用的高光贴图。默认值为null。
</p>
...
...
docs/api/zh/materials/MeshDepthMaterial.html
浏览文件 @
8c218910
...
...
@@ -76,9 +76,6 @@
<h3>
[property:Boolean morphTargets]
</h3>
<p>
材质是否使用morphTargets。默认值为false。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h3>
[property:Boolean wireframe]
</h3>
<p>
将几何体渲染为线框。默认值为*false*(即渲染为平滑着色)。
</p>
...
...
docs/api/zh/materials/MeshDistanceMaterial.html
浏览文件 @
8c218910
...
...
@@ -97,9 +97,6 @@
The position of the point light in world space.
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h2>
方法(Methods)
</h2>
<p>
共有方法请参见其基类[page:Material]。
</p>
...
...
docs/api/zh/materials/MeshLambertMaterial.html
浏览文件 @
8c218910
...
...
@@ -119,9 +119,6 @@
折射率不应超过1。默认值为*0.98*。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h3>
[property:Texture specularMap]
</h3>
<p>
材质使用的高光贴图。默认值为null。
</p>
...
...
docs/api/zh/materials/MeshMatcapMaterial.html
浏览文件 @
8c218910
...
...
@@ -112,9 +112,6 @@
<p>
法线贴图对材质的影响程度。典型范围是0-1。默认值是[page:Vector2]设置为(1,1)。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h2>
方法(Methods)
</h2>
<p>
共有方法请参见其基类[page:Material]。
</p>
...
...
docs/api/zh/materials/MeshNormalMaterial.html
浏览文件 @
8c218910
...
...
@@ -91,9 +91,6 @@
<p>
法线贴图对材质的影响程度。典型范围是0-1。默认值是[page:Vector2]设置为(1,1)。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h3>
[property:Boolean wireframe]
</h3>
<p>
将几何体渲染为线框。默认值为*false*(即渲染为平滑着色)。
...
...
docs/api/zh/materials/MeshPhongMaterial.html
浏览文件 @
8c218910
...
...
@@ -163,10 +163,6 @@
<h3>
[property:Float shininess]
</h3>
<p>
[page:.specular]高亮的程度,越高的值越闪亮。默认值为 *30*。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h3>
[property:Color specular]
</h3>
<p>
材质的高光颜色。默认值为*0x111111*(深灰色)的颜色[page:Color]。
<br
/><br
/>
这定义了材质的光泽度和光泽的颜色。
...
...
docs/api/zh/materials/MeshStandardMaterial.html
浏览文件 @
8c218910
...
...
@@ -198,9 +198,6 @@
<h3>
[property:Texture roughnessMap]
</h3>
<p>
该纹理的绿色通道用于改变材质的粗糙度。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
材质是否使用蒙皮。默认值为false。
</p>
<h3>
[property:Boolean vertexTangents]
</h3>
<p>
Defines whether precomputed vertex tangents, which must be provided in a vec4 "tangent" attribute,
...
...
docs/api/zh/materials/MeshToonMaterial.html
浏览文件 @
8c218910
...
...
@@ -163,9 +163,6 @@
Default is a [page:Vector2] set to (1,1).
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
Define whether the material uses skinning. Default is false.
</p>
<h3>
[property:Boolean wireframe]
</h3>
<p>
Render geometry as wireframe. Default is *false* (i.e. render as flat polygons).
</p>
...
...
docs/api/zh/materials/ShaderMaterial.html
浏览文件 @
8c218910
...
...
@@ -337,11 +337,6 @@ this.extensions = {
<p>
定义材质是否使用平面着色进行渲染。默认值为false。
</p>
<h3>
[property:Boolean skinning]
</h3>
<p>
定义材质是否使用蒙皮; 如果将蒙皮属性传递给shader,则为true。默认值为false。
</p>
<h3>
[property:Object uniforms]
</h3>
<p>
如下形式的对象:
<code>
...
...
docs/api/zh/objects/SkinnedMesh.html
浏览文件 @
8c218910
...
...
@@ -13,7 +13,6 @@
<p
class=
"desc"
>
具有[page:Skeleton](骨架)和[page:Bone bones](骨骼)的网格,可用于给几何体上的顶点添加动画。
其材质必须支持蒙皮,并且已经启用了蒙皮 —— 请阅读[page:MeshStandardMaterial.skinning]。
</p>
<iframe
id=
"scene"
src=
"scenes/bones-browser.html"
></iframe>
...
...
docs/manual/ar/introduction/How-to-update-things.html
浏览文件 @
8c218910
...
...
@@ -137,7 +137,6 @@ line.geometry.computeBoundingSphere();
<li>
texture
</li>
<li>
fog
</li>
<li>
vertex colors
</li>
<li>
skinning
</li>
<li>
morphing
</li>
<li>
shadow map
</li>
<li>
alpha test
</li>
...
...
docs/manual/en/introduction/How-to-update-things.html
浏览文件 @
8c218910
...
...
@@ -147,7 +147,6 @@ line.geometry.computeBoundingSphere();
<li>
texture
</li>
<li>
fog
</li>
<li>
vertex colors
</li>
<li>
skinning
</li>
<li>
morphing
</li>
<li>
shadow map
</li>
<li>
alpha test
</li>
...
...
docs/manual/ja/introduction/How-to-update-things.html
浏览文件 @
8c218910
...
...
@@ -173,7 +173,6 @@ geometry.dynamic = true;
<li>
texture
</li>
<li>
fog
</li>
<li>
vertex colors
</li>
<li>
skinning
</li>
<li>
morphing
</li>
<li>
shadow map
</li>
<li>
alpha test
</li>
...
...
@@ -260,4 +259,4 @@ camera.updateProjectionMatrix();
</div>
</body>
</html>
\ No newline at end of file
</html>
docs/manual/ko/introduction/How-to-update-things.html
浏览文件 @
8c218910
...
...
@@ -143,7 +143,6 @@ line.geometry.computeBoundingSphere();
<li>
texture
</li>
<li>
fog
</li>
<li>
vertex colors
</li>
<li>
skinning
</li>
<li>
morphing
</li>
<li>
shadow map
</li>
<li>
alpha test
</li>
...
...
docs/manual/zh/introduction/How-to-update-things.html
浏览文件 @
8c218910
...
...
@@ -132,7 +132,6 @@ line.geometry.attributes.position.needsUpdate = true; // 需要加在第一次
<li>
texture
</li>
<li>
fog
</li>
<li>
vertex colors
</li>
<li>
skinning
</li>
<li>
morphing
</li>
<li>
shadow map
</li>
<li>
alpha test
</li>
...
...
docs/scenes/bones-browser.html
浏览文件 @
8c218910
...
...
@@ -163,7 +163,6 @@
function
createMesh
(
geometry
,
bones
)
{
const
material
=
new
MeshPhongMaterial
(
{
skinning
:
true
,
color
:
0x156289
,
emissive
:
0x072534
,
side
:
DoubleSide
,
...
...
editor/js/Sidebar.Material.js
浏览文件 @
8c218910
...
...
@@ -262,16 +262,6 @@ function SidebarMaterial( editor ) {
container
.
add
(
materialDepthPackingRow
);
// skinning
var
materialSkinningRow
=
new
UIRow
();
var
materialSkinning
=
new
UICheckbox
(
false
).
onChange
(
update
);
materialSkinningRow
.
add
(
new
UIText
(
strings
.
getKey
(
'
sidebar/material/skinning
'
)
).
setWidth
(
'
90px
'
)
);
materialSkinningRow
.
add
(
materialSkinning
);
container
.
add
(
materialSkinningRow
);
// map
var
materialMapRow
=
new
UIRow
();
...
...
@@ -751,12 +741,6 @@ function SidebarMaterial( editor ) {
}
if
(
material
.
skinning
!==
undefined
&&
material
.
skinning
!==
materialSkinning
.
getValue
()
)
{
editor
.
execute
(
new
SetMaterialValueCommand
(
editor
,
currentObject
,
'
skinning
'
,
materialSkinning
.
getValue
(),
currentMaterialSlot
)
);
}
if
(
material
.
map
!==
undefined
)
{
var
mapEnabled
=
materialMapEnabled
.
getValue
()
===
true
;
...
...
@@ -1256,7 +1240,6 @@ function SidebarMaterial( editor ) {
'
vertexColors
'
:
materialVertexColorsRow
,
'
vertexTangents
'
:
materialVertexTangentsRow
,
'
depthPacking
'
:
materialDepthPackingRow
,
'
skinning
'
:
materialSkinningRow
,
'
map
'
:
materialMapRow
,
'
matcap
'
:
materialMatcapMapRow
,
'
alphaMap
'
:
materialAlphaMapRow
,
...
...
@@ -1438,12 +1421,6 @@ function SidebarMaterial( editor ) {
}
if
(
material
.
skinning
!==
undefined
)
{
materialSkinning
.
setValue
(
material
.
skinning
);
}
if
(
material
.
map
!==
undefined
)
{
materialMapEnabled
.
setValue
(
material
.
map
!==
null
);
...
...
editor/js/Strings.js
浏览文件 @
8c218910
...
...
@@ -250,7 +250,6 @@ function Strings( config ) {
'
sidebar/material/clearcoatroughness
'
:
'
Clearcoat Roughness
'
,
'
sidebar/material/vertexcolors
'
:
'
Vertex Colors
'
,
'
sidebar/material/vertextangents
'
:
'
Vertex Tangents
'
,
'
sidebar/material/skinning
'
:
'
Skinning
'
,
'
sidebar/material/matcap
'
:
'
Matcap
'
,
'
sidebar/material/map
'
:
'
Map
'
,
'
sidebar/material/alphamap
'
:
'
Alpha Map
'
,
...
...
@@ -585,7 +584,6 @@ function Strings( config ) {
'
sidebar/material/clearcoatroughness
'
:
'
Rugosité du vernis
'
,
'
sidebar/material/vertexcolors
'
:
'
Couleurs aux Sommets
'
,
'
sidebar/material/vertextangents
'
:
'
Tangentes aux sommets
'
,
'
sidebar/material/skinning
'
:
'
Skinning
'
,
'
sidebar/material/matcap
'
:
'
Matcap
'
,
'
sidebar/material/map
'
:
'
Texture
'
,
'
sidebar/material/alphamap
'
:
'
Texture de transparence
'
,
...
...
@@ -920,7 +918,6 @@ function Strings( config ) {
'
sidebar/material/clearcoatroughness
'
:
'
透明图层粗糙度
'
,
'
sidebar/material/vertexcolors
'
:
'
顶点颜色
'
,
'
sidebar/material/vertextangents
'
:
'
顶点切线
'
,
'
sidebar/material/skinning
'
:
'
皮肤
'
,
'
sidebar/material/matcap
'
:
'
材质捕获
'
,
'
sidebar/material/map
'
:
'
贴图
'
,
'
sidebar/material/alphamap
'
:
'
透明贴图
'
,
...
...
editor/js/libs/tern-threejs/threejs.js
浏览文件 @
8c218910
...
...
@@ -2161,10 +2161,6 @@
"
!type
"
:
"
boolean
"
,
"
!doc
"
:
"
This setting might not have any effect when used with certain renderers.
"
},
"
skinning
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define whether the material uses skinning. Default is false.
"
},
"
morphTargets
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define whether the material uses morphTargets. Default is false.
"
...
...
@@ -2300,10 +2296,6 @@
"
!type
"
:
"
boolean
"
,
"
!doc
"
:
"
This setting might not have any effect when used with certain renderers.
"
},
"
skinning
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define whether the material uses skinning. Default is *false*.
"
},
"
morphTargets
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define whether the material uses morphTargets. Default is *false*.
"
...
...
@@ -2444,10 +2436,6 @@
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
This setting might not have any effect when used with certain renderers.
"
},
"
skinning
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define whether the material uses skinning. Default is *false*.
"
},
"
morphTargets
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define whether the material uses morphTargets. Default is *false*.
"
...
...
@@ -2551,10 +2539,6 @@
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define how the vertices are colored, by defining how the *colors* attribute gets populated. Default is false.
"
},
"
skinning
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Define whether the material uses skinning; true to pass skinning attributes to the shader. Default is false.
"
},
"
morphTargets
"
:
{
"
!type
"
:
"
bool
"
,
"
!doc
"
:
"
Defines whether the material uses morphTargets; true morphTarget attributes to this shader
"
...
...
examples/js/effects/OutlineEffect.js
浏览文件 @
8c218910
...
...
@@ -243,7 +243,6 @@
if
(
material
.
name
===
'
invisible
'
)
return
;
const
outlineParameters
=
originalMaterial
.
userData
.
outlineParameters
;
material
.
skinning
=
originalMaterial
.
skinning
;
material
.
morphTargets
=
originalMaterial
.
morphTargets
;
material
.
morphNormals
=
originalMaterial
.
morphNormals
;
material
.
fog
=
originalMaterial
.
fog
;
...
...
examples/js/loaders/ColladaLoader.js
浏览文件 @
8c218910
...
...
@@ -3439,18 +3439,7 @@
}
// regard skinning
const
skinning
=
geometry
.
data
.
attributes
.
skinIndex
!==
undefined
;
if
(
skinning
)
{
for
(
let
i
=
0
,
l
=
materials
.
length
;
i
<
l
;
i
++
)
{
materials
[
i
].
skinning
=
true
;
}
}
// choose between a single or multi materials (material array)
const
skinning
=
geometry
.
data
.
attributes
.
skinIndex
!==
undefined
;
// choose between a single or multi materials (material array)
const
material
=
materials
.
length
===
1
?
materials
[
0
]
:
materials
;
// now create a specific 3D object
...
...
examples/js/loaders/FBXLoader.js
浏览文件 @
8c218910
...
...
@@ -1157,11 +1157,6 @@
if
(
geometry
.
FBX_Deformer
)
{
materials
.
forEach
(
function
(
material
)
{
material
.
skinning
=
true
;
}
);
model
=
new
THREE
.
SkinnedMesh
(
geometry
,
material
);
model
.
normalizeSkinWeights
();
...
...
examples/js/loaders/GLTFLoader.js
浏览文件 @
8c218910
...
...
@@ -2418,7 +2418,6 @@
const
useVertexTangents
=
geometry
.
attributes
.
tangent
!==
undefined
;
const
useVertexColors
=
geometry
.
attributes
.
color
!==
undefined
;
const
useFlatShading
=
geometry
.
attributes
.
normal
===
undefined
;
const
useSkinning
=
mesh
.
isSkinnedMesh
===
true
;
const
useMorphTargets
=
Object
.
keys
(
geometry
.
morphAttributes
).
length
>
0
;
const
useMorphNormals
=
useMorphTargets
&&
geometry
.
morphAttributes
.
normal
!==
undefined
;
...
...
@@ -2460,11 +2459,10 @@
}
// Clone the material if it will be modified
if
(
useVertexTangents
||
useVertexColors
||
useFlatShading
||
use
Skinning
||
use
MorphTargets
)
{
if
(
useVertexTangents
||
useVertexColors
||
useFlatShading
||
useMorphTargets
)
{
let
cacheKey
=
'
ClonedMaterial:
'
+
material
.
uuid
+
'
:
'
;
if
(
material
.
isGLTFSpecularGlossinessMaterial
)
cacheKey
+=
'
specular-glossiness:
'
;
if
(
useSkinning
)
cacheKey
+=
'
skinning:
'
;
if
(
useVertexTangents
)
cacheKey
+=
'
vertex-tangents:
'
;
if
(
useVertexColors
)
cacheKey
+=
'
vertex-colors:
'
;
if
(
useFlatShading
)
cacheKey
+=
'
flat-shading:
'
;
...
...
@@ -2475,7 +2473,6 @@
if
(
!
cachedMaterial
)
{
cachedMaterial
=
material
.
clone
();
if
(
useSkinning
)
cachedMaterial
.
skinning
=
true
;
if
(
useVertexColors
)
cachedMaterial
.
vertexColors
=
true
;
if
(
useFlatShading
)
cachedMaterial
.
flatShading
=
true
;
if
(
useMorphTargets
)
cachedMaterial
.
morphTargets
=
true
;
...
...
examples/js/loaders/MMDLoader.js
浏览文件 @
8c218910
...
...
@@ -956,7 +956,6 @@
params
.
emissive
=
new
THREE
.
Color
().
fromArray
(
material
.
ambient
);
params
.
transparent
=
params
.
opacity
!==
1.0
;
//
params
.
skinning
=
geometry
.
bones
.
length
>
0
?
true
:
false
;
params
.
morphTargets
=
geometry
.
morphTargets
.
length
>
0
?
true
:
false
;
params
.
fog
=
true
;
// blend
...
...
examples/jsm/effects/OutlineEffect.js
浏览文件 @
8c218910
...
...
@@ -333,7 +333,6 @@ class OutlineEffect {
const
outlineParameters
=
originalMaterial
.
userData
.
outlineParameters
;
material
.
skinning
=
originalMaterial
.
skinning
;
material
.
morphTargets
=
originalMaterial
.
morphTargets
;
material
.
morphNormals
=
originalMaterial
.
morphNormals
;
material
.
fog
=
originalMaterial
.
fog
;
...
...
examples/jsm/loaders/ColladaLoader.js
浏览文件 @
8c218910
...
...
@@ -3684,16 +3684,6 @@ class ColladaLoader extends Loader {
const
skinning
=
(
geometry
.
data
.
attributes
.
skinIndex
!==
undefined
);
if
(
skinning
)
{
for
(
let
i
=
0
,
l
=
materials
.
length
;
i
<
l
;
i
++
)
{
materials
[
i
].
skinning
=
true
;
}
}
// choose between a single or multi materials (material array)
const
material
=
(
materials
.
length
===
1
)
?
materials
[
0
]
:
materials
;
...
...
examples/jsm/loaders/FBXLoader.js
浏览文件 @
8c218910
...
...
@@ -1261,12 +1261,6 @@ class FBXTreeParser {
if
(
geometry
.
FBX_Deformer
)
{
materials
.
forEach
(
function
(
material
)
{
material
.
skinning
=
true
;
}
);
model
=
new
SkinnedMesh
(
geometry
,
material
);
model
.
normalizeSkinWeights
();
...
...
examples/jsm/loaders/GLTFLoader.js
浏览文件 @
8c218910
...
...
@@ -2682,7 +2682,6 @@ class GLTFParser {
const
useVertexTangents
=
geometry
.
attributes
.
tangent
!==
undefined
;
const
useVertexColors
=
geometry
.
attributes
.
color
!==
undefined
;
const
useFlatShading
=
geometry
.
attributes
.
normal
===
undefined
;
const
useSkinning
=
mesh
.
isSkinnedMesh
===
true
;
const
useMorphTargets
=
Object
.
keys
(
geometry
.
morphAttributes
).
length
>
0
;
const
useMorphNormals
=
useMorphTargets
&&
geometry
.
morphAttributes
.
normal
!==
undefined
;
...
...
@@ -2727,12 +2726,11 @@ class GLTFParser {
}
// Clone the material if it will be modified
if
(
useVertexTangents
||
useVertexColors
||
useFlatShading
||
use
Skinning
||
use
MorphTargets
)
{
if
(
useVertexTangents
||
useVertexColors
||
useFlatShading
||
useMorphTargets
)
{
let
cacheKey
=
'
ClonedMaterial:
'
+
material
.
uuid
+
'
:
'
;
if
(
material
.
isGLTFSpecularGlossinessMaterial
)
cacheKey
+=
'
specular-glossiness:
'
;
if
(
useSkinning
)
cacheKey
+=
'
skinning:
'
;
if
(
useVertexTangents
)
cacheKey
+=
'
vertex-tangents:
'
;
if
(
useVertexColors
)
cacheKey
+=
'
vertex-colors:
'
;
if
(
useFlatShading
)
cacheKey
+=
'
flat-shading:
'
;
...
...
@@ -2745,7 +2743,6 @@ class GLTFParser {
cachedMaterial
=
material
.
clone
();
if
(
useSkinning
)
cachedMaterial
.
skinning
=
true
;
if
(
useVertexColors
)
cachedMaterial
.
vertexColors
=
true
;
if
(
useFlatShading
)
cachedMaterial
.
flatShading
=
true
;
if
(
useMorphTargets
)
cachedMaterial
.
morphTargets
=
true
;
...
...
examples/jsm/loaders/MMDLoader.js
浏览文件 @
8c218910
...
...
@@ -1100,7 +1100,6 @@ class MaterialBuilder {
//
params
.
skinning
=
geometry
.
bones
.
length
>
0
?
true
:
false
;
params
.
morphTargets
=
geometry
.
morphTargets
.
length
>
0
?
true
:
false
;
params
.
fog
=
true
;
...
...
examples/jsm/nodes/materials/NodeMaterial.js
浏览文件 @
8c218910
...
...
@@ -191,7 +191,6 @@ class NodeMaterial extends ShaderMaterial {
if
(
this
.
premultipliedAlpha
===
true
)
data
.
premultipliedAlpha
=
this
.
premultipliedAlpha
;
if
(
this
.
morphTargets
===
true
)
data
.
morphTargets
=
true
;
if
(
this
.
skinning
===
true
)
data
.
skinning
=
true
;
if
(
this
.
visible
===
false
)
data
.
visible
=
false
;
if
(
JSON
.
stringify
(
this
.
userData
)
!==
'
{}
'
)
data
.
userData
=
this
.
userData
;
...
...
examples/webgl_loader_vrm.html
浏览文件 @
8c218910
...
...
@@ -62,7 +62,6 @@
THREE
.
Material
.
prototype
.
copy
.
call
(
material
,
object
.
material
[
i
]
);
material
.
color
.
copy
(
object
.
material
[
i
].
color
);
material
.
map
=
object
.
material
[
i
].
map
;
material
.
skinning
=
object
.
material
[
i
].
skinning
;
material
.
morphTargets
=
object
.
material
[
i
].
morphTargets
;
material
.
morphNormals
=
object
.
material
[
i
].
morphNormals
;
object
.
material
[
i
]
=
material
;
...
...
@@ -75,7 +74,6 @@
THREE
.
Material
.
prototype
.
copy
.
call
(
material
,
object
.
material
);
material
.
color
.
copy
(
object
.
material
.
color
);
material
.
map
=
object
.
material
.
map
;
material
.
skinning
=
object
.
material
.
skinning
;
material
.
morphTargets
=
object
.
material
.
morphTargets
;
material
.
morphNormals
=
object
.
material
.
morphNormals
;
object
.
material
=
material
;
...
...
src/loaders/MaterialLoader.js
浏览文件 @
8c218910
...
...
@@ -118,7 +118,6 @@ class MaterialLoader extends Loader {
if
(
json
.
polygonOffsetFactor
!==
undefined
)
material
.
polygonOffsetFactor
=
json
.
polygonOffsetFactor
;
if
(
json
.
polygonOffsetUnits
!==
undefined
)
material
.
polygonOffsetUnits
=
json
.
polygonOffsetUnits
;
if
(
json
.
skinning
!==
undefined
)
material
.
skinning
=
json
.
skinning
;
if
(
json
.
morphTargets
!==
undefined
)
material
.
morphTargets
=
json
.
morphTargets
;
if
(
json
.
morphNormals
!==
undefined
)
material
.
morphNormals
=
json
.
morphNormals
;
if
(
json
.
dithering
!==
undefined
)
material
.
dithering
=
json
.
dithering
;
...
...
src/materials/Material.js
浏览文件 @
8c218910
...
...
@@ -314,7 +314,6 @@ Material.prototype = Object.assign( Object.create( EventDispatcher.prototype ),
if
(
this
.
morphTargets
===
true
)
data
.
morphTargets
=
true
;
if
(
this
.
morphNormals
===
true
)
data
.
morphNormals
=
true
;
if
(
this
.
skinning
===
true
)
data
.
skinning
=
true
;
if
(
this
.
flatShading
===
true
)
data
.
flatShading
=
this
.
flatShading
;
...
...
src/materials/MeshBasicMaterial.js
浏览文件 @
8c218910
...
...
@@ -29,7 +29,6 @@ import { Color } from '../math/Color.js';
* wireframe: <boolean>,
* wireframeLinewidth: <float>,
*
* skinning: <bool>,
* morphTargets: <bool>
* }
*/
...
...
@@ -66,7 +65,6 @@ class MeshBasicMaterial extends Material {
this
.
wireframeLinecap
=
'
round
'
;
this
.
wireframeLinejoin
=
'
round
'
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
setValues
(
parameters
);
...
...
@@ -101,7 +99,6 @@ class MeshBasicMaterial extends Material {
this
.
wireframeLinecap
=
source
.
wireframeLinecap
;
this
.
wireframeLinejoin
=
source
.
wireframeLinejoin
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
return
this
;
...
...
src/materials/MeshDepthMaterial.js
浏览文件 @
8c218910
...
...
@@ -29,7 +29,6 @@ class MeshDepthMaterial extends Material {
this
.
depthPacking
=
BasicDepthPacking
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
map
=
null
;
...
...
@@ -55,7 +54,6 @@ class MeshDepthMaterial extends Material {
this
.
depthPacking
=
source
.
depthPacking
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
map
=
source
.
map
;
...
...
src/materials/MeshDistanceMaterial.js
浏览文件 @
8c218910
...
...
@@ -8,7 +8,6 @@ import { Vector3 } from '../math/Vector3.js';
* nearDistance: <float>,
* farDistance: <float>,
*
* skinning: <bool>,
* morphTargets: <bool>,
*
* map: new THREE.Texture( <Image> ),
...
...
@@ -34,7 +33,6 @@ class MeshDistanceMaterial extends Material {
this
.
nearDistance
=
1
;
this
.
farDistance
=
1000
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
map
=
null
;
...
...
@@ -59,7 +57,6 @@ class MeshDistanceMaterial extends Material {
this
.
nearDistance
=
source
.
nearDistance
;
this
.
farDistance
=
source
.
farDistance
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
map
=
source
.
map
;
...
...
src/materials/MeshLambertMaterial.js
浏览文件 @
8c218910
...
...
@@ -31,7 +31,6 @@ import { Color } from '../math/Color.js';
* wireframe: <boolean>,
* wireframeLinewidth: <float>,
*
* skinning: <bool>,
* morphTargets: <bool>,
* morphNormals: <bool>
* }
...
...
@@ -73,7 +72,6 @@ class MeshLambertMaterial extends Material {
this
.
wireframeLinecap
=
'
round
'
;
this
.
wireframeLinejoin
=
'
round
'
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
morphNormals
=
false
;
...
...
@@ -113,7 +111,6 @@ class MeshLambertMaterial extends Material {
this
.
wireframeLinecap
=
source
.
wireframeLinecap
;
this
.
wireframeLinejoin
=
source
.
wireframeLinejoin
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
morphNormals
=
source
.
morphNormals
;
...
...
src/materials/MeshMatcapMaterial.js
浏览文件 @
8c218910
...
...
@@ -25,7 +25,6 @@ import { Color } from '../math/Color.js';
*
* alphaMap: new THREE.Texture( <Image> ),
*
* skinning: <bool>,
* morphTargets: <bool>,
* morphNormals: <bool>
*
...
...
@@ -62,7 +61,6 @@ class MeshMatcapMaterial extends Material {
this
.
alphaMap
=
null
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
morphNormals
=
false
;
...
...
@@ -98,7 +96,6 @@ class MeshMatcapMaterial extends Material {
this
.
alphaMap
=
source
.
alphaMap
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
morphNormals
=
source
.
morphNormals
;
...
...
src/materials/MeshNormalMaterial.js
浏览文件 @
8c218910
...
...
@@ -20,7 +20,6 @@ import { Vector2 } from '../math/Vector2.js';
* wireframe: <boolean>,
* wireframeLinewidth: <float>
*
* skinning: <bool>,
* morphTargets: <bool>,
* morphNormals: <bool>,
*
...
...
@@ -52,7 +51,6 @@ class MeshNormalMaterial extends Material {
this
.
fog
=
false
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
morphNormals
=
false
;
...
...
@@ -80,7 +78,6 @@ class MeshNormalMaterial extends Material {
this
.
wireframe
=
source
.
wireframe
;
this
.
wireframeLinewidth
=
source
.
wireframeLinewidth
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
morphNormals
=
source
.
morphNormals
;
...
...
src/materials/MeshPhongMaterial.js
浏览文件 @
8c218910
...
...
@@ -45,7 +45,6 @@ import { Color } from '../math/Color.js';
* wireframe: <boolean>,
* wireframeLinewidth: <float>,
*
* skinning: <bool>,
* morphTargets: <bool>,
* morphNormals: <bool>,
*
...
...
@@ -102,7 +101,6 @@ class MeshPhongMaterial extends Material {
this
.
wireframeLinecap
=
'
round
'
;
this
.
wireframeLinejoin
=
'
round
'
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
morphNormals
=
false
;
...
...
@@ -157,7 +155,6 @@ class MeshPhongMaterial extends Material {
this
.
wireframeLinecap
=
source
.
wireframeLinecap
;
this
.
wireframeLinejoin
=
source
.
wireframeLinejoin
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
morphNormals
=
source
.
morphNormals
;
...
...
src/materials/MeshStandardMaterial.js
浏览文件 @
8c218910
...
...
@@ -47,7 +47,6 @@ import { Color } from '../math/Color.js';
* wireframe: <boolean>,
* wireframeLinewidth: <float>,
*
* skinning: <bool>,
* morphTargets: <bool>,
* morphNormals: <bool>,
*
...
...
@@ -108,7 +107,6 @@ class MeshStandardMaterial extends Material {
this
.
wireframeLinecap
=
'
round
'
;
this
.
wireframeLinejoin
=
'
round
'
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
morphNormals
=
false
;
...
...
@@ -169,7 +167,6 @@ class MeshStandardMaterial extends Material {
this
.
wireframeLinecap
=
source
.
wireframeLinecap
;
this
.
wireframeLinejoin
=
source
.
wireframeLinejoin
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
morphNormals
=
source
.
morphNormals
;
...
...
src/materials/MeshToonMaterial.js
浏览文件 @
8c218910
...
...
@@ -36,7 +36,6 @@ import { Color } from '../math/Color.js';
* wireframe: <boolean>,
* wireframeLinewidth: <float>,
*
* skinning: <bool>,
* morphTargets: <bool>,
* morphNormals: <bool>
* }
...
...
@@ -85,7 +84,6 @@ class MeshToonMaterial extends Material {
this
.
wireframeLinecap
=
'
round
'
;
this
.
wireframeLinejoin
=
'
round
'
;
this
.
skinning
=
false
;
this
.
morphTargets
=
false
;
this
.
morphNormals
=
false
;
...
...
@@ -130,7 +128,6 @@ class MeshToonMaterial extends Material {
this
.
wireframeLinecap
=
source
.
wireframeLinecap
;
this
.
wireframeLinejoin
=
source
.
wireframeLinejoin
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
morphNormals
=
source
.
morphNormals
;
...
...
src/materials/ShaderMaterial.js
浏览文件 @
8c218910
...
...
@@ -17,7 +17,6 @@ import default_fragment from '../renderers/shaders/ShaderChunk/default_fragment.
*
* lights: <bool>,
*
* skinning: <bool>,
* morphTargets: <bool>,
* morphNormals: <bool>
* }
...
...
@@ -46,7 +45,6 @@ class ShaderMaterial extends Material {
this
.
lights
=
false
;
// set to use scene lights
this
.
clipping
=
false
;
// set to use user-defined clipping planes
this
.
skinning
=
false
;
// set to use skinning attribute streams
this
.
morphTargets
=
false
;
// set to use morph targets
this
.
morphNormals
=
false
;
// set to use morph normals
...
...
@@ -101,8 +99,6 @@ class ShaderMaterial extends Material {
this
.
lights
=
source
.
lights
;
this
.
clipping
=
source
.
clipping
;
this
.
skinning
=
source
.
skinning
;
this
.
morphTargets
=
source
.
morphTargets
;
this
.
morphNormals
=
source
.
morphNormals
;
...
...
src/objects/Mesh.js
浏览文件 @
8c218910
...
...
@@ -366,7 +366,7 @@ function checkBufferGeometryIntersection( object, material, raycaster, ray, posi
}
if
(
object
.
isSkinnedMesh
&&
material
.
skinning
)
{
if
(
object
.
isSkinnedMesh
)
{
object
.
boneTransform
(
a
,
_vA
);
object
.
boneTransform
(
b
,
_vB
);
...
...
src/renderers/WebGLRenderer.js
浏览文件 @
8c218910
...
...
@@ -1430,6 +1430,7 @@ function WebGLRenderer( parameters ) {
materialProperties
.
outputEncoding
=
parameters
.
outputEncoding
;
materialProperties
.
instancing
=
parameters
.
instancing
;
materialProperties
.
skinning
=
parameters
.
skinning
;
materialProperties
.
numClippingPlanes
=
parameters
.
numClippingPlanes
;
materialProperties
.
numIntersection
=
parameters
.
numClipIntersection
;
materialProperties
.
vertexAlphas
=
parameters
.
vertexAlphas
;
...
...
@@ -1490,6 +1491,14 @@ function WebGLRenderer( parameters ) {
needsProgramChange
=
true
;
}
else
if
(
object
.
isSkinnedMesh
&&
materialProperties
.
skinning
===
false
)
{
needsProgramChange
=
true
;
}
else
if
(
!
object
.
isSkinnedMesh
&&
materialProperties
.
skinning
===
true
)
{
needsProgramChange
=
true
;
}
else
if
(
materialProperties
.
envMap
!==
envMap
)
{
needsProgramChange
=
true
;
...
...
@@ -1612,7 +1621,7 @@ function WebGLRenderer( parameters ) {
material
.
isMeshStandardMaterial
||
material
.
isShaderMaterial
||
material
.
isShadowMaterial
||
material
.
skinning
)
{
object
.
isSkinnedMesh
)
{
p_uniforms
.
setValue
(
_gl
,
'
viewMatrix
'
,
camera
.
matrixWorldInverse
);
...
...
@@ -1624,7 +1633,7 @@ function WebGLRenderer( parameters ) {
// auto-setting of texture unit for bone texture must go before other textures
// otherwise textures used for skinning can take over texture units reserved for other material textures
if
(
material
.
skinning
)
{
if
(
object
.
isSkinnedMesh
)
{
p_uniforms
.
setOptional
(
_gl
,
object
,
'
bindMatrix
'
);
p_uniforms
.
setOptional
(
_gl
,
object
,
'
bindMatrixInverse
'
);
...
...
src/renderers/webgl/WebGLPrograms.js
浏览文件 @
8c218910
...
...
@@ -221,7 +221,7 @@ function WebGLPrograms( renderer, cubemaps, extensions, capabilities, bindingSta
sizeAttenuation
:
material
.
sizeAttenuation
,
logarithmicDepthBuffer
:
logarithmicDepthBuffer
,
skinning
:
material
.
skinning
&&
maxBones
>
0
,
skinning
:
object
.
isSkinnedMesh
===
true
&&
maxBones
>
0
,
maxBones
:
maxBones
,
useVertexTexture
:
floatVertexTextures
,
...
...
src/renderers/webgl/WebGLShadowMap.js
浏览文件 @
8c218910
...
...
@@ -228,9 +228,9 @@ function WebGLShadowMap( _renderer, _objects, _capabilities ) {
}
function
getDepthMaterialVariant
(
useMorphing
,
useSkinning
,
useInstancing
)
{
function
getDepthMaterialVariant
(
useMorphing
)
{
const
index
=
useMorphing
<<
0
|
useSkinning
<<
1
|
useInstancing
<<
2
;
const
index
=
useMorphing
<<
0
;
let
material
=
_depthMaterials
[
index
];
...
...
@@ -240,8 +240,7 @@ function WebGLShadowMap( _renderer, _objects, _capabilities ) {
depthPacking
:
RGBADepthPacking
,
morphTargets
:
useMorphing
,
skinning
:
useSkinning
morphTargets
:
useMorphing
}
);
...
...
@@ -253,9 +252,9 @@ function WebGLShadowMap( _renderer, _objects, _capabilities ) {
}
function
getDistanceMaterialVariant
(
useMorphing
,
useSkinning
,
useInstancing
)
{
function
getDistanceMaterialVariant
(
useMorphing
)
{
const
index
=
useMorphing
<<
0
|
useSkinning
<<
1
|
useInstancing
<<
2
;
const
index
=
useMorphing
<<
0
;
let
material
=
_distanceMaterials
[
index
];
...
...
@@ -263,8 +262,7 @@ function WebGLShadowMap( _renderer, _objects, _capabilities ) {
material
=
new
MeshDistanceMaterial
(
{
morphTargets
:
useMorphing
,
skinning
:
useSkinning
morphTargets
:
useMorphing
}
);
...
...
@@ -300,25 +298,7 @@ function WebGLShadowMap( _renderer, _objects, _capabilities ) {
}
let
useSkinning
=
false
;
if
(
object
.
isSkinnedMesh
===
true
)
{
if
(
material
.
skinning
===
true
)
{
useSkinning
=
true
;
}
else
{
console
.
warn
(
'
THREE.WebGLShadowMap: THREE.SkinnedMesh with material.skinning set to false:
'
,
object
);
}
}
const
useInstancing
=
object
.
isInstancedMesh
===
true
;
result
=
getMaterialVariant
(
useMorphing
,
useSkinning
,
useInstancing
);
result
=
getMaterialVariant
(
useMorphing
);
}
else
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录