24 Commits
v1.8 ... v1.9

Author SHA1 Message Date
minjaesong
3841611780 1.9 release 2021-03-15 19:56:53 +09:00
minjaesong
06bc8c9e2d forgot to update demo.png 2020-10-16 15:20:07 +09:00
minjaesong
21415c6f8d add: kerning sets for b and d 2020-10-06 16:31:24 +09:00
minjaesong
22c2a7aa52 fix: issue #12 2020-10-06 15:14:57 +09:00
minjaesong
0eb181f315 time to get off so i'll just commit this 2020-09-29 18:04:58 +09:00
minjaesong
45b431f953 fix: partial fix for issue #12 2020-09-29 14:07:35 +09:00
minjaesong
bbee554fec add: error msg for illegal linotype dimension 2020-09-29 11:36:59 +09:00
minjaesong
c4c67f489e fixing idiotic priority cache impl where they won't get younger 2020-05-04 00:09:05 +09:00
minjaesong
4d867d6523 replacing personalised test text 2020-05-03 23:42:06 +09:00
minjaesong
6620c11178 hangul: minor texture changes 2020-05-03 23:28:59 +09:00
minjaesong
db06cab07c cleaning up unnecessary functions 2020-05-03 22:26:45 +09:00
minjaesong
90b11cdd97 hangul: more microkerning shit 2020-05-03 20:34:12 +09:00
minjaesong
7bb92d1b4e hangul: some of the microkerning implemented in dirty way 2020-05-03 18:13:17 +09:00
minjaesong
b5dd744bd5 hangul: WEO to use wider initials just like WI and YI 2020-05-02 00:03:50 +09:00
minjaesong
34903b10d4 more hangul improvements 2020-05-01 17:12:13 +09:00
minjaesong
0c5b7c8b70 more letters for kerning charsets 2020-04-23 02:50:03 +09:00
minjaesong
cdffca98ef even more kerning pairs i can think of WIP 2020-04-23 01:16:18 +09:00
minjaesong
ce30d1d5fd major modification on hangul font 2020-04-23 01:02:57 +09:00
minjaesong
ab067044f8 more kerning pairs i can think of WIP 2020-04-21 05:17:19 +09:00
minjaesong
3e04b8bbe6 more kerning pairs WIP 2020-04-19 15:03:37 +09:00
minjaesong
4556a9e244 very crude kerning impl for Ys and Ts and AV-VA pairs 2020-04-14 23:56:08 +09:00
minjaesong
e5d04de250 character sets to use ints rather than chars 2020-04-14 23:45:35 +09:00
minjaesong
b7df181729 minor improvement on rotund r 2020-04-14 07:25:11 +09:00
minjaesong
2fd3fcfd46 support for LatinExt-D 2020-04-14 06:41:11 +09:00
70 changed files with 694 additions and 1335 deletions

0
.gitignore vendored Normal file → Executable file
View File

0
.idea/.name generated Normal file → Executable file
View File

0
.idea/artifacts/FontDemoGDX.xml generated Normal file → Executable file
View File

2
.idea/artifacts/TerrarumSansBitmap.xml generated Normal file → Executable file
View File

@@ -1,6 +1,6 @@
<component name="ArtifactManager"> <component name="ArtifactManager">
<artifact type="jar" name="TerrarumSansBitmap"> <artifact type="jar" name="TerrarumSansBitmap">
<output-path>$PROJECT_DIR$/FontTestGDX/lib</output-path> <output-path>$PROJECT_DIR$/lib</output-path>
<root id="archive" name="TerrarumSansBitmap.jar"> <root id="archive" name="TerrarumSansBitmap.jar">
<element id="module-output" name="BuildJAR_TerrarumSansBitmap" /> <element id="module-output" name="BuildJAR_TerrarumSansBitmap" />
<element id="directory" name="META-INF"> <element id="directory" name="META-INF">

0
.idea/codeStyles/Project.xml generated Normal file → Executable file
View File

0
.idea/codeStyles/codeStyleConfig.xml generated Normal file → Executable file
View File

0
.idea/kotlinc.xml generated Normal file → Executable file
View File

0
.idea/libraries/GdxLib.xml generated Normal file → Executable file
View File

9
.idea/libraries/KotlinJavaRuntime.xml generated Normal file → Executable file
View File

@@ -3,10 +3,19 @@
<CLASSES> <CLASSES>
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-runtime.jar!/" /> <root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-runtime.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-reflect.jar!/" /> <root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-reflect.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-stdlib.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-test.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-stdlib-jdk7.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-stdlib-jdk8.jar!/" />
</CLASSES> </CLASSES>
<JAVADOC /> <JAVADOC />
<SOURCES> <SOURCES>
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-runtime-sources.jar!/" /> <root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-runtime-sources.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-stdlib-sources.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-reflect-sources.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-test-sources.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-stdlib-jdk7-sources.jar!/" />
<root url="jar://$KOTLIN_BUNDLED$/lib/kotlin-stdlib-jdk8-sources.jar!/" />
</SOURCES> </SOURCES>
</library> </library>
</component> </component>

0
.idea/libraries/TesterLib.xml generated Normal file → Executable file
View File

0
.idea/markdown-navigator.xml generated Normal file → Executable file
View File

0
.idea/markdown-navigator/profiles_settings.xml generated Normal file → Executable file
View File

2
.idea/misc.xml generated Normal file → Executable file
View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8" project-jdk-type="JavaSDK"> <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="1.8.0_242" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/out" /> <output url="file://$PROJECT_DIR$/out" />
</component> </component>
</project> </project>

0
.idea/modules.xml generated Normal file → Executable file
View File

0
.idea/vcs.xml generated Normal file → Executable file
View File

1064
.idea/workspace.xml generated Normal file → Executable file

File diff suppressed because it is too large Load Diff

0
BuildJAR_TerrarumSansBitmap.iml Normal file → Executable file
View File

0
CONTRIBUTING.md Normal file → Executable file
View File

0
CONTRIBUTORS.txt Normal file → Executable file
View File

Binary file not shown.

1
FontTestGDX/FontTestGDX.iml Normal file → Executable file
View File

@@ -10,5 +10,6 @@
<orderEntry type="library" name="KotlinJavaRuntime" level="project" /> <orderEntry type="library" name="KotlinJavaRuntime" level="project" />
<orderEntry type="library" name="GdxLib" level="project" /> <orderEntry type="library" name="GdxLib" level="project" />
<orderEntry type="library" name="TesterLib" level="project" /> <orderEntry type="library" name="TesterLib" level="project" />
<orderEntry type="module" module-name="BuildJAR_TerrarumSansBitmap" />
</component> </component>
</module> </module>

2
FontTestGDX/META-INF/MANIFEST.MF Normal file → Executable file
View File

@@ -1,6 +1,6 @@
Manifest-Version: 1.0 Manifest-Version: 1.0
Class-Path: lib/gdx.jar lib/gdx-backend-lwjgl.jar lib/gdx-backend-lwjg Class-Path: lib/gdx.jar lib/gdx-backend-lwjgl.jar lib/gdx-backend-lwjg
l-natives.jar lib/gdx-natives.jar lib/kotlin-stdlib.jar TerrarumSansB l-natives.jar lib/gdx-natives.jar lib/kotlin-stdlib.jar lib/TerrarumSansB
itmap.jar itmap.jar
Main-Class: FontTestGDXKt Main-Class: FontTestGDXKt

0
FontTestGDX/src/FontTestGDX.kt Normal file → Executable file
View File

0
LICENSE.md Normal file → Executable file
View File

0
META-INF/MANIFEST.MF Normal file → Executable file
View File

0
PUA_allocation_chart.xlsx Normal file → Executable file
View File

0
README.md Normal file → Executable file
View File

0
alignment_illustration.jpg Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 59 KiB

After

Width:  |  Height:  |  Size: 59 KiB

0
assets/ascii_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 320 KiB

After

Width:  |  Height:  |  Size: 320 KiB

0
assets/cjkpunct.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 50 KiB

After

Width:  |  Height:  |  Size: 50 KiB

0
assets/cyrilic_bulgarian_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

0
assets/cyrilic_serbian_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

0
assets/cyrilic_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 380 KiB

After

Width:  |  Height:  |  Size: 380 KiB

0
assets/devanagari_bengali_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 320 KiB

After

Width:  |  Height:  |  Size: 320 KiB

0
assets/diacritical_marks_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 140 KiB

After

Width:  |  Height:  |  Size: 140 KiB

0
assets/fullwidth_forms.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

0
assets/futhark.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 68 KiB

After

Width:  |  Height:  |  Size: 68 KiB

0
assets/greek_polytonic_xyswap_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 320 KiB

After

Width:  |  Height:  |  Size: 320 KiB

0
assets/greek_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 MiB

After

Width:  |  Height:  |  Size: 2.6 MiB

0
assets/hayeren_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

BIN
assets/insular_variable.tga Normal file → Executable file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

0
assets/ipa_ext_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 220 KiB

After

Width:  |  Height:  |  Size: 220 KiB

0
assets/kana.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 210 KiB

After

Width:  |  Height:  |  Size: 210 KiB

0
assets/kartuli_allcaps_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 60 KiB

0
assets/kartuli_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

0
assets/latinExt_additional_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 320 KiB

After

Width:  |  Height:  |  Size: 320 KiB

0
assets/puae000-e0ff.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 324 KiB

After

Width:  |  Height:  |  Size: 324 KiB

0
assets/richtext_furigana.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 24 KiB

0
assets/thai_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

0
assets/tsalagi_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

0
assets/unipunct_variable.tga Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 200 KiB

After

Width:  |  Height:  |  Size: 200 KiB

0
assets/wenquanyi.tga.gz Normal file → Executable file
View File

BIN
demo.PNG Normal file → Executable file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 KiB

After

Width:  |  Height:  |  Size: 146 KiB

14
demotext.txt Normal file → Executable file
View File

@@ -3,16 +3,16 @@
There are many bitmap fonts on the internet. You care for the multilingual support, but alas! There are many bitmap fonts on the internet. You care for the multilingual support, but alas!
most of them do not support your language, vector fonts take too much time to load, and even most of them do not support your language, vector fonts take too much time to load, and even
then their legibility suffers because fuck built-in antialias. then their legibility suffers because screw built-in antialias.
You somehow found a multilingual one, and it makes your game look like an old computer, and you say: You somehow found a multilingual one, and it makes your game look like an old computer, and you say:
“Well, better than nothing… no, its ugly.” “Well, better than nothing… no, its ugly.”
You speak japanese and you wish to support it, but then このクソなfont only goot for displaying You speak japanese and you wish to support it, but then このクソなfont only good for displaying
Japanese, its not even multilingual, and their English look uncanny and inconsistent as hell. Japanese, its not even truly multilingual, and their English look uncanny and inconsistent.
Eventually you just mix different fonts together, and the results were always infuriating. Eventually you just mix different fonts together, and the results were always mildly infuriating.
No more suffering. This font has everything you need. No more suffering. This font has everything you need.
@@ -41,7 +41,7 @@ How multilingual? Real multilingual!
􏻬სწრაფი ყავისფერი მელა გადაახტა ზარმაც ძაღლს ᲘᲜᲢᲔᲚ ᲞᲔᲜᲢᲘᲣᲛᲘ ᲛᲘᲙᲠᲝᲞᲠᲝᲪᲔᲡᲝᲠᲘ􀀀 􏻬სწრაფი ყავისფერი მელა გადაახტა ზარმაც ძაღლს ᲘᲜᲢᲔᲚ ᲞᲔᲜᲢᲘᲣᲛᲘ ᲛᲘᲙᲠᲝᲞᲠᲝᲪᲔᲡᲝᲠᲘ􀀀
􏻬ऋषियों को सताने वाले दुष्ट राक्षसों के राजा रावण का सर्वनाश करने वाले विष्णुवतार भगवान श्रीराम अयोध्या के महाराज दशरथ के􀀀 􏻬ऋषियों को सताने वाले दुष्ट राक्षसों के राजा रावण का सर्वनाश करने वाले विष्णुवतार भगवान श्रीराम अयोध्या के महाराज दशरथ के􀀀
􏻬Kæmi ný öxi hér, ykist þjófum nú bæði víl og ádrepa􀀀 􏻬Kæmi ný öxi hér, ykist þjófum nú bæði víl og ádrepa􀀀
􏻬Ċuaiġ bé ṁórṡáċ le dlúṫspád fíorḟinn trí hata mo ḋea-ṗorcáin ḃig􀀀 􏻬Ċuaiġ bé ṁórṡáċ le dlúṫspád fíoḟinn trí hata mo ḋea-ṗocáin ḃig􀀀
􏻬あめつちほしそら やまかはみねたに くもきりむろこけ ひといぬうへすゑ ゆわさるおふせよ えの𛀁をなれゐて􀀀 􏻬あめつちほしそら やまかはみねたに くもきりむろこけ ひといぬうへすゑ ゆわさるおふせよ えの𛀁をなれゐて􀀀
􏻬トリナクコヱス ユメサマセ ミヨアケワタル ヒンカシヲ ソライロハエテ オキツヘニ ホフネムレヰヌ モヤノウチ􀀀 􏻬トリナクコヱス ユメサマセ ミヨアケワタル ヒンカシヲ ソライロハエテ オキツヘニ ホフネムレヰヌ モヤノウチ􀀀
􏻬田居に出で 菜摘むわれをぞ 君召すと 求食り追ひゆく 山城の 打酔へる子ら 藻葉干せよ え舟繋けぬ􀀀 􏻬田居に出で 菜摘むわれをぞ 君召すと 求食り追ひゆく 山城の 打酔へる子ら 藻葉干せよ え舟繋けぬ􀀀
@@ -109,8 +109,8 @@ How multilingual? Real multilingual!
Cyrillic Supplement Armenian Devanagari Bengali Thai Georgian Hangul Jamo Cherokee Runic Cyrillic Supplement Armenian Devanagari Bengali Thai Georgian Hangul Jamo Cherokee Runic
Georgian Extended Greek Extended General Punctuations Superscripts and Subscripts CJK Symbols Georgian Extended Greek Extended General Punctuations Superscripts and Subscripts CJK Symbols
Latin Extended-C Kana Hangul Compatibility Jamo Kana Phonetic Extensions CJK Unihan Extension A Latin Extended-C Kana Hangul Compatibility Jamo Kana Phonetic Extensions CJK Unihan Extension A
CJK Unihan Hangul Jamo Extended-A Hangul Syllables Hangul Jamo Extended-B Fullwidth Forms CJK Unihan Latin Extended-D Hangul Jamo Extended-A Hangul Syllables Hangul Jamo Extended-B
Kana Supplement Fullwidth Forms Kana Supplement
GitHubs issue page is open! You can report any 􏽕errors􀀀, or leave 􏽕suggestions􀀀. GitHubs issue page is open! You can report any 􏽕errors􀀀, or leave 􏽕suggestions􀀀.
You can help this font to be more versatile. (for more languages, more frameworks) 􏽕Clone􀀀 this repo, make You can help this font to be more versatile. (for more languages, more frameworks) 􏽕Clone􀀀 this repo, make

0
font_drawing_template.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

0
glyph_height_pos_annotation.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 18 KiB

0
samples/README.md Normal file → Executable file
View File

0
samples/wikipedia_x86.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 75 KiB

After

Width:  |  Height:  |  Size: 75 KiB

0
src/net/torvald/terrarumsansbitmap/GlyphProps.kt Normal file → Executable file
View File

874
src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt Normal file → Executable file

File diff suppressed because it is too large Load Diff

View File

@@ -25,14 +25,15 @@
package net.torvald.terrarumsansbitmap.gdx package net.torvald.terrarumsansbitmap.gdx
import com.badlogic.gdx.files.FileHandle import com.badlogic.gdx.files.FileHandle
import com.badlogic.gdx.graphics.Color
import com.badlogic.gdx.graphics.Pixmap import com.badlogic.gdx.graphics.Pixmap
/** /**
* Breaks one pixmap atlas into many child pixmaps
*
* Created by minjaesong on 2018-09-17. * Created by minjaesong on 2018-09-17.
*/ */
class PixmapRegionPack( class PixmapRegionPack(
pixmap: Pixmap, pixmapAtlas: Pixmap,
val tileW: Int, val tileW: Int,
val tileH: Int, val tileH: Int,
val hGap: Int = 0, val hGap: Int = 0,
@@ -47,8 +48,8 @@ class PixmapRegionPack(
constructor(fileHandle: FileHandle, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0, xySwapped: Boolean = false) : constructor(fileHandle: FileHandle, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0, xySwapped: Boolean = false) :
this(Pixmap(fileHandle), tileW, tileH, hGap, vGap, hFrame, vFrame, xySwapped) this(Pixmap(fileHandle), tileW, tileH, hGap, vGap, hFrame, vFrame, xySwapped)
val horizontalCount = (pixmap.width - 2 * hFrame + hGap) / (tileW + hGap) val horizontalCount = (pixmapAtlas.width - 2 * hFrame + hGap) / (tileW + hGap)
val verticalCount = (pixmap.height - 2 * vFrame + vGap) / (tileH + vGap) val verticalCount = (pixmapAtlas.height - 2 * vFrame + vGap) / (tileH + vGap)
val regions: Array<Pixmap> val regions: Array<Pixmap>
@@ -70,10 +71,10 @@ class PixmapRegionPack(
pixmap.pixels.rewind() pixmapAtlas.pixels.rewind()
if (!xySwapped) { if (!xySwapped) {
regions = Array<Pixmap>(horizontalCount * verticalCount, { regions = Array<Pixmap>(horizontalCount * verticalCount) {
val rx = (it % horizontalCount * (tileW + hGap)) + hFrame // pixel, not index val rx = (it % horizontalCount * (tileW + hGap)) + hFrame // pixel, not index
val ry = (it / horizontalCount * (tileH + vGap)) + vFrame // pixel, not index val ry = (it / horizontalCount * (tileH + vGap)) + vFrame // pixel, not index
@@ -84,15 +85,15 @@ class PixmapRegionPack(
// for every "scanline" // for every "scanline"
for (y in 0 until tileH) { for (y in 0 until tileH) {
val offsetY = (ry + y) * (pixmap.width * 4) + (vFrame * pixmap.width * 4) val offsetY = (ry + y) * (pixmapAtlas.width * 4) + (vFrame * pixmapAtlas.width * 4)
val offsetX = rx * 4 + hFrame * 4 val offsetX = rx * 4 + hFrame * 4
//println("offset: ${offsetX + offsetY}") //println("offset: ${offsetX + offsetY}")
val bytesBuffer = ByteArray(4 * tileW) val bytesBuffer = ByteArray(4 * tileW)
pixmap.pixels.position(offsetY + offsetX) pixmapAtlas.pixels.position(offsetY + offsetX)
pixmap.pixels.get(bytesBuffer, 0, bytesBuffer.size) pixmapAtlas.pixels.get(bytesBuffer, 0, bytesBuffer.size)
// test print bytesbuffer // test print bytesbuffer
/*bytesBuffer.forEachIndexed { index, it -> /*bytesBuffer.forEachIndexed { index, it ->
@@ -112,10 +113,10 @@ class PixmapRegionPack(
// todo globalFlipY ? // todo globalFlipY ?
/*return*/region /*return*/region
}) }
} }
else { else {
regions = Array<Pixmap>(horizontalCount * verticalCount, { regions = Array<Pixmap>(horizontalCount * verticalCount) {
val rx = (it / verticalCount * (tileW + hGap)) + hFrame val rx = (it / verticalCount * (tileW + hGap)) + hFrame
val ry = (it % verticalCount * (tileH + vGap)) + vFrame val ry = (it % verticalCount * (tileH + vGap)) + vFrame
@@ -126,15 +127,15 @@ class PixmapRegionPack(
// for every "scanline" // for every "scanline"
for (y in 0 until tileH) { for (y in 0 until tileH) {
val offsetY = (ry + y) * (pixmap.width * 4) + (vFrame * pixmap.width * 4) val offsetY = (ry + y) * (pixmapAtlas.width * 4) + (vFrame * pixmapAtlas.width * 4)
val offsetX = rx * 4 + hFrame * 4 val offsetX = rx * 4 + hFrame * 4
//println("offset: ${offsetX + offsetY}") //println("offset: ${offsetX + offsetY}")
val bytesBuffer = ByteArray(4 * tileW) val bytesBuffer = ByteArray(4 * tileW)
pixmap.pixels.position(offsetY + offsetX) pixmapAtlas.pixels.position(offsetY + offsetX)
pixmap.pixels.get(bytesBuffer, 0, bytesBuffer.size) pixmapAtlas.pixels.get(bytesBuffer, 0, bytesBuffer.size)
// test print bytesbuffer // test print bytesbuffer
/*bytesBuffer.forEachIndexed { index, it -> /*bytesBuffer.forEachIndexed { index, it ->
@@ -154,7 +155,7 @@ class PixmapRegionPack(
// todo globalFlipY ? // todo globalFlipY ?
/*return*/region /*return*/region
}) }
} }
} }

View File

0
src/net/torvald/terrarumsansbitmap/readme.md Normal file → Executable file
View File

0
terrarum_sans_cyrillic_2.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

BIN
testing.PNG Normal file → Executable file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 58 KiB

24
testtext.txt Normal file → Executable file
View File

@@ -1,10 +1,16 @@
re ʘ, ʇ, ʗ, and ʖ, al To
ɓ ɗ ɠ uu
ɐ ɔ ə ɟ ɥ ɯ ɹ ʇ ʌ ʍ ʎ Td
Vʷ[kʰuˣt̪s̟] and Vʷ[kʰʉˣt͜ʃ]. mm
Ye
Yd
ʡ̆ /œ̃/
/ɛ̃/
Labiodental flap [ⱱ] U+2C71
acegijmnopqrsuvwxyzɱɳʙɾɽʒʂʐʋɹɻɥɟɡɢʛȵɲŋɴʀɕʑçʝxɣχʁʜʍɰʟɨʉɯuʊøɘɵɤəɛœɜɞʌɔæɐɶɑɒɚɝɩɪʅʈʏʞⱥⱦⱱⱳⱴⱶⱷⱸⱺⱻ /ẽ
when the line ends with a diacritics, whole letter wont render
if the line starts with a letter-with-diacritic, it will error out

0
width_bit_encoding_annotated.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 18 KiB