Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Ablesons
three.js
提交
7a68f02f
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 搜索 >>
提交
7a68f02f
编写于
12月 04, 2020
作者:
G
Garrett Johnson
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
node modularize
上级
ecd8117e
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
21 addition
and
21 deletion
+21
-21
examples/jsm/postprocessing/BokehPass.js
examples/jsm/postprocessing/BokehPass.js
+3
-3
examples/jsm/postprocessing/ClearPass.js
examples/jsm/postprocessing/ClearPass.js
+3
-3
examples/jsm/postprocessing/OutlinePass.js
examples/jsm/postprocessing/OutlinePass.js
+3
-3
examples/jsm/postprocessing/RenderPass.js
examples/jsm/postprocessing/RenderPass.js
+3
-3
examples/jsm/postprocessing/SAOPass.js
examples/jsm/postprocessing/SAOPass.js
+3
-3
examples/jsm/postprocessing/SSAARenderPass.js
examples/jsm/postprocessing/SSAARenderPass.js
+3
-3
examples/jsm/postprocessing/UnrealBloomPass.js
examples/jsm/postprocessing/UnrealBloomPass.js
+3
-3
未找到文件。
examples/jsm/postprocessing/BokehPass.js
浏览文件 @
7a68f02f
...
...
@@ -77,7 +77,7 @@ var BokehPass = function ( scene, camera, params ) {
this
.
fsQuad
=
new
Pass
.
FullScreenQuad
(
this
.
materialBokeh
);
this
.
oldClearColor
=
new
Color
();
this
.
_
oldClearColor
=
new
Color
();
};
...
...
@@ -91,7 +91,7 @@ BokehPass.prototype = Object.assign( Object.create( Pass.prototype ), {
this
.
scene
.
overrideMaterial
=
this
.
materialDepth
;
renderer
.
getClearColor
(
this
.
oldClearColor
);
renderer
.
getClearColor
(
this
.
_
oldClearColor
);
var
oldClearAlpha
=
renderer
.
getClearAlpha
();
var
oldAutoClear
=
renderer
.
autoClear
;
renderer
.
autoClear
=
false
;
...
...
@@ -122,7 +122,7 @@ BokehPass.prototype = Object.assign( Object.create( Pass.prototype ), {
}
this
.
scene
.
overrideMaterial
=
null
;
renderer
.
setClearColor
(
this
.
oldClearColor
);
renderer
.
setClearColor
(
this
.
_
oldClearColor
);
renderer
.
setClearAlpha
(
oldClearAlpha
);
renderer
.
autoClear
=
oldAutoClear
;
...
...
examples/jsm/postprocessing/ClearPass.js
浏览文件 @
7a68f02f
...
...
@@ -11,7 +11,7 @@ var ClearPass = function ( clearColor, clearAlpha ) {
this
.
clearColor
=
(
clearColor
!==
undefined
)
?
clearColor
:
0x000000
;
this
.
clearAlpha
=
(
clearAlpha
!==
undefined
)
?
clearAlpha
:
0
;
this
.
oldClearColor
=
new
Color
();
this
.
_
oldClearColor
=
new
Color
();
};
...
...
@@ -25,7 +25,7 @@ ClearPass.prototype = Object.assign( Object.create( Pass.prototype ), {
if
(
this
.
clearColor
)
{
renderer
.
getClearColor
(
this
.
oldClearColor
);
renderer
.
getClearColor
(
this
.
_
oldClearColor
);
oldClearAlpha
=
renderer
.
getClearAlpha
();
renderer
.
setClearColor
(
this
.
clearColor
,
this
.
clearAlpha
);
...
...
@@ -37,7 +37,7 @@ ClearPass.prototype = Object.assign( Object.create( Pass.prototype ), {
if
(
this
.
clearColor
)
{
renderer
.
setClearColor
(
this
.
oldClearColor
,
oldClearAlpha
);
renderer
.
setClearColor
(
this
.
_
oldClearColor
,
oldClearAlpha
);
}
...
...
examples/jsm/postprocessing/OutlinePass.js
浏览文件 @
7a68f02f
...
...
@@ -116,7 +116,7 @@ var OutlinePass = function ( resolution, scene, camera, selectedObjects ) {
this
.
enabled
=
true
;
this
.
needsSwap
=
false
;
this
.
oldClearColor
=
new
Color
();
this
.
_
oldClearColor
=
new
Color
();
this
.
oldClearAlpha
=
1
;
this
.
fsQuad
=
new
Pass
.
FullScreenQuad
(
null
);
...
...
@@ -296,7 +296,7 @@ OutlinePass.prototype = Object.assign( Object.create( Pass.prototype ), {
if
(
this
.
selectedObjects
.
length
>
0
)
{
renderer
.
getClearColor
(
this
.
oldClearColor
);
renderer
.
getClearColor
(
this
.
_
oldClearColor
);
this
.
oldClearAlpha
=
renderer
.
getClearAlpha
();
var
oldAutoClear
=
renderer
.
autoClear
;
...
...
@@ -411,7 +411,7 @@ OutlinePass.prototype = Object.assign( Object.create( Pass.prototype ), {
renderer
.
setRenderTarget
(
readBuffer
);
this
.
fsQuad
.
render
(
renderer
);
renderer
.
setClearColor
(
this
.
oldClearColor
,
this
.
oldClearAlpha
);
renderer
.
setClearColor
(
this
.
_
oldClearColor
,
this
.
oldClearAlpha
);
renderer
.
autoClear
=
oldAutoClear
;
}
...
...
examples/jsm/postprocessing/RenderPass.js
浏览文件 @
7a68f02f
...
...
@@ -18,7 +18,7 @@ var RenderPass = function ( scene, camera, overrideMaterial, clearColor, clearAl
this
.
clear
=
true
;
this
.
clearDepth
=
false
;
this
.
needsSwap
=
false
;
this
.
oldClearColor
=
new
Color
();
this
.
_
oldClearColor
=
new
Color
();
};
...
...
@@ -43,7 +43,7 @@ RenderPass.prototype = Object.assign( Object.create( Pass.prototype ), {
if
(
this
.
clearColor
)
{
renderer
.
getClearColor
(
this
.
oldClearColor
);
renderer
.
getClearColor
(
this
.
_
oldClearColor
);
oldClearAlpha
=
renderer
.
getClearAlpha
();
renderer
.
setClearColor
(
this
.
clearColor
,
this
.
clearAlpha
);
...
...
@@ -64,7 +64,7 @@ RenderPass.prototype = Object.assign( Object.create( Pass.prototype ), {
if
(
this
.
clearColor
)
{
renderer
.
setClearColor
(
this
.
oldClearColor
,
oldClearAlpha
);
renderer
.
setClearColor
(
this
.
_
oldClearColor
,
oldClearAlpha
);
}
...
...
examples/jsm/postprocessing/SAOPass.js
浏览文件 @
7a68f02f
...
...
@@ -44,7 +44,7 @@ var SAOPass = function ( scene, camera, depthTexture, useNormals, resolution ) {
this
.
supportsNormalTexture
=
(
useNormals
!==
undefined
)
?
useNormals
:
false
;
this
.
originalClearColor
=
new
Color
();
this
.
oldClearColor
=
new
Color
();
this
.
_
oldClearColor
=
new
Color
();
this
.
oldClearAlpha
=
1
;
this
.
params
=
{
...
...
@@ -220,7 +220,7 @@ SAOPass.prototype = Object.assign( Object.create( Pass.prototype ), {
}
renderer
.
getClearColor
(
this
.
oldClearColor
);
renderer
.
getClearColor
(
this
.
_
oldClearColor
);
this
.
oldClearAlpha
=
renderer
.
getClearAlpha
();
var
oldAutoClear
=
renderer
.
autoClear
;
renderer
.
autoClear
=
false
;
...
...
@@ -331,7 +331,7 @@ SAOPass.prototype = Object.assign( Object.create( Pass.prototype ), {
// Rendering SAOPass result on top of previous pass
this
.
renderPass
(
renderer
,
outputMaterial
,
this
.
renderToScreen
?
null
:
readBuffer
);
renderer
.
setClearColor
(
this
.
oldClearColor
,
this
.
oldClearAlpha
);
renderer
.
setClearColor
(
this
.
_
oldClearColor
,
this
.
oldClearAlpha
);
renderer
.
autoClear
=
oldAutoClear
;
},
...
...
examples/jsm/postprocessing/SSAARenderPass.js
浏览文件 @
7a68f02f
...
...
@@ -33,7 +33,7 @@ var SSAARenderPass = function ( scene, camera, clearColor, clearAlpha ) {
// as we need to clear the buffer in this pass, clearColor must be set to something, defaults to black.
this
.
clearColor
=
(
clearColor
!==
undefined
)
?
clearColor
:
0x000000
;
this
.
clearAlpha
=
(
clearAlpha
!==
undefined
)
?
clearAlpha
:
0
;
this
.
oldClearColor
=
new
Color
();
this
.
_
oldClearColor
=
new
Color
();
if
(
CopyShader
===
undefined
)
console
.
error
(
"
SSAARenderPass relies on CopyShader
"
);
...
...
@@ -90,7 +90,7 @@ SSAARenderPass.prototype = Object.assign( Object.create( Pass.prototype ), {
var
autoClear
=
renderer
.
autoClear
;
renderer
.
autoClear
=
false
;
renderer
.
getClearColor
(
this
.
oldClearColor
);
renderer
.
getClearColor
(
this
.
_
oldClearColor
);
var
oldClearAlpha
=
renderer
.
getClearAlpha
();
var
baseSampleWeight
=
1.0
/
jitterOffsets
.
length
;
...
...
@@ -147,7 +147,7 @@ SSAARenderPass.prototype = Object.assign( Object.create( Pass.prototype ), {
if
(
this
.
camera
.
clearViewOffset
)
this
.
camera
.
clearViewOffset
();
renderer
.
autoClear
=
autoClear
;
renderer
.
setClearColor
(
this
.
oldClearColor
,
oldClearAlpha
);
renderer
.
setClearColor
(
this
.
_
oldClearColor
,
oldClearAlpha
);
}
...
...
examples/jsm/postprocessing/UnrealBloomPass.js
浏览文件 @
7a68f02f
...
...
@@ -147,7 +147,7 @@ var UnrealBloomPass = function ( resolution, strength, radius, threshold ) {
this
.
enabled
=
true
;
this
.
needsSwap
=
false
;
this
.
oldClearColor
=
new
Color
();
this
.
_
oldClearColor
=
new
Color
();
this
.
oldClearAlpha
=
1
;
this
.
basic
=
new
MeshBasicMaterial
();
...
...
@@ -201,7 +201,7 @@ UnrealBloomPass.prototype = Object.assign( Object.create( Pass.prototype ), {
render
:
function
(
renderer
,
writeBuffer
,
readBuffer
,
deltaTime
,
maskActive
)
{
renderer
.
getClearColor
(
this
.
oldClearColor
);
renderer
.
getClearColor
(
this
.
_
oldClearColor
);
this
.
oldClearAlpha
=
renderer
.
getClearAlpha
();
var
oldAutoClear
=
renderer
.
autoClear
;
renderer
.
autoClear
=
false
;
...
...
@@ -289,7 +289,7 @@ UnrealBloomPass.prototype = Object.assign( Object.create( Pass.prototype ), {
// Restore renderer settings
renderer
.
setClearColor
(
this
.
oldClearColor
,
this
.
oldClearAlpha
);
renderer
.
setClearColor
(
this
.
_
oldClearColor
,
this
.
oldClearAlpha
);
renderer
.
autoClear
=
oldAutoClear
;
},
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录