한글패치 관련 짧은 글들

unity 2019.4.0f1 폰트 atlas 가로 세로값 (hex)

Snowyegret 2021. 6. 28. 19:21

hex부분을 이용하여 sdf폰트 atlas의 전체 가로 세로 값을 알아보기 위해 uabe를 이용하였다.

UABE가 현재 지원되지 않으니 UAAE나 UABEA를 이용하면 확인 가능

 

방법: 테스트용 유니티 빌드(4096x4096, 8192x8192, 4096x8192)를 이용,

1. 4096x4096 파일의 원본 monobehaviour를 export to raw / monobehaviour 버튼 후 export를 이용하여 추출한 후,

2. UABE를 통한 export dump to txt -> 메모장에서 값을 1234x5678로 수정 -> import dump

3. 1번의 방법을 이용하여 수정 후의 monobehaviour파일과 TMPro_Fontasset파일을 추출

4. hxd를 이용하여 데이터 비교

 

결과:

차이점이 처음 발견된 부분. byteflip을 이용하면 1000(16) = 4096(10) / 04D2(16) = 1234(10)
00 00 바이트 이후 연속된 부분, 1000(16) = 4096(10) / 162E(16) = 5678(10)

 

 

기존 유니티 한글화 강좌를 읽어보면 dds파일의 너비와 높이가 바이너리 값으로 표현되어 있다고 나와 있으나,

버전이 올라가서 그런지 표시가 달라졌다는 것을 알 수 있었다.

그냥 단순하게 10진법 -> 16진법으로 바이트플립하여 작성되어 있다는 것을 알 수 있었다.

 

 

 

참고한 사이트:

ieee754

https://www.h-schmidt.net/FloatConverter/IEEE754.html

 

IEEE-754 Floating Point Converter

IEEE-754 Floating Point Converter Translations: de This page allows you to convert between the decimal representation of numbers (like "1.02") and the binary format used by all modern CPUs (IEEE 754 floating point). Update There has been an update in the w

www.h-schmidt.net

https://tools.m-bsys.com/calculators/ieee754.php

 

浮動小数点数内部表現シミュレーター - instant tools

 

tools.m-bsys.com

 

 

dec to hex / hex to dec

https://www.binaryhexconverter.com/decimal-to-hex-converter

 

Decimal to Hexadecimal Converter

Decimal to Hexadecimal Converter To use this decimal to hex converter tool, you have to type a decimal value like 79 into the left field below, and then hit the Convert button. Therefore, you can convert up to 19 decimal characters (max. value of 922337203

www.binaryhexconverter.com