generated from napi-rs/package-template
-
-
Notifications
You must be signed in to change notification settings - Fork 79
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
130c4c6
commit f11514c
Showing
18 changed files
with
299 additions
and
266 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,15 +3,17 @@ const { join } = require('path') | |
|
||
const { createCanvas, GlobalFonts } = require('../index.js') | ||
|
||
GlobalFonts.registerFromPath(join(__dirname, '..', '__test__', 'fonts', '[email protected]'), 'Apple Emoji') | ||
GlobalFonts.registerFromPath(join(__dirname, '..', '__test__', 'fonts', '[email protected]'), 'Apple Color Emoji') | ||
GlobalFonts.registerFromPath(join(__dirname, '..', '__test__', 'fonts', 'COLRv1.ttf'), 'COLRv1') | ||
|
||
console.info(GlobalFonts.families) | ||
GlobalFonts.families.forEach(({ family }) => { | ||
console.info(family) | ||
}) | ||
|
||
const canvas = createCanvas(760, 360) | ||
const ctx = canvas.getContext('2d') | ||
|
||
ctx.font = '50px Apple Emoji' | ||
ctx.font = '50px Apple Color Emoji' | ||
ctx.strokeText('😀😃😄😁😆😅😂🤣☺️😊😊😇', 50, 150) | ||
|
||
ctx.font = '100px COLRv1' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule skia
updated
1509 files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
f11514c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Benchmark
Draw house#skia-canvas
21.9
ops/sec (±1.13%
)24
ops/sec (±0.1%
)1.10
Draw house#node-canvas
19.8
ops/sec (±0.95%
)26
ops/sec (±0.28%
)1.31
Draw house#@napi-rs/skia
20.5
ops/sec (±0.97%
)23
ops/sec (±0.54%
)1.12
Draw gradient#skia-canvas
20.5
ops/sec (±0.95%
)22.7
ops/sec (±0.21%
)1.11
Draw gradient#node-canvas
18.7
ops/sec (±0.6%
)25.2
ops/sec (±0.28%
)1.35
Draw gradient#@napi-rs/skia
19.4
ops/sec (±1.25%
)22.6
ops/sec (±0.09%
)1.16
This comment was automatically generated by workflow using github-action-benchmark.