troika-three-text
Advanced tools
Comparing version 0.34.0-textoutline.4 to 0.34.0-textoutline.5
{ | ||
"name": "troika-three-text", | ||
"version": "0.34.0-textoutline.4+ac3d583", | ||
"version": "0.34.0-textoutline.5+6830461", | ||
"description": "SDF-based text rendering for Three.js", | ||
@@ -28,3 +28,3 @@ "author": "Jason Johnston <jason.johnston@protectwise.com>", | ||
}, | ||
"gitHead": "ac3d5839c9eec254640941063ab42c40eb14210d" | ||
"gitHead": "68304611684615371f046cd2f7e1053413af263f" | ||
} |
@@ -355,3 +355,7 @@ import { | ||
this.sync() | ||
this._prepareForRender(material) | ||
// This may not always be a text material, e.g. if there's a scene.overrideMaterial present | ||
if (material.isTroikaTextMaterial) { | ||
this._prepareForRender(material) | ||
} | ||
} | ||
@@ -401,3 +405,5 @@ | ||
if (!outlineMaterial) { | ||
outlineMaterial = derivedMaterial._outlineMtl = derivedMaterial.clone() | ||
outlineMaterial = derivedMaterial._outlineMtl = Object.create(derivedMaterial, { | ||
id: {value: derivedMaterial.id + 0.1} | ||
}) | ||
outlineMaterial.isTextOutlineMaterial = true | ||
@@ -451,2 +457,3 @@ outlineMaterial.depthWrite = false | ||
let distanceOffset = 0 | ||
if (isOutline) { | ||
@@ -459,4 +466,5 @@ let {outlineWidth} = this | ||
} | ||
uniforms.uTroikaDistanceOffset.value = outlineWidth | ||
distanceOffset = outlineWidth | ||
} | ||
uniforms.uTroikaDistanceOffset.value = distanceOffset | ||
@@ -463,0 +471,0 @@ let clipRect = this.clipRect |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
1586207
25760