Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Ablesons
three.js
提交
97daea3b
T
three.js
项目概览
Ablesons
/
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 搜索 >>
未验证
提交
97daea3b
编写于
12月 22, 2020
作者:
M
Mr.doob
提交者:
GitHub
12月 22, 2020
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #20840 from linbingquan/dev-es6-defaultvalue
src: ES6 default value.
上级
326b83d6
93e1c2eb
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
19 addition
and
19 deletion
+19
-19
src/animation/AnimationClip.js
src/animation/AnimationClip.js
+3
-3
src/cameras/OrthographicCamera.js
src/cameras/OrthographicCamera.js
+7
-7
src/objects/Line.js
src/objects/Line.js
+3
-3
src/objects/Mesh.js
src/objects/Mesh.js
+3
-3
src/objects/Points.js
src/objects/Points.js
+3
-3
未找到文件。
src/animation/AnimationClip.js
浏览文件 @
97daea3b
...
...
@@ -9,12 +9,12 @@ import { VectorKeyframeTrack } from './tracks/VectorKeyframeTrack.js';
import
{
MathUtils
}
from
'
../math/MathUtils.js
'
;
import
{
NormalAnimationBlendMode
}
from
'
../constants.js
'
;
function
AnimationClip
(
name
,
duration
,
tracks
,
b
lendMode
)
{
function
AnimationClip
(
name
,
duration
=
-
1
,
tracks
,
blendMode
=
NormalAnimationB
lendMode
)
{
this
.
name
=
name
;
this
.
tracks
=
tracks
;
this
.
duration
=
(
duration
!==
undefined
)
?
duration
:
-
1
;
this
.
blendMode
=
(
blendMode
!==
undefined
)
?
blendMode
:
NormalAnimationB
lendMode
;
this
.
duration
=
duration
;
this
.
blendMode
=
b
lendMode
;
this
.
uuid
=
MathUtils
.
generateUUID
();
...
...
src/cameras/OrthographicCamera.js
浏览文件 @
97daea3b
import
{
Camera
}
from
'
./Camera.js
'
;
import
{
Object3D
}
from
'
../core/Object3D.js
'
;
function
OrthographicCamera
(
left
,
right
,
top
,
bottom
,
near
,
far
)
{
function
OrthographicCamera
(
left
=
-
1
,
right
=
1
,
top
=
1
,
bottom
=
-
1
,
near
=
0.1
,
far
=
2000
)
{
Camera
.
call
(
this
);
...
...
@@ -10,13 +10,13 @@ function OrthographicCamera( left, right, top, bottom, near, far ) {
this
.
zoom
=
1
;
this
.
view
=
null
;
this
.
left
=
(
left
!==
undefined
)
?
left
:
-
1
;
this
.
right
=
(
right
!==
undefined
)
?
right
:
1
;
this
.
top
=
(
top
!==
undefined
)
?
top
:
1
;
this
.
bottom
=
(
bottom
!==
undefined
)
?
bottom
:
-
1
;
this
.
left
=
left
;
this
.
right
=
right
;
this
.
top
=
top
;
this
.
bottom
=
bottom
;
this
.
near
=
(
near
!==
undefined
)
?
near
:
0.1
;
this
.
far
=
(
far
!==
undefined
)
?
far
:
2000
;
this
.
near
=
near
;
this
.
far
=
far
;
this
.
updateProjectionMatrix
();
...
...
src/objects/Line.js
浏览文件 @
97daea3b
...
...
@@ -13,7 +13,7 @@ const _inverseMatrix = new Matrix4();
const
_ray
=
new
Ray
();
const
_sphere
=
new
Sphere
();
function
Line
(
geometry
,
material
,
mode
)
{
function
Line
(
geometry
=
new
BufferGeometry
(),
material
=
new
LineBasicMaterial
()
,
mode
)
{
if
(
mode
===
1
)
{
...
...
@@ -25,8 +25,8 @@ function Line( geometry, material, mode ) {
this
.
type
=
'
Line
'
;
this
.
geometry
=
geometry
!==
undefined
?
geometry
:
new
BufferGeometry
()
;
this
.
material
=
material
!==
undefined
?
material
:
new
LineBasicMaterial
()
;
this
.
geometry
=
geometry
;
this
.
material
=
material
;
this
.
updateMorphTargets
();
...
...
src/objects/Mesh.js
浏览文件 @
97daea3b
...
...
@@ -33,14 +33,14 @@ const _uvC = new Vector2();
const
_intersectionPoint
=
new
Vector3
();
const
_intersectionPointWorld
=
new
Vector3
();
function
Mesh
(
geometry
,
material
)
{
function
Mesh
(
geometry
=
new
BufferGeometry
(),
material
=
new
MeshBasicMaterial
()
)
{
Object3D
.
call
(
this
);
this
.
type
=
'
Mesh
'
;
this
.
geometry
=
geometry
!==
undefined
?
geometry
:
new
BufferGeometry
()
;
this
.
material
=
material
!==
undefined
?
material
:
new
MeshBasicMaterial
()
;
this
.
geometry
=
geometry
;
this
.
material
=
material
;
this
.
updateMorphTargets
();
...
...
src/objects/Points.js
浏览文件 @
97daea3b
...
...
@@ -11,14 +11,14 @@ const _ray = new Ray();
const
_sphere
=
new
Sphere
();
const
_position
=
new
Vector3
();
function
Points
(
geometry
,
material
)
{
function
Points
(
geometry
=
new
BufferGeometry
(),
material
=
new
PointsMaterial
()
)
{
Object3D
.
call
(
this
);
this
.
type
=
'
Points
'
;
this
.
geometry
=
geometry
!==
undefined
?
geometry
:
new
BufferGeometry
()
;
this
.
material
=
material
!==
undefined
?
material
:
new
PointsMaterial
()
;
this
.
geometry
=
geometry
;
this
.
material
=
material
;
this
.
updateMorphTargets
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录