Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Ablesons
three.js
提交
1d3b7f23
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(gitcode.net)2024年7月9日维护升级公告
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
1d3b7f23
编写于
10月 14, 2016
作者:
M
Mr.doob
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Updated builds.
上级
449d18ae
变更
2
展开全部
隐藏空白更改
内联
并排
Showing
2 changed file
with
615 addition
and
604 deletion
+615
-604
build/three.js
build/three.js
+17
-7
build/three.min.js
build/three.min.js
+598
-597
未找到文件。
build/three.js
浏览文件 @
1d3b7f23
...
...
@@ -4962,7 +4962,7 @@
var bumpmap_pars_fragment = "#ifdef USE_BUMPMAP\n\tuniform sampler2D bumpMap;\n\tuniform float bumpScale;\n\tvec2 dHdxy_fwd() {\n\t\tvec2 dSTdx = dFdx( vUv );\n\t\tvec2 dSTdy = dFdy( vUv );\n\t\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\n\t\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\n\t\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\n\t\treturn vec2( dBx, dBy );\n\t}\n\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy ) {\n\t\tvec3 vSigmaX = dFdx( surf_pos );\n\t\tvec3 vSigmaY = dFdy( surf_pos );\n\t\tvec3 vN = surf_norm;\n\t\tvec3 R1 = cross( vSigmaY, vN );\n\t\tvec3 R2 = cross( vN, vSigmaX );\n\t\tfloat fDet = dot( vSigmaX, R1 );\n\t\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\n\t\treturn normalize( abs( fDet ) * surf_norm - vGrad );\n\t}\n#endif\n";
var clipping_planes_fragment = "#if NUM_CLIPPING_PLANES > 0\n\tfor ( int i = 0; i <
NUM_CLIPPING_PLANES; ++ i ) {\n\t\tvec4 plane = clippingPlanes[ i ];\n\t\tif ( dot( vViewPosition, plane.xyz ) > plane.w ) discard;\n\t}
\n#endif\n";
var clipping_planes_fragment = "#if NUM_CLIPPING_PLANES > 0\n\tfor ( int i = 0; i <
UNION_CLIPPING_PLANES; ++ i ) {\n\t\tvec4 plane = clippingPlanes[ i ];\n\t\tif ( dot( vViewPosition, plane.xyz ) > plane.w ) discard;\n\t}\n\t\t\n\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\n\t\tbool clipped = true;\n\t\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; ++ i ) {\n\t\t\tvec4 plane = clippingPlanes[ i ];\n\t\t\tclipped = ( dot( vViewPosition, plane.xyz ) > plane.w ) && clipped;\n\t\t}\n\t\tif ( clipped ) discard;\n\t\n\t#endif
\n#endif\n";
var clipping_planes_pars_fragment = "#if NUM_CLIPPING_PLANES > 0\n\t#if ! defined( PHYSICAL ) && ! defined( PHONG )\n\t\tvarying vec3 vViewPosition;\n\t#endif\n\tuniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];\n#endif\n";
...
...
@@ -7200,6 +7200,7 @@
this.depthWrite = true;
this.clippingPlanes = null;
this.clipIntersection = false;
this.clipShadows = false;
this.colorWrite = true;
...
...
@@ -7463,6 +7464,7 @@
this.visible = source.visible;
this.clipShadows = source.clipShadows;
this.clipIntersection = source.clipIntersection;
var srcPlanes = source.clippingPlanes,
dstPlanes = null;
...
...
@@ -16406,6 +16408,7 @@
parameters.flipSided ? '#define FLIP_SIDED' : '',
'#define NUM_CLIPPING_PLANES ' + parameters.numClippingPlanes,
'#define UNION_CLIPPING_PLANES ' + (parameters.numClippingPlanes - parameters.numClipIntersection),
parameters.shadowMapEnabled ? '#define USE_SHADOWMAP' : '',
parameters.shadowMapEnabled ? '#define ' + shadowMapTypeDefine : '',
...
...
@@ -16645,7 +16648,7 @@
"maxMorphTargets", "maxMorphNormals", "premultipliedAlpha",
"numDirLights", "numPointLights", "numSpotLights", "numHemiLights",
"shadowMapEnabled", "shadowMapType", "toneMapping", 'physicallyCorrectLights',
"alphaTest", "doubleSided", "flipSided", "numClippingPlanes", "depthPacking"
"alphaTest", "doubleSided", "flipSided", "numClippingPlanes", "
numClipIntersection", "
depthPacking"
];
...
...
@@ -16717,7 +16720,7 @@
}
this.getParameters = function ( material, lights, fog, nClipPlanes, object ) {
this.getParameters = function ( material, lights, fog, nClipPlanes,
nClipIntersection,
object ) {
var shaderID = shaderIDs[ material.type ];
...
...
@@ -16794,6 +16797,7 @@
numHemiLights: lights.hemi.length,
numClippingPlanes: nClipPlanes,
numClipIntersection: nClipIntersection,
shadowMapEnabled: renderer.shadowMap.enabled && object.receiveShadow && lights.shadows.length > 0,
shadowMapType: renderer.shadowMap.type,
...
...
@@ -19205,6 +19209,7 @@
this.uniform = uniform;
this.numPlanes = 0;
this.numIntersection = 0;
this.init = function( planes, enableLocalClipping, camera ) {
...
...
@@ -19239,7 +19244,7 @@
};
this.setState = function( planes, clipShadows, camera, cache, fromCache ) {
this.setState = function( planes, clip
Intersection, clip
Shadows, camera, cache, fromCache ) {
if ( ! localClippingEnabled ||
planes === null || planes.length === 0 ||
...
...
@@ -19274,6 +19279,7 @@
}
cache.clippingState = dstArray;
this.numIntersection = clipIntersection ? this.numPlanes : 0;
this.numPlanes += nGlobal;
}
...
...
@@ -19291,6 +19297,7 @@
}
scope.numPlanes = numGlobalPlanes;
scope.numIntersection = 0;
}
...
...
@@ -19335,6 +19342,7 @@
}
scope.numPlanes = nPlanes;
return dstArray;
}
...
...
@@ -20851,7 +20859,7 @@
var materialProperties = properties.get( material );
var parameters = programCache.getParameters(
material, _lights, fog, _clipping.numPlanes, object );
material, _lights, fog, _clipping.numPlanes,
_clipping.numIntersection,
object );
var code = programCache.getProgramCode( material, parameters );
...
...
@@ -20954,6 +20962,7 @@
material.clipping === true ) {
materialProperties.numClippingPlanes = _clipping.numPlanes;
materialProperties.numIntersection = _clipping.numIntersection;
uniforms.clippingPlanes = _clipping.uniform;
}
...
...
@@ -21029,7 +21038,7 @@
// object instead of the material, once it becomes feasible
// (#8465, #8379)
_clipping.setState(
material.clippingPlanes, material.clipShadows,
material.clippingPlanes, material.clip
Intersection, material.clip
Shadows,
camera, materialProperties, useCache );
}
...
...
@@ -21051,7 +21060,8 @@
material.needsUpdate = true;
} else if ( materialProperties.numClippingPlanes !== undefined &&
materialProperties.numClippingPlanes !== _clipping.numPlanes ) {
( materialProperties.numClippingPlanes !== _clipping.numPlanes ||
materialProperties.numIntersection !== _clipping.numIntersection ) ) {
material.needsUpdate = true;
...
...
build/three.min.js
浏览文件 @
1d3b7f23
此差异已折叠。
点击以展开。
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录