Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Ablesons
three.js
提交
8797bf05
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,发现更多精彩内容 >>
提交
8797bf05
编写于
9月 26, 2014
作者:
M
Mr.doob
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Updated builds.
上级
fb07c9bc
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
7 addition
and
2 deletion
+7
-2
build/three.js
build/three.js
+6
-1
build/three.min.js
build/three.min.js
+1
-1
未找到文件。
build/three.js
浏览文件 @
8797bf05
...
...
@@ -10377,7 +10377,12 @@ THREE.OrthographicCamera.prototype = Object.create( THREE.Camera.prototype );
THREE.OrthographicCamera.prototype.updateProjectionMatrix = function () {
this.projectionMatrix.makeOrthographic( this.left / this.zoom, this.right / this.zoom, this.top / this.zoom, this.bottom / this.zoom, this.near, this.far );
var dx = ( this.right - this.left ) / ( 2 * this.zoom );
var dy = ( this.top - this.bottom ) / ( 2 * this.zoom );
var cx = ( this.right + this.left ) / 2;
var cy = ( this.top + this.bottom ) / 2;
this.projectionMatrix.makeOrthographic( cx - dx, cx + dx, cy + dy, cy - dy, this.near, this.far );
};
...
...
build/three.min.js
浏览文件 @
8797bf05
...
...
@@ -223,7 +223,7 @@ THREE.Camera.prototype.clone=function(a){void 0===a&&(a=new THREE.Camera);THREE.
THREE
.
CubeCamera
=
function
(
a
,
b
,
c
){
THREE
.
Object3D
.
call
(
this
);
this
.
type
=
"
CubeCamera
"
;
var
d
=
new
THREE
.
PerspectiveCamera
(
90
,
1
,
a
,
b
);
d
.
up
.
set
(
0
,
-
1
,
0
);
d
.
lookAt
(
new
THREE
.
Vector3
(
1
,
0
,
0
));
this
.
add
(
d
);
var
e
=
new
THREE
.
PerspectiveCamera
(
90
,
1
,
a
,
b
);
e
.
up
.
set
(
0
,
-
1
,
0
);
e
.
lookAt
(
new
THREE
.
Vector3
(
-
1
,
0
,
0
));
this
.
add
(
e
);
var
g
=
new
THREE
.
PerspectiveCamera
(
90
,
1
,
a
,
b
);
g
.
up
.
set
(
0
,
0
,
1
);
g
.
lookAt
(
new
THREE
.
Vector3
(
0
,
1
,
0
));
this
.
add
(
g
);
var
f
=
new
THREE
.
PerspectiveCamera
(
90
,
1
,
a
,
b
);
f
.
up
.
set
(
0
,
0
,
-
1
);
f
.
lookAt
(
new
THREE
.
Vector3
(
0
,
-
1
,
0
));
this
.
add
(
f
);
var
h
=
new
THREE
.
PerspectiveCamera
(
90
,
1
,
a
,
b
);
h
.
up
.
set
(
0
,
-
1
,
0
);
h
.
lookAt
(
new
THREE
.
Vector3
(
0
,
0
,
1
));
this
.
add
(
h
);
var
k
=
new
THREE
.
PerspectiveCamera
(
90
,
1
,
a
,
b
);
k
.
up
.
set
(
0
,
-
1
,
0
);
k
.
lookAt
(
new
THREE
.
Vector3
(
0
,
0
,
-
1
));
this
.
add
(
k
);
this
.
renderTarget
=
new
THREE
.
WebGLRenderTargetCube
(
c
,
c
,{
format
:
THREE
.
RGBFormat
,
magFilter
:
THREE
.
LinearFilter
,
minFilter
:
THREE
.
LinearFilter
});
this
.
updateCubeMap
=
function
(
a
,
b
){
var
c
=
this
.
renderTarget
,
r
=
c
.
generateMipmaps
;
c
.
generateMipmaps
=!
1
;
c
.
activeCubeFace
=
0
;
a
.
render
(
b
,
d
,
c
);
c
.
activeCubeFace
=
1
;
a
.
render
(
b
,
e
,
c
);
c
.
activeCubeFace
=
2
;
a
.
render
(
b
,
g
,
c
);
c
.
activeCubeFace
=
3
;
a
.
render
(
b
,
f
,
c
);
c
.
activeCubeFace
=
4
;
a
.
render
(
b
,
h
,
c
);
c
.
generateMipmaps
=
r
;
c
.
activeCubeFace
=
5
;
a
.
render
(
b
,
k
,
c
)}};
THREE
.
CubeCamera
.
prototype
=
Object
.
create
(
THREE
.
Object3D
.
prototype
);
THREE
.
OrthographicCamera
=
function
(
a
,
b
,
c
,
d
,
e
,
g
){
THREE
.
Camera
.
call
(
this
);
this
.
type
=
"
OrthographicCamera
"
;
this
.
zoom
=
1
;
this
.
left
=
a
;
this
.
right
=
b
;
this
.
top
=
c
;
this
.
bottom
=
d
;
this
.
near
=
void
0
!==
e
?
e
:.
1
;
this
.
far
=
void
0
!==
g
?
g
:
2
E3
;
this
.
updateProjectionMatrix
()};
THREE
.
OrthographicCamera
.
prototype
=
Object
.
create
(
THREE
.
Camera
.
prototype
);
THREE
.
OrthographicCamera
.
prototype
.
updateProjectionMatrix
=
function
(){
this
.
projectionMatrix
.
makeOrthographic
(
this
.
left
/
this
.
zoom
,
this
.
right
/
this
.
zoom
,
this
.
top
/
this
.
zoom
,
this
.
bottom
/
this
.
zoom
,
this
.
near
,
this
.
far
)};
THREE
.
OrthographicCamera
.
prototype
=
Object
.
create
(
THREE
.
Camera
.
prototype
);
THREE
.
OrthographicCamera
.
prototype
.
updateProjectionMatrix
=
function
(){
var
a
=
(
this
.
right
-
this
.
left
)
/
(
2
*
this
.
zoom
),
b
=
(
this
.
top
-
this
.
bottom
)
/
(
2
*
this
.
zoom
),
c
=
(
this
.
right
+
this
.
left
)
/
2
,
d
=
(
this
.
top
+
this
.
bottom
)
/
2
;
this
.
projectionMatrix
.
makeOrthographic
(
c
-
a
,
c
+
a
,
d
+
b
,
d
-
b
,
this
.
near
,
this
.
far
)};
THREE
.
OrthographicCamera
.
prototype
.
clone
=
function
(){
var
a
=
new
THREE
.
OrthographicCamera
;
THREE
.
Camera
.
prototype
.
clone
.
call
(
this
,
a
);
a
.
zoom
=
this
.
zoom
;
a
.
left
=
this
.
left
;
a
.
right
=
this
.
right
;
a
.
top
=
this
.
top
;
a
.
bottom
=
this
.
bottom
;
a
.
near
=
this
.
near
;
a
.
far
=
this
.
far
;
a
.
projectionMatrix
.
copy
(
this
.
projectionMatrix
);
return
a
};
THREE
.
PerspectiveCamera
=
function
(
a
,
b
,
c
,
d
){
THREE
.
Camera
.
call
(
this
);
this
.
type
=
"
PerspectiveCamera
"
;
this
.
zoom
=
1
;
this
.
fov
=
void
0
!==
a
?
a
:
50
;
this
.
aspect
=
void
0
!==
b
?
b
:
1
;
this
.
near
=
void
0
!==
c
?
c
:.
1
;
this
.
far
=
void
0
!==
d
?
d
:
2
E3
;
this
.
updateProjectionMatrix
()};
THREE
.
PerspectiveCamera
.
prototype
=
Object
.
create
(
THREE
.
Camera
.
prototype
);
THREE
.
PerspectiveCamera
.
prototype
.
setLens
=
function
(
a
,
b
){
void
0
===
b
&&
(
b
=
24
);
this
.
fov
=
2
*
THREE
.
Math
.
radToDeg
(
Math
.
atan
(
b
/
(
2
*
a
)));
this
.
updateProjectionMatrix
()};
THREE
.
PerspectiveCamera
.
prototype
.
setViewOffset
=
function
(
a
,
b
,
c
,
d
,
e
,
g
){
this
.
fullWidth
=
a
;
this
.
fullHeight
=
b
;
this
.
x
=
c
;
this
.
y
=
d
;
this
.
width
=
e
;
this
.
height
=
g
;
this
.
updateProjectionMatrix
()};
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录