|
@@ -80,7 +80,6 @@ export class PBRMaterialDefines extends MaterialDefines
|
|
public ALPHAFRESNEL = false;
|
|
public ALPHAFRESNEL = false;
|
|
public LINEARALPHAFRESNEL = false;
|
|
public LINEARALPHAFRESNEL = false;
|
|
public PREMULTIPLYALPHA = false;
|
|
public PREMULTIPLYALPHA = false;
|
|
- public STRICTTRANSPARENCYMODE = false;
|
|
|
|
|
|
|
|
public EMISSIVE = false;
|
|
public EMISSIVE = false;
|
|
public EMISSIVEDIRECTUV = 0;
|
|
public EMISSIVEDIRECTUV = 0;
|
|
@@ -826,10 +825,6 @@ export abstract class PBRBaseMaterial extends PushMaterial {
|
|
* Specifies whether or not this material should be rendered in alpha blend mode.
|
|
* Specifies whether or not this material should be rendered in alpha blend mode.
|
|
*/
|
|
*/
|
|
public needAlphaBlending(): boolean {
|
|
public needAlphaBlending(): boolean {
|
|
- if (this.strictTransparencyMode) {
|
|
|
|
- return this._transparencyMode === Material.MATERIAL_ALPHABLEND || this._transparencyMode === Material.MATERIAL_ALPHATESTANDBLEND;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
if (this._disableAlphaBlending) {
|
|
if (this._disableAlphaBlending) {
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
@@ -841,10 +836,6 @@ export abstract class PBRBaseMaterial extends PushMaterial {
|
|
* Specifies whether or not this material should be rendered in alpha test mode.
|
|
* Specifies whether or not this material should be rendered in alpha test mode.
|
|
*/
|
|
*/
|
|
public needAlphaTesting(): boolean {
|
|
public needAlphaTesting(): boolean {
|
|
- if (this.strictTransparencyMode) {
|
|
|
|
- return this._transparencyMode === Material.MATERIAL_ALPHATEST || this._transparencyMode === Material.MATERIAL_ALPHATESTANDBLEND;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
if (this._forceAlphaTest) {
|
|
if (this._forceAlphaTest) {
|
|
return true;
|
|
return true;
|
|
}
|
|
}
|
|
@@ -860,10 +851,6 @@ export abstract class PBRBaseMaterial extends PushMaterial {
|
|
* Specifies whether or not the alpha value of the albedo texture should be used for alpha blending.
|
|
* Specifies whether or not the alpha value of the albedo texture should be used for alpha blending.
|
|
*/
|
|
*/
|
|
protected _shouldUseAlphaFromAlbedoTexture(): boolean {
|
|
protected _shouldUseAlphaFromAlbedoTexture(): boolean {
|
|
- if (this.strictTransparencyMode) {
|
|
|
|
- return this._useAlphaFromAlbedoTexture;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
return this._albedoTexture != null && this._albedoTexture.hasAlpha && this._useAlphaFromAlbedoTexture && this._transparencyMode !== PBRBaseMaterial.PBRMATERIAL_OPAQUE;
|
|
return this._albedoTexture != null && this._albedoTexture.hasAlpha && this._useAlphaFromAlbedoTexture && this._transparencyMode !== PBRBaseMaterial.PBRMATERIAL_OPAQUE;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -1495,8 +1482,6 @@ export abstract class PBRBaseMaterial extends PushMaterial {
|
|
|
|
|
|
defines.HORIZONOCCLUSION = this._useHorizonOcclusion;
|
|
defines.HORIZONOCCLUSION = this._useHorizonOcclusion;
|
|
|
|
|
|
- defines.STRICTTRANSPARENCYMODE = this._strictTransparencyMode;
|
|
|
|
-
|
|
|
|
// Misc.
|
|
// Misc.
|
|
if (defines._areMiscDirty) {
|
|
if (defines._areMiscDirty) {
|
|
MaterialHelper.PrepareDefinesForMisc(mesh, scene, this._useLogarithmicDepth, this.pointsCloud, this.fogEnabled, this._shouldTurnAlphaTestOn(mesh) || this._forceAlphaTest, defines);
|
|
MaterialHelper.PrepareDefinesForMisc(mesh, scene, this._useLogarithmicDepth, this.pointsCloud, this.fogEnabled, this._shouldTurnAlphaTestOn(mesh) || this._forceAlphaTest, defines);
|