Jump to content
The Dark Mod Forums

Zbyl

Member
  • Content Count

    37
  • Joined

  • Last visited

  • Days Won

    1

Zbyl last won the day on February 1 2013

Zbyl had the most liked content!

Community Reputation

8 Neutral

About Zbyl

  • Rank
    Member
  1. If you'd like to check out the "decompose" function you'd need it.
  2. Here it is: https://docs.google.com/file/d/0B0pkDNTfAmoedHZvT1VJV2tpbGs/edit?usp=sharing Required DLL: https://docs.google....dit?usp=sharing Also remember to install: ImageMagick-6.8.6-8-Q16-x86-dll.exe (or x64 - I'm not sure). Edit: This tool has a simple GUI now - when run without parameters.
  3. Update on my work: - Unicode language files work ok, - BFG fonts now render similarily as the old fonts. It's not pixel perfect, but close. - I've created a tool to create BFG fonts (https://github.com/Zbyl/BFGFontTool). It has some support for porting old Doom 3 fonts to new Doom 3 BFG fonts. The code is not entirely final, but since the interest in those features is low my work on this is done for now. If anyone will be interested in this code - let me know.
  4. I've implemented generation of fake old .dat files during creation of a BFG font, but it turns out they won't be good enough to use in the GUI editor. It turned out that generation of scaled fonts is a complex task. Even more difficult considering that they have to satisfy additional constraints that Doom 3 BFG impose. In other words - too much work to be worth the effort.
  5. For TDM it would not be necessary. Old fonts can be changed into BFG fonts with legacy_sizes.dat. And new fonts will have auto-generated legacy_sizes.dat files. Moreover some font files, like stone font for example, do not adhere to the specification. They have a hack embedded to circumvent old .dat file limitations. It would be counter-productive for me to try and re-implement those hacks. I could try to make a simple, no-hack, exporter - but I don't see a use for it. Edit: What do you need old Doom 3 fonts for?
  6. I know it uses Flash for menus, and old GUI for surfaces. But in both of them it uses .dat files exclusively. No TTFs, nor OTFs are used. Old Doom GUI made with old tools will work with new fonts. Wheather they will work in Doom 3 BFG out of the box - probably. But that's another matter, which I'm not concerned with at the moment. No. What I'm saying is this: either old .dat files, or new legacy_sizes.dat file is necessary for fonts to be scaled properly.
  7. BFG uses old .dat files for one thing only: taking the maxCharWidth and maxCharHeight from them. Nothing else. 100% certain. BFG fonts are self contained. Old maxCharWidth and maxCharHeight are used to figure out how to scale the new font to be the same size as the old font. Nothing else. Rendering dosen't use old .dat files at all. If GUI Editor uses old font system - then it's probably because it wasn't updated. After all Doom 3 BFG uses Flash for all new GUI, and the scaling-compatibility-layer ensures that even GUI made with old editor will display properly in game.
  8. It's either: - 3 old .dat files, 1 new .dat file and 1 new TGA atlas, or: - 1 new .dat file, 1 new TGA atlas and 1 new "legacy_sizes.dat" file. Both work. If compatibility was not a problem then I'd do a much cleaner solution without "legacy_sizes.dat" nor old .dat files. But it seems it's out of question. However - for any new fonts the compatibility layer will be bypassed. It'll be much easier for font makers and gui designers. BTW.: Is it possible to get the stone font in TTF or OTF format?
  9. I use old .dat files to read information about their size. Then I save it on the side in a helper file, and don't use old .dat files ever again, for anything.
  10. What I've done so far: - ported BFG font rendering code to D3, - ported "stone" font to D3 BFG format, - implemented compatibility functions to adjust font scale, - potrted BFG LangDict to D3 so all languages now support Unicode. Here's a link to the picture (I don't have permission to insert an image): https://docs.google....dit?usp=sharing There a two problems that I can see: - in main menu and on lists of missions some letters have descenders cut (problem with font scale?), - in main menu the character "o with accent" is weirdly positioned. I haven't yet compared it with the unmodified TDM.
  11. Such one-pixel-here-and-there inaccuracies are bound to happen. idFont and BMFont render the fonts slightly differently. id uses it's own font rendering and BMFont uses standard Windows rendering. Things like antialiasing type, hints, clear type etc. will produce slightly different results. There's no way to copy idFont's output with bit-to-bit precision. What we have is probably as close as we can get. And it's close enough IMHO. Edit: "to" word in the next line is a result of such one-pixel inaccuracies.
  12. Not exact yet. Close enough though. (We should probably generate fonts from outline and turn off true type hinting.) As for your error: FileNotFoundException. Maybe "48.ftn" should be "48.fnt"? Also you could try giving absolute paths to make sure. I'm satisfied with the outcome so far. I'll try to do some TDM coding to try and make new fonts visually compatible with the old ones.
  13. I've uploaded your font's .dat file here: https://drive.google.com/folderview?id=0B0pkDNTfAmoeOUZRWkYxMzBOSVU&usp=sharing It does not match the parameters in original font from BFG exactly: descender is -10, in original it's -11. But descender is not used in font rendering. So the output, hopefuly, will be the same. I've also created my own, alternative, parameters. My font is here: https://drive.google.com/folderview?id=0B0pkDNTfAmoeRktUOElCRHlRZ00&usp=sharing I think it's slightly worse (ascender is 46 instead of 45 - but ascender is actually used during rendering), but you can check it out too. It has bigger spacing (4 pixels) so there should be no "boxing" artifacts. I don't think we can get any better results with BMFont (it supports only integer font sizes). But I don't think it's needed. I'm pretty sure you can compile my tool using VS2010 Express, or using gcc under Linux (should work on Mono without problems... except for the optional ImageMagick stuff). I've also uploaded my tool under the first link. It's not overly useful, though.
  14. Yes. My font has different ascender, descender and scale. But how to compute those values exactly as idFont does - I'll have to dig some more.
×
×
  • Create New...