XML:TSFF: Difference between revisions

28 bytes added ,  6 December 2023
m
no edit summary
m (correcting prev/next types in nav header)
mNo edit summary
(2 intermediate revisions by one other user not shown)
Line 4: Line 4:
*TSFF is a singleton global resource found in level0_Final.dat.
*TSFF is a singleton global resource found in level0_Final.dat.
*It describes a font family that Oni can use. The only font family available is Tahoma.
*It describes a font family that Oni can use. The only font family available is Tahoma.
*The glyph encoding is documented on [[OBD:Text encoding]].
*You can visualize the data in [http://mods.oni2.net/node/256 OniBrowser]. Be sure to also install the XNA package from Microsoft's website.
*You can visualize the data in [http://mods.oni2.net/node/256 OniBrowser]. Be sure to also install the XNA package from Microsoft's website.


==Hierarchy==
==Hierarchy==
TSFF instance
{{Tree list}}
  |
*TSFF instance
  +-- TSFL instance
**TSFL instance
  |
**TSFT instances
  +-- TSFT instances
***TSGA instances
      |
{{Tree list/end}}
      +-- TSGA instances


==TSFF tag==
==TSFF tag==
Line 191: Line 191:
|}
|}


Every TSGA file contains 256 elements. One element stands for one of the 256 signs of the ASCII table. The first 32 signs are reserved control characters, so these elements are always all-zero.
Every TSGA file contains 256 elements. Each element stands for one of the 256 glyphs, however the first 32 spaces are for non-printable control characters so these elements are always all-zero.


A glyph is basically a monochrome bitmap that's (width * height) pixels in size. Each pixel is stored in one byte in the TSFT file. (Fonts are antialiased, so shades of gray are needed rather than storing each pixel in one bit.) Each element in the TSFT file, being 32-bits, contains 4 pixels. The rows are not 32-bit aligned, so a new row of pixels can start inside an element.
A glyph is basically a grayscale bitmap which is (width * height) pixels in size. Each pixel is stored in one byte in the TSFT file. (Fonts are antialiased, so shades of gray are needed rather than storing each pixel in one bit.) Each element in the TSFT file, being 32 bits, contains 4 pixels, and a new row of pixels can start inside an element.


{{XML}}
{{XML}}
8,288

edits