troika-3d-text
Advanced tools
Comparing version 0.26.1 to 0.27.0
@@ -6,2 +6,18 @@ # Change Log | ||
# [0.27.0](https://github.com/protectwise/troika/compare/v0.26.1...v0.27.0) (2020-06-02) | ||
### Bug Fixes | ||
* **troika-3d-text:** prevent error when transpiling down to es5 ([7264b0c](https://github.com/protectwise/troika/commit/7264b0cee7aa5fc5df08102a77fbfc8f6be5ba3e)), closes [#51](https://github.com/protectwise/troika/issues/51) | ||
### Features | ||
* **troika-3d:** add three.js r117 to supported version range ([2761f39](https://github.com/protectwise/troika/commit/2761f39c272ecacd1dc0ce4f4cab8f166d373e90)) | ||
## [0.26.1](https://github.com/protectwise/troika/compare/v0.26.0...v0.26.1) (2020-05-26) | ||
@@ -8,0 +24,0 @@ |
{ | ||
"name": "troika-3d-text", | ||
"version": "0.26.1", | ||
"version": "0.27.0", | ||
"description": "Troika 3D Text", | ||
@@ -18,5 +18,5 @@ "author": "Jason Johnston <jason.johnston@protectwise.com>", | ||
"dependencies": { | ||
"troika-3d": "^0.26.0", | ||
"troika-three-utils": "^0.26.0", | ||
"troika-worker-utils": "^0.26.1" | ||
"troika-3d": "^0.27.0", | ||
"troika-three-utils": "^0.27.0", | ||
"troika-worker-utils": "^0.27.0" | ||
}, | ||
@@ -31,3 +31,3 @@ "devDependencies": { | ||
}, | ||
"gitHead": "da9622bb62a9c792e166fb1824c3012a7d9f9524" | ||
"gitHead": "964d4105d8fca15525459c3322351801c772dd9d" | ||
} |
@@ -19,3 +19,3 @@ /** | ||
function wrapFontObj([typrFont]) { | ||
function wrapFontObj(typrFont) { | ||
const glyphMap = Object.create(null) | ||
@@ -111,3 +111,3 @@ | ||
} | ||
return wrapFontObj(Typr.parse(buffer)) | ||
return wrapFontObj(Typr.parse(buffer)[0]) | ||
} | ||
@@ -114,0 +114,0 @@ } |
@@ -73,3 +73,3 @@ import { | ||
* consecutive glyphs: `{start:N, end:N, rect:[minX, minY, maxX, maxY]}`. This can be | ||
* used with `applyClipRect` to choose an optimized `maxInstancedCount`. | ||
* used with `applyClipRect` to choose an optimized `instanceCount`. | ||
* @param {Uint8Array} [glyphColors] - An array holding r,g,b values for each glyph. | ||
@@ -83,3 +83,3 @@ */ | ||
this._chunkedBounds = chunkedBounds | ||
this.maxInstancedCount = glyphAtlasIndices.length | ||
setInstanceCount(this, glyphAtlasIndices.length) | ||
@@ -98,3 +98,3 @@ // Update the boundingSphere based on the total bounds | ||
* Given a clipping rect, and the chunkedBounds from the last updateGlyphs call, choose the lowest | ||
* `maxInstancedCount` that will show all glyphs within the clipped view. This is an optimization | ||
* `instanceCount` that will show all glyphs within the clipped view. This is an optimization | ||
* for long blocks of text that are clipped, to skip vertex shader evaluation for glyphs that would | ||
@@ -123,3 +123,3 @@ * be clipped anyway. | ||
} | ||
this.maxInstancedCount = count | ||
setInstanceCount(this, count) | ||
} | ||
@@ -152,5 +152,10 @@ } | ||
// Handle maxInstancedCount -> instanceCount rename that happened in three r117 | ||
function setInstanceCount(geom, count) { | ||
geom[geom.hasOwnProperty('instanceCount') ? 'instanceCount' : 'maxInstancedCount'] = count | ||
} | ||
export { | ||
GlyphsGeometry | ||
} |
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
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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2006116
35572
+ Addedthree@0.117.1(transitive)
+ Addedtroika-3d@0.27.0(transitive)
+ Addedtroika-animation@0.27.0(transitive)
+ Addedtroika-core@0.27.0(transitive)
+ Addedtroika-three-utils@0.27.0(transitive)
+ Addedtroika-worker-utils@0.27.0(transitive)
- Removedthree@0.115.0(transitive)
- Removedtroika-3d@0.26.0(transitive)
- Removedtroika-animation@0.26.0(transitive)
- Removedtroika-core@0.26.0(transitive)
- Removedtroika-three-utils@0.26.0(transitive)
- Removedtroika-worker-utils@0.26.1(transitive)
Updatedtroika-3d@^0.27.0
Updatedtroika-three-utils@^0.27.0
Updatedtroika-worker-utils@^0.27.0