Forwarded from ☕️ Мерлин заваривает τσάι 🐌
Функция, которую можно вызывать не более чем N раз с проверкой количества вызовов на уровне компиляции
#rust
https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=45f165c0c0f6146cf3c7a1e0743f635e
#rust
https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=45f165c0c0f6146cf3c7a1e0743f635e
play.rust-lang.org
Rust Playground
A browser interface to the Rust compiler to experiment with the language
🔥3🤯2🤔1
Forwarded from HN Best Comments
Re: Tetris Font
I did kinda the opposite and instead of making a font out of tetris I made a font play Tetris.
I did it with the Harfbuzz shaper which now have experimental support for embedding WebAssembly programs to shape fonts.
Talk where I show it off: https://www.youtube.com/watch?v=Ms1Drb9Vw9M
Source code: https://github.com/Erk-/programmable-fonts
You can also see actual uses of this WebAssembly embedding to show that is not just for fun here: https://github.com/harfbuzz/harfbuzz-wasm-examples
erk__, 8 hours ago
I did kinda the opposite and instead of making a font out of tetris I made a font play Tetris.
I did it with the Harfbuzz shaper which now have experimental support for embedding WebAssembly programs to shape fonts.
Talk where I show it off: https://www.youtube.com/watch?v=Ms1Drb9Vw9M
Source code: https://github.com/Erk-/programmable-fonts
You can also see actual uses of this WebAssembly embedding to show that is not just for fun here: https://github.com/harfbuzz/harfbuzz-wasm-examples
erk__, 8 hours ago
YouTube
Programmable fonts with Rust by Valdemar Erk
#rust #rustlang #programming
00:00:00 Outline
00:00:29 History of fonts
00:07:12 Computer fonts
00:10:06 Text shaping
00:16:11 Animation* with fonts
00:19:34 Computer games in a font
00:26:42 Q: What can programmable fonts do that wasn't possible before?…
00:00:00 Outline
00:00:29 History of fonts
00:07:12 Computer fonts
00:10:06 Text shaping
00:16:11 Animation* with fonts
00:19:34 Computer games in a font
00:26:42 Q: What can programmable fonts do that wasn't possible before?…