Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
车家大少爷
three.js
提交
f3642887
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,发现更多精彩内容 >>
未验证
提交
f3642887
编写于
3月 22, 2019
作者:
M
Mr.doob
提交者:
GitHub
3月 22, 2019
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #16033 from Oletus/postprocessing-render-to-screen
Set Pass.renderToScreen automatically in EffectComposer
上级
4fb74e3b
911e4b21
变更
41
显示空白变更内容
内联
并排
Showing
41 changed file
with
25 addition
and
72 deletion
+25
-72
examples/js/postprocessing/EffectComposer.js
examples/js/postprocessing/EffectComposer.js
+20
-1
examples/misc_controls_fly.html
examples/misc_controls_fly.html
+0
-2
examples/webgl2_multisampled_renderbuffers.html
examples/webgl2_multisampled_renderbuffers.html
+0
-1
examples/webgl_lightningstrike.html
examples/webgl_lightningstrike.html
+1
-13
examples/webgl_loader_sea3d.html
examples/webgl_loader_sea3d.html
+0
-1
examples/webgl_loader_sea3d_bvh.html
examples/webgl_loader_sea3d_bvh.html
+0
-1
examples/webgl_loader_sea3d_bvh_retarget.html
examples/webgl_loader_sea3d_bvh_retarget.html
+0
-1
examples/webgl_loader_sea3d_hierarchy.html
examples/webgl_loader_sea3d_hierarchy.html
+0
-1
examples/webgl_loader_sea3d_keyframe.html
examples/webgl_loader_sea3d_keyframe.html
+0
-1
examples/webgl_loader_sea3d_morph.html
examples/webgl_loader_sea3d_morph.html
+0
-1
examples/webgl_loader_sea3d_physics.html
examples/webgl_loader_sea3d_physics.html
+0
-1
examples/webgl_loader_sea3d_skinning.html
examples/webgl_loader_sea3d_skinning.html
+0
-1
examples/webgl_loader_sea3d_sound.html
examples/webgl_loader_sea3d_sound.html
+0
-1
examples/webgl_materials_bumpmap_skin.html
examples/webgl_materials_bumpmap_skin.html
+0
-2
examples/webgl_materials_normalmap.html
examples/webgl_materials_normalmap.html
+0
-2
examples/webgl_materials_skin.html
examples/webgl_materials_skin.html
+4
-4
examples/webgl_materials_video.html
examples/webgl_materials_video.html
+0
-2
examples/webgl_points_dynamic.html
examples/webgl_points_dynamic.html
+0
-2
examples/webgl_postprocessing.html
examples/webgl_postprocessing.html
+0
-1
examples/webgl_postprocessing_advanced.html
examples/webgl_postprocessing_advanced.html
+0
-7
examples/webgl_postprocessing_afterimage.html
examples/webgl_postprocessing_afterimage.html
+0
-1
examples/webgl_postprocessing_backgrounds.html
examples/webgl_postprocessing_backgrounds.html
+0
-1
examples/webgl_postprocessing_dof.html
examples/webgl_postprocessing_dof.html
+0
-2
examples/webgl_postprocessing_fxaa.html
examples/webgl_postprocessing_fxaa.html
+0
-2
examples/webgl_postprocessing_glitch.html
examples/webgl_postprocessing_glitch.html
+0
-1
examples/webgl_postprocessing_masking.html
examples/webgl_postprocessing_masking.html
+0
-1
examples/webgl_postprocessing_nodes_pass.html
examples/webgl_postprocessing_nodes_pass.html
+0
-1
examples/webgl_postprocessing_outline.html
examples/webgl_postprocessing_outline.html
+0
-1
examples/webgl_postprocessing_pixel.html
examples/webgl_postprocessing_pixel.html
+0
-1
examples/webgl_postprocessing_rgb_halftone.html
examples/webgl_postprocessing_rgb_halftone.html
+0
-1
examples/webgl_postprocessing_sao.html
examples/webgl_postprocessing_sao.html
+0
-1
examples/webgl_postprocessing_smaa.html
examples/webgl_postprocessing_smaa.html
+0
-1
examples/webgl_postprocessing_sobel.html
examples/webgl_postprocessing_sobel.html
+0
-1
examples/webgl_postprocessing_ssaa.html
examples/webgl_postprocessing_ssaa.html
+0
-1
examples/webgl_postprocessing_ssaa_unbiased.html
examples/webgl_postprocessing_ssaa_unbiased.html
+0
-2
examples/webgl_postprocessing_ssao.html
examples/webgl_postprocessing_ssao.html
+0
-1
examples/webgl_postprocessing_taa.html
examples/webgl_postprocessing_taa.html
+0
-1
examples/webgl_postprocessing_unreal_bloom.html
examples/webgl_postprocessing_unreal_bloom.html
+0
-1
examples/webgl_shader_lava.html
examples/webgl_shader_lava.html
+0
-2
examples/webgl_shaders_tonemapping.html
examples/webgl_shaders_tonemapping.html
+0
-2
examples/webgl_tonemapping.html
examples/webgl_tonemapping.html
+0
-1
未找到文件。
examples/js/postprocessing/EffectComposer.js
浏览文件 @
f3642887
...
...
@@ -28,6 +28,8 @@ THREE.EffectComposer = function ( renderer, renderTarget ) {
this
.
writeBuffer
=
this
.
renderTarget1
;
this
.
readBuffer
=
this
.
renderTarget2
;
this
.
renderToScreen
=
true
;
this
.
passes
=
[];
// dependencies
...
...
@@ -75,6 +77,22 @@ Object.assign( THREE.EffectComposer.prototype, {
},
isLastEnabledPass
:
function
(
passIndex
)
{
for
(
var
i
=
passIndex
+
1
;
i
<
this
.
passes
.
length
;
i
++
)
{
if
(
this
.
passes
[
i
].
enabled
)
{
return
false
;
}
}
return
true
;
},
render
:
function
(
deltaTime
)
{
// deltaTime value is in seconds
...
...
@@ -99,6 +117,7 @@ Object.assign( THREE.EffectComposer.prototype, {
if
(
pass
.
enabled
===
false
)
continue
;
pass
.
renderToScreen
=
(
this
.
renderToScreen
&&
this
.
isLastEnabledPass
(
i
)
);
pass
.
render
(
this
.
renderer
,
this
.
writeBuffer
,
this
.
readBuffer
,
deltaTime
,
maskActive
);
if
(
pass
.
needsSwap
)
{
...
...
@@ -187,7 +206,7 @@ THREE.Pass = function () {
// if set to true, the pass clears its buffer before rendering
this
.
clear
=
false
;
// if set to true, the result of the pass is rendered to screen
// if set to true, the result of the pass is rendered to screen
. This is set automatically by EffectComposer.
this
.
renderToScreen
=
false
;
};
...
...
examples/misc_controls_fly.html
浏览文件 @
f3642887
...
...
@@ -240,8 +240,6 @@
var
renderModel
=
new
THREE
.
RenderPass
(
scene
,
camera
);
var
effectFilm
=
new
THREE
.
FilmPass
(
0.35
,
0.75
,
2048
,
false
);
effectFilm
.
renderToScreen
=
true
;
composer
=
new
THREE
.
EffectComposer
(
renderer
);
composer
.
addPass
(
renderModel
);
...
...
examples/webgl2_multisampled_renderbuffers.html
浏览文件 @
f3642887
...
...
@@ -135,7 +135,6 @@
var
renderPass
=
new
THREE
.
RenderPass
(
scene
,
camera
);
var
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
//
...
...
examples/webgl_lightningstrike.html
浏览文件 @
f3642887
...
...
@@ -256,7 +256,6 @@
outlinePass
.
edgeThickness
=
2.8
;
outlinePass
.
visibleEdgeColor
=
visibleColor
;
outlinePass
.
hiddenEdgeColor
.
set
(
0
);
outlinePass
.
renderToScreen
=
true
;
composer
.
addPass
(
outlinePass
);
scene
.
userData
.
outlineEnabled
=
true
;
...
...
@@ -580,18 +579,7 @@
controls
.
update
();
if
(
scene
.
userData
.
outlineEnabled
)
{
outlinePass
.
enabled
=
true
;
rayPass
.
renderToScreen
=
false
;
}
else
{
outlinePass
.
enabled
=
false
;
rayPass
.
renderToScreen
=
true
;
}
outlinePass
.
enabled
=
scene
.
userData
.
outlineEnabled
;
composer
.
render
();
...
...
examples/webgl_loader_sea3d.html
浏览文件 @
f3642887
...
...
@@ -146,7 +146,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_loader_sea3d_bvh.html
浏览文件 @
f3642887
...
...
@@ -262,7 +262,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_loader_sea3d_bvh_retarget.html
浏览文件 @
f3642887
...
...
@@ -211,7 +211,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_loader_sea3d_hierarchy.html
浏览文件 @
f3642887
...
...
@@ -154,7 +154,6 @@
composer
.
addPass
(
vignettePass
);
var
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
composer
.
addPass
(
copyPass
);
// events
...
...
examples/webgl_loader_sea3d_keyframe.html
浏览文件 @
f3642887
...
...
@@ -184,7 +184,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_loader_sea3d_morph.html
浏览文件 @
f3642887
...
...
@@ -150,7 +150,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_loader_sea3d_physics.html
浏览文件 @
f3642887
...
...
@@ -177,7 +177,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_loader_sea3d_skinning.html
浏览文件 @
f3642887
...
...
@@ -198,7 +198,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_loader_sea3d_sound.html
浏览文件 @
f3642887
...
...
@@ -349,7 +349,6 @@
composer
.
addPass
(
vignettePass
);
composer
.
addPass
(
copyPass
);
copyPass
.
renderToScreen
=
true
;
// events
...
...
examples/webgl_materials_bumpmap_skin.html
浏览文件 @
f3642887
...
...
@@ -134,8 +134,6 @@
var
effectBeckmann
=
new
THREE
.
ShaderPass
(
THREE
.
ShaderSkin
[
"
beckmann
"
]
);
var
effectCopy
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
effectCopy
.
renderToScreen
=
true
;
var
pars
=
{
minFilter
:
THREE
.
LinearFilter
,
magFilter
:
THREE
.
LinearFilter
,
format
:
THREE
.
RGBFormat
,
stencilBuffer
:
false
};
var
rtwidth
=
512
,
rtheight
=
512
;
...
...
examples/webgl_materials_normalmap.html
浏览文件 @
f3642887
...
...
@@ -171,8 +171,6 @@
effectColor
.
uniforms
[
'
powRGB
'
].
value
.
set
(
1.4
,
1.45
,
1.45
);
effectColor
.
uniforms
[
'
mulRGB
'
].
value
.
set
(
1.1
,
1.1
,
1.1
);
effectColor
.
renderToScreen
=
true
;
composer
=
new
THREE
.
EffectComposer
(
renderer
);
composer
.
addPass
(
renderModel
);
...
...
examples/webgl_materials_skin.html
浏览文件 @
f3642887
...
...
@@ -186,8 +186,6 @@
var
renderModelUV
=
new
THREE
.
RenderPass
(
scene
,
camera
,
materialUV
,
new
THREE
.
Color
(
0x575757
)
);
var
effectCopy
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
var
effectBloom1
=
new
THREE
.
BloomPass
(
1
,
15
,
2
,
512
);
var
effectBloom2
=
new
THREE
.
BloomPass
(
1
,
25
,
3
,
512
);
var
effectBloom3
=
new
THREE
.
BloomPass
(
1
,
25
,
4
,
512
);
...
...
@@ -196,8 +194,6 @@
effectBloom2
.
clear
=
true
;
effectBloom3
.
clear
=
true
;
effectCopy
.
renderToScreen
=
true
;
//
var
pars
=
{
...
...
@@ -215,6 +211,7 @@
composer
=
new
THREE
.
EffectComposer
(
renderer
,
new
THREE
.
WebGLRenderTarget
(
rtwidth
,
rtheight
,
pars
)
);
composer
.
addPass
(
renderModelUV
);
composer
.
renderToScreen
=
false
;
var
renderScene
=
new
THREE
.
TexturePass
(
composer
.
renderTarget2
.
texture
);
...
...
@@ -224,16 +221,19 @@
composerUV1
.
addPass
(
renderScene
);
composerUV1
.
addPass
(
effectBloom1
);
composerUV1
.
renderToScreen
=
false
;
composerUV2
=
new
THREE
.
EffectComposer
(
renderer
,
new
THREE
.
WebGLRenderTarget
(
rtwidth
,
rtheight
,
pars
)
);
composerUV2
.
addPass
(
renderScene
);
composerUV2
.
addPass
(
effectBloom2
);
composerUV2
.
renderToScreen
=
false
;
composerUV3
=
new
THREE
.
EffectComposer
(
renderer
,
new
THREE
.
WebGLRenderTarget
(
rtwidth
,
rtheight
,
pars
)
);
composerUV3
.
addPass
(
renderScene
);
composerUV3
.
addPass
(
effectBloom3
);
composerUV3
.
renderToScreen
=
false
;
//
...
...
examples/webgl_materials_video.html
浏览文件 @
f3642887
...
...
@@ -223,8 +223,6 @@
var
effectBloom
=
new
THREE
.
BloomPass
(
1.3
);
var
effectCopy
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
effectCopy
.
renderToScreen
=
true
;
composer
=
new
THREE
.
EffectComposer
(
renderer
);
composer
.
addPass
(
renderModel
);
...
...
examples/webgl_points_dynamic.html
浏览文件 @
f3642887
...
...
@@ -138,8 +138,6 @@
effectFocus
.
uniforms
[
"
screenWidth
"
].
value
=
window
.
innerWidth
;
effectFocus
.
uniforms
[
"
screenHeight
"
].
value
=
window
.
innerHeight
;
effectFocus
.
renderToScreen
=
true
;
composer
=
new
THREE
.
EffectComposer
(
renderer
);
composer
.
addPass
(
renderModel
);
...
...
examples/webgl_postprocessing.html
浏览文件 @
f3642887
...
...
@@ -82,7 +82,6 @@
var
effect
=
new
THREE
.
ShaderPass
(
THREE
.
RGBShiftShader
);
effect
.
uniforms
[
'
amount
'
].
value
=
0.0015
;
effect
.
renderToScreen
=
true
;
composer
.
addPass
(
effect
);
//
...
...
examples/webgl_postprocessing_advanced.html
浏览文件 @
f3642887
...
...
@@ -206,13 +206,6 @@
renderMaskInverse
.
inverse
=
true
;
//effectFilm.renderToScreen = true;
//effectFilmBW.renderToScreen = true;
//effectDotScreen.renderToScreen = true;
//effectBleach.renderToScreen = true;
effectVignette
.
renderToScreen
=
true
;
//effectCopy.renderToScreen = true;
//
var
rtParameters
=
{
...
...
examples/webgl_postprocessing_afterimage.html
浏览文件 @
f3642887
...
...
@@ -68,7 +68,6 @@
composer
.
addPass
(
new
THREE
.
RenderPass
(
scene
,
camera
)
);
afterimagePass
=
new
THREE
.
AfterimagePass
();
afterimagePass
.
renderToScreen
=
true
;
composer
.
addPass
(
afterimagePass
);
window
.
addEventListener
(
'
resize
'
,
onWindowResize
,
false
);
...
...
examples/webgl_postprocessing_backgrounds.html
浏览文件 @
f3642887
...
...
@@ -215,7 +215,6 @@
composer
.
addPass
(
renderPass
);
var
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
composer
.
addPass
(
copyPass
);
var
controls
=
new
THREE
.
OrbitControls
(
cameraP
,
renderer
.
domElement
);
...
...
examples/webgl_postprocessing_dof.html
浏览文件 @
f3642887
...
...
@@ -258,8 +258,6 @@
height
:
height
}
);
bokehPass
.
renderToScreen
=
true
;
var
composer
=
new
THREE
.
EffectComposer
(
renderer
);
composer
.
addPass
(
renderPass
);
...
...
examples/webgl_postprocessing_fxaa.html
浏览文件 @
f3642887
...
...
@@ -136,7 +136,6 @@
//
fxaaPass
=
new
THREE
.
ShaderPass
(
THREE
.
FXAAShader
);
fxaaPass
.
renderToScreen
=
true
;
var
pixelRatio
=
renderer
.
getPixelRatio
();
...
...
@@ -150,7 +149,6 @@
//
var
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
composer2
=
new
THREE
.
EffectComposer
(
renderer
);
composer2
.
addPass
(
renderPass
);
...
...
examples/webgl_postprocessing_glitch.html
浏览文件 @
f3642887
...
...
@@ -103,7 +103,6 @@
composer
.
addPass
(
new
THREE
.
RenderPass
(
scene
,
camera
)
);
glitchPass
=
new
THREE
.
GlitchPass
();
glitchPass
.
renderToScreen
=
true
;
composer
.
addPass
(
glitchPass
);
...
...
examples/webgl_postprocessing_masking.html
浏览文件 @
f3642887
...
...
@@ -81,7 +81,6 @@
var
texturePass2
=
new
THREE
.
TexturePass
(
texture2
);
var
outputPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
outputPass
.
renderToScreen
=
true
;
var
parameters
=
{
minFilter
:
THREE
.
LinearFilter
,
...
...
examples/webgl_postprocessing_nodes_pass.html
浏览文件 @
f3642887
...
...
@@ -516,7 +516,6 @@
composer
.
addPass
(
new
THREE
.
RenderPass
(
scene
,
camera
)
);
nodepass
=
new
NodePass
();
nodepass
.
renderToScreen
=
true
;
composer
.
addPass
(
nodepass
);
...
...
examples/webgl_postprocessing_outline.html
浏览文件 @
f3642887
...
...
@@ -298,7 +298,6 @@
effectFXAA
=
new
THREE
.
ShaderPass
(
THREE
.
FXAAShader
);
effectFXAA
.
uniforms
[
'
resolution
'
].
value
.
set
(
1
/
window
.
innerWidth
,
1
/
window
.
innerHeight
);
effectFXAA
.
renderToScreen
=
true
;
composer
.
addPass
(
effectFXAA
);
window
.
addEventListener
(
'
resize
'
,
onWindowResize
,
false
);
...
...
examples/webgl_postprocessing_pixel.html
浏览文件 @
f3642887
...
...
@@ -147,7 +147,6 @@
pixelPass
=
new
THREE
.
ShaderPass
(
THREE
.
PixelShader
);
pixelPass
.
uniforms
[
"
resolution
"
].
value
=
new
THREE
.
Vector2
(
window
.
innerWidth
,
window
.
innerHeight
);
pixelPass
.
uniforms
[
"
resolution
"
].
value
.
multiplyScalar
(
window
.
devicePixelRatio
);
pixelPass
.
renderToScreen
=
true
;
composer
.
addPass
(
pixelPass
);
window
.
addEventListener
(
'
resize
'
,
resize
);
...
...
examples/webgl_postprocessing_rgb_halftone.html
浏览文件 @
f3642887
...
...
@@ -149,7 +149,6 @@
disable
:
false
};
halftonePass
=
new
THREE
.
HalftonePass
(
window
.
innerWidth
,
window
.
innerHeight
,
params
);
halftonePass
.
renderToScreen
=
true
;
composer
.
addPass
(
renderPass
);
composer
.
addPass
(
halftonePass
);
...
...
examples/webgl_postprocessing_sao.html
浏览文件 @
f3642887
...
...
@@ -139,7 +139,6 @@
renderPass
=
new
THREE
.
RenderPass
(
scene
,
camera
);
composer
.
addPass
(
renderPass
);
saoPass
=
new
THREE
.
SAOPass
(
scene
,
camera
,
false
,
true
);
saoPass
.
renderToScreen
=
true
;
composer
.
addPass
(
saoPass
);
// Init gui
...
...
examples/webgl_postprocessing_smaa.html
浏览文件 @
f3642887
...
...
@@ -77,7 +77,6 @@
composer
.
addPass
(
new
THREE
.
RenderPass
(
scene
,
camera
)
);
pass
=
new
THREE
.
SMAAPass
(
window
.
innerWidth
*
renderer
.
getPixelRatio
(),
window
.
innerHeight
*
renderer
.
getPixelRatio
()
);
pass
.
renderToScreen
=
true
;
composer
.
addPass
(
pass
);
window
.
addEventListener
(
'
resize
'
,
onWindowResize
,
false
);
...
...
examples/webgl_postprocessing_sobel.html
浏览文件 @
f3642887
...
...
@@ -118,7 +118,6 @@
// Sobel operator
effectSobel
=
new
THREE
.
ShaderPass
(
THREE
.
SobelOperatorShader
);
effectSobel
.
renderToScreen
=
true
;
effectSobel
.
uniforms
[
"
resolution
"
].
value
.
x
=
window
.
innerWidth
;
effectSobel
.
uniforms
[
"
resolution
"
].
value
.
y
=
window
.
innerHeight
;
composer
.
addPass
(
effectSobel
);
...
...
examples/webgl_postprocessing_ssaa.html
浏览文件 @
f3642887
...
...
@@ -128,7 +128,6 @@
composer
.
addPass
(
ssaaRenderPass
);
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
composer
.
addPass
(
copyPass
);
window
.
addEventListener
(
'
resize
'
,
onWindowResize
,
false
);
...
...
examples/webgl_postprocessing_ssaa_unbiased.html
浏览文件 @
f3642887
...
...
@@ -182,7 +182,6 @@
ssaaRenderPassO
=
new
THREE
.
SSAARenderPass
(
scene
,
cameraO
);
composer
.
addPass
(
ssaaRenderPassO
);
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
composer
.
addPass
(
copyPass
);
window
.
addEventListener
(
'
resize
'
,
onWindowResize
,
false
);
...
...
@@ -251,7 +250,6 @@
ssaaRenderPassP
.
enabled
=
(
params
.
camera
===
'
perspective
'
);
ssaaRenderPassO
.
enabled
=
(
params
.
camera
===
'
orthographic
'
);
ssaaRenderPassP
.
renderToScreen
=
ssaaRenderPassO
.
renderToScreen
=
params
.
renderToScreen
;
copyPass
.
enabled
=
!
params
.
renderToScreen
;
composer
.
render
();
...
...
examples/webgl_postprocessing_ssao.html
浏览文件 @
f3642887
...
...
@@ -127,7 +127,6 @@
ssaoPass
=
new
THREE
.
SSAOPass
(
scene
,
camera
,
width
,
height
);
ssaoPass
.
kernelRadius
=
16
;
ssaoPass
.
renderToScreen
=
true
;
effectComposer
=
new
THREE
.
EffectComposer
(
renderer
);
effectComposer
.
addPass
(
ssaoPass
);
...
...
examples/webgl_postprocessing_taa.html
浏览文件 @
f3642887
...
...
@@ -157,7 +157,6 @@
composer
.
addPass
(
renderPass
);
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
composer
.
addPass
(
copyPass
);
window
.
addEventListener
(
'
resize
'
,
onWindowResize
,
false
);
...
...
examples/webgl_postprocessing_unreal_bloom.html
浏览文件 @
f3642887
...
...
@@ -104,7 +104,6 @@
var
renderScene
=
new
THREE
.
RenderPass
(
scene
,
camera
);
var
bloomPass
=
new
THREE
.
UnrealBloomPass
(
new
THREE
.
Vector2
(
window
.
innerWidth
,
window
.
innerHeight
),
1.5
,
0.4
,
0.85
);
bloomPass
.
renderToScreen
=
true
;
bloomPass
.
threshold
=
params
.
bloomThreshold
;
bloomPass
.
strength
=
params
.
bloomStrength
;
bloomPass
.
radius
=
params
.
bloomRadius
;
...
...
examples/webgl_shader_lava.html
浏览文件 @
f3642887
...
...
@@ -183,8 +183,6 @@
var
effectBloom
=
new
THREE
.
BloomPass
(
1.25
);
var
effectFilm
=
new
THREE
.
FilmPass
(
0.35
,
0.95
,
2048
,
false
);
effectFilm
.
renderToScreen
=
true
;
composer
=
new
THREE
.
EffectComposer
(
renderer
);
composer
.
addPass
(
renderModel
);
...
...
examples/webgl_shaders_tonemapping.html
浏览文件 @
f3642887
...
...
@@ -368,7 +368,6 @@
hdrToneMappingPass
=
new
THREE
.
AdaptiveToneMappingPass
(
false
,
256
);
bloomPass
=
new
THREE
.
BloomPass
();
var
gammaCorrectionPass
=
new
THREE
.
ShaderPass
(
THREE
.
GammaCorrectionShader
);
gammaCorrectionPass
.
renderToScreen
=
true
;
dynamicHdrEffectComposer
.
addPass
(
skyboxPass
);
dynamicHdrEffectComposer
.
addPass
(
scenePass
);
...
...
@@ -390,7 +389,6 @@
ldrEffectComposer
.
addPass
(
gammaCorrectionPass
);
// var gammaPass = new THREE.ShaderPass( GammaShader );
// gammaPass.renderToScreen = true;
// ldrEffectComposer.addPass( gammaPass );
var
gui
=
new
dat
.
GUI
();
...
...
examples/webgl_tonemapping.html
浏览文件 @
f3642887
...
...
@@ -215,7 +215,6 @@
composer
.
addPass
(
renderScene
);
var
copyPass
=
new
THREE
.
ShaderPass
(
THREE
.
CopyShader
);
copyPass
.
renderToScreen
=
true
;
composer
.
addPass
(
copyPass
);
stats
=
new
Stats
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录