Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
车家大少爷
three.js
提交
b151edf2
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,发现更多精彩内容 >>
提交
b151edf2
编写于
3月 30, 2012
作者:
M
Mr.doob
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Simplified skyboxes handling in examples.
上级
fb248f5b
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
34 addition
and
65 deletion
+34
-65
examples/webgl_materials_cars.html
examples/webgl_materials_cars.html
+5
-13
examples/webgl_materials_cars_anaglyph.html
examples/webgl_materials_cars_anaglyph.html
+1
-2
examples/webgl_materials_cubemap.html
examples/webgl_materials_cubemap.html
+7
-15
examples/webgl_materials_cubemap_balls_reflection.html
examples/webgl_materials_cubemap_balls_reflection.html
+10
-16
examples/webgl_materials_cubemap_balls_reflection_anaglyph.html
...es/webgl_materials_cubemap_balls_reflection_anaglyph.html
+1
-1
examples/webgl_materials_cubemap_balls_refraction.html
examples/webgl_materials_cubemap_balls_refraction.html
+9
-17
examples/webgl_materials_cubemap_balls_refraction_crosseyed.html
...s/webgl_materials_cubemap_balls_refraction_crosseyed.html
+1
-1
未找到文件。
examples/webgl_materials_cars.html
浏览文件 @
b151edf2
...
...
@@ -138,7 +138,7 @@
var
container
,
stats
;
var
camera
,
scene
,
renderer
;
var
cameraCube
,
sceneCube
,
cubeTarget
;
var
cameraCube
,
sceneCube
;
var
m
,
mi
;
...
...
@@ -168,10 +168,9 @@
// CAMERAS
camera
=
new
THREE
.
PerspectiveCamera
(
70
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100000
);
cameraCube
=
new
THREE
.
PerspectiveCamera
(
70
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100000
);
cubeTarget
=
new
THREE
.
Vector3
(
0
,
0
,
0
);
scene
.
add
(
camera
);
cameraCube
=
new
THREE
.
PerspectiveCamera
(
70
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100000
);
sceneCube
.
add
(
cameraCube
);
// LIGHTS
...
...
@@ -609,20 +608,13 @@
var
timer
=
-
0.0002
*
Date
.
now
();
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
position
.
x
=
1000
*
Math
.
cos
(
timer
);
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
position
.
z
=
1000
*
Math
.
sin
(
timer
);
camera
.
lookAt
(
scene
.
position
);
cameraCube
.
rotation
.
copy
(
camera
.
rotation
);
cubeTarget
.
x
=
-
camera
.
position
.
x
;
cubeTarget
.
y
=
-
camera
.
position
.
y
;
cubeTarget
.
z
=
-
camera
.
position
.
z
;
cameraCube
.
lookAt
(
cubeTarget
);
renderer
.
clear
();
renderer
.
render
(
sceneCube
,
cameraCube
);
renderer
.
render
(
scene
,
camera
);
...
...
examples/webgl_materials_cars_anaglyph.html
浏览文件 @
b151edf2
...
...
@@ -596,9 +596,8 @@
var
timer
=
-
0.0002
*
Date
.
now
();
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
position
.
x
=
1000
*
Math
.
cos
(
timer
);
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
position
.
z
=
1000
*
Math
.
sin
(
timer
);
camera
.
lookAt
(
scene
.
position
);
...
...
examples/webgl_materials_cubemap.html
浏览文件 @
b151edf2
...
...
@@ -47,9 +47,9 @@
var
container
,
stats
;
var
camera
,
scene
,
renderer
;
var
cameraCube
,
sceneCube
,
cubeTarget
;
var
cameraCube
,
sceneCube
;
var
mesh
,
zmesh
,
lightMesh
,
geometry
;
var
mesh
,
lightMesh
,
geometry
;
var
loader
;
...
...
@@ -76,11 +76,9 @@
camera
=
new
THREE
.
PerspectiveCamera
(
50
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
5000
);
camera
.
position
.
z
=
2000
;
scene
.
add
(
camera
);
cameraCube
=
new
THREE
.
PerspectiveCamera
(
50
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100
);
cubeTarget
=
new
THREE
.
Vector3
(
0
,
0
,
0
);
scene
.
add
(
camera
);
sceneCube
.
add
(
cameraCube
);
// LIGHTS
...
...
@@ -207,21 +205,15 @@
var
timer
=
-
0.0002
*
Date
.
now
();
lightMesh
.
position
.
x
=
1500
*
Math
.
cos
(
timer
);
lightMesh
.
position
.
z
=
1500
*
Math
.
sin
(
timer
);
camera
.
position
.
x
+=
(
mouseX
-
camera
.
position
.
x
)
*
.
05
;
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
lookAt
(
scene
.
position
);
cameraCube
.
rotation
.
copy
(
camera
.
rotation
);
cubeTarget
.
x
=
-
camera
.
position
.
x
;
cubeTarget
.
y
=
-
camera
.
position
.
y
;
cubeTarget
.
z
=
-
camera
.
position
.
z
;
cameraCube
.
lookAt
(
cubeTarget
);
lightMesh
.
position
.
x
=
1500
*
Math
.
cos
(
timer
);
lightMesh
.
position
.
z
=
1500
*
Math
.
sin
(
timer
);
renderer
.
clear
();
renderer
.
render
(
sceneCube
,
cameraCube
);
renderer
.
render
(
scene
,
camera
);
...
...
examples/webgl_materials_cubemap_balls_reflection.html
浏览文件 @
b151edf2
...
...
@@ -46,9 +46,9 @@
var
container
;
var
camera
,
scene
,
renderer
;
var
cameraCube
,
sceneCube
,
cubeTarget
;
var
cameraCube
,
sceneCube
;
var
mesh
,
zmesh
,
lightMesh
,
geometry
;
var
mesh
,
lightMesh
,
geometry
;
var
spheres
=
[];
var
directionalLight
,
pointLight
;
...
...
@@ -74,12 +74,12 @@
camera
=
new
THREE
.
PerspectiveCamera
(
60
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100000
);
camera
.
position
.
z
=
3200
;
scene
.
add
(
camera
);
cameraCube
=
new
THREE
.
PerspectiveCamera
(
60
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100000
);
cubeTarget
=
new
THREE
.
Vector3
(
0
,
0
,
0
);
scene
.
add
(
camera
);
sceneCube
.
add
(
cameraCube
);
var
geometry
=
new
THREE
.
SphereGeometry
(
100
,
32
,
16
);
...
...
@@ -159,17 +159,6 @@
var
timer
=
0.0001
*
Date
.
now
();
camera
.
position
.
x
+=
(
mouseX
-
camera
.
position
.
x
)
*
.
05
;
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
lookAt
(
scene
.
position
);
cubeTarget
.
x
=
-
camera
.
position
.
x
;
cubeTarget
.
y
=
-
camera
.
position
.
y
;
cubeTarget
.
z
=
-
camera
.
position
.
z
;
cameraCube
.
lookAt
(
cubeTarget
);
for
(
var
i
=
0
,
il
=
spheres
.
length
;
i
<
il
;
i
++
)
{
var
sphere
=
spheres
[
i
];
...
...
@@ -179,7 +168,12 @@
}
renderer
.
clear
();
camera
.
position
.
x
+=
(
mouseX
-
camera
.
position
.
x
)
*
.
05
;
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
lookAt
(
scene
.
position
);
cameraCube
.
rotation
.
copy
(
camera
.
rotation
);
renderer
.
render
(
sceneCube
,
cameraCube
);
renderer
.
render
(
scene
,
camera
);
...
...
examples/webgl_materials_cubemap_balls_reflection_anaglyph.html
浏览文件 @
b151edf2
...
...
@@ -47,7 +47,7 @@
var
camera
,
scene
,
renderer
;
var
mesh
,
zmesh
,
lightMesh
,
geometry
;
var
mesh
,
lightMesh
,
geometry
;
var
spheres
=
[];
var
directionalLight
,
pointLight
;
...
...
examples/webgl_materials_cubemap_balls_refraction.html
浏览文件 @
b151edf2
...
...
@@ -46,9 +46,9 @@
var
container
;
var
camera
,
scene
,
renderer
;
var
cameraCube
,
sceneCube
,
cubeTarget
;
var
cameraCube
,
sceneCube
;
var
mesh
,
zmesh
,
lightMesh
,
geometry
;
var
mesh
,
lightMesh
,
geometry
;
var
spheres
=
[];
var
directionalLight
,
pointLight
;
...
...
@@ -73,11 +73,9 @@
camera
=
new
THREE
.
PerspectiveCamera
(
60
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100000
);
camera
.
position
.
z
=
3200
;
scene
.
add
(
camera
);
cameraCube
=
new
THREE
.
PerspectiveCamera
(
60
,
window
.
innerWidth
/
window
.
innerHeight
,
1
,
100000
);
cubeTarget
=
new
THREE
.
Vector3
(
0
,
0
,
0
);
scene
.
add
(
camera
);
sceneCube
.
add
(
cameraCube
);
var
geometry
=
new
THREE
.
SphereGeometry
(
100
,
32
,
16
);
...
...
@@ -157,17 +155,6 @@
var
timer
=
0.0001
*
Date
.
now
();
camera
.
position
.
x
+=
(
mouseX
-
camera
.
position
.
x
)
*
.
05
;
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
lookAt
(
scene
.
position
);
cubeTarget
.
x
=
-
camera
.
position
.
x
;
cubeTarget
.
y
=
-
camera
.
position
.
y
;
cubeTarget
.
z
=
-
camera
.
position
.
z
;
cameraCube
.
lookAt
(
cubeTarget
);
for
(
var
i
=
0
,
il
=
spheres
.
length
;
i
<
il
;
i
++
)
{
var
sphere
=
spheres
[
i
];
...
...
@@ -177,7 +164,12 @@
}
renderer
.
clear
();
camera
.
position
.
x
+=
(
mouseX
-
camera
.
position
.
x
)
*
.
05
;
camera
.
position
.
y
+=
(
-
mouseY
-
camera
.
position
.
y
)
*
.
05
;
camera
.
lookAt
(
scene
.
position
);
cameraCube
.
rotation
.
copy
(
camera
.
rotation
);
renderer
.
render
(
sceneCube
,
cameraCube
);
renderer
.
render
(
scene
,
camera
);
...
...
examples/webgl_materials_cubemap_balls_refraction_crosseyed.html
浏览文件 @
b151edf2
...
...
@@ -50,7 +50,7 @@
var
camera
,
scene
,
renderer
;
var
mesh
,
zmesh
,
lightMesh
,
geometry
;
var
mesh
,
lightMesh
,
geometry
;
var
spheres
=
[];
var
directionalLight
,
pointLight
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录