Jump to content
The Dark Mod Forums

motorsep

Member
  • Posts

    913
  • Joined

  • Last visited

  • Days Won

    2

Posts posted by motorsep

  1. Hmm.. Tried your font, no good: http://i.imgur.com/9pF5AA4.png

     

    Oh, you need alpha to be "glyph" and RGB "one".

     

    Got some interesting info, I hope it'll help: "The BFG (and Rage) font system is relatively simple. The exporter is only a few hundred lines total. It doesn't use kerning information at all. Each glyph just has an x, y, width, height, and an xSkip value. I believe the ascender/descender data from the font is not used, but rather it's calculated manually, but I don't remember for sure anymore."

  2. What I did was exporting bunch of variants and matching glyph heights. So the TGA atlas I provided matched the output produced by idFont +-1 px. So now what's important is to produce proper .dat file. It will not match exactly with the one produced by idFont. But as long as all relevant info is in it, it should work.

     

    Also, BMFont has size in pixels. Pixels can't really be float ;) 1px is 1px So the atlas is file. It's how you convert fnt file into dat file.

     

    EDIT: Almost there ! Awesome results: http://www.steel-storm.com/files/d3bfg_ArialNarrow_font_comparison_A.zip

     

    Next, I am going to test with your alternative variant (the screenshots are with my atlas and dat file you generated using my .fnt)

  3. I experimented some with exporting font from BMFont, and I think I matched the size of original BFG glyphs. Could you please try converting my test and upload .dat file for me to test, as I don't have C# to compile your code ?

     

    http://www.steel-sto...bft_an_test.zip

     

    Thanks.

     

    EDIT: Afaik BFG's dat file has no info about kerning, as it relies on kerning in Doom 3 .dat files. But I might be wrong.

  4. I've created an ArialNarrow font that should work. I'm not sure if the scale will be ok though. https://drive.google...ejg&usp=sharing

    I've attached BMFont's config and .fnt that I used to create this font too.

     

    Ok, tested. Here are the comparison screenshots: http://www.steel-storm.com/files/d3bfg_ArialNarrow_font_comparison.zip

     

    Generally speaking, it's a very good start! However, as you can see, there are issues. Font size doesn't match up, somehow there are white boxes around glyphs (_09.tga; terminal GUI on Mars City 1 at the very beginning right off the drop ship) and it's totally screwed up in PDA.

  5. Yep. I convert the text version of the descriptor into a BFG .dat. Probably converting XML descriptor would be easier, but I just didn't thought of it.

    Sure I'll share the code - but at the moment it's rather messy. And in C#. I'll clean it up a tiny bit first.

     

    As for testing my font in BFG - sadly I can't do that, since I don't own BFG... I only have the code to play with.

     

    Thanks! Ahh, C#.. I hope we can convert it into C++ :)

     

    If you can send me ArialNarrow converted with your method, I can test it here (.tga and .dat is what I need).

  6. My test Gothic font is here: https://drive.google...N1U&usp=sharing

    BFG .dat is of course in a different format than D3 .dat. The TGA is generated by BMFont - I didn't make any chages to it.

    BFG fonts are different for example in that they use only one big texture per font, not many like in D3. This is not a problem these days when big textures are universaly supported.

     

    Ahh, I see. So font atlas is of the power of two, while original BFG atlases are non-power of two. BFG's glyphs are packed very tightly, rotated/mirrored if needed to fit more characters in one atlas. I suppose it doesn't really matter for regular fonts, but for Japanese/Korean/Chinese fonts just square atlas would be huge :/

     

    Have you tested if your font works with BFG (converting ArialNarrow into BFG's font and replacing the original ArialNarrow that comes with BFG) ? If not, and you don't really know how, I can test it if you can convert ArialNarrow.

     

    Do you convert glyphs descriptor generated by BMFont into .dat file? If so, can you please share the code of your converter?

  7. Like I said: I use BMFont and my custom converter from BMFont to BFG fonts.

     

    BMFont's page shows 404. As far as I remember, BMFont generated glyph atlas from TTF fonts. How do you generate .dat file for BFG? Can you upload the final BFG font you generated, using BMFont and your secret tool, so I could look at TGA atlas and .dat file, please?

     

    They do replace the original font system (they need original fonts only to know what their maxCharWidth/maxCharHeight is to know how to scale new fonts into old GUI). This is in the code - no guesses here.

     

    Right, they didn't replace it. You can still use old fonts with BFG, or just new font. However, it's be off. Replacing means you can use new font without screwing GUIs. They added new font system without removing old one.

     

    EDIT: http://www.angelcode.com/products/bmfont/ works, which doesn't solve the issue of generating proper .dat files

  8. @Zbyl: What tool do you use to generate BFG fonts?

     

    BFG's fonts improvements were meant to improve Doom 3 fonts - make them of higher resolution and allow for extra characters, that's all. They were not a replacement for original font system. That's why BFG's fonts need old font .dat files to map new characters over them.

  9. So I decided to replace _default material with caulk and change material folder from "materials" to "materials_v1".

     

    .game file has those fields and I assumed that DR uses those dynamically. However, changing those setting yields no results. When new brush is created, it still gets _default material assigned and all materials are read from base/materials/ regardless what folder name I use in the .game file settings.

     

    Is my assumption, that DR has all those things hard coded, correct? Thank you.

  10. Hmm.. I am not sure if that was the issue in previous versions, but no matter what I tweak in the .game file for a new game (except paths) it has no effect. I tried to change "_default" texture to "textures/common/caulk" and DR still uses "_default" texture for every new brush I create o.O (I deleted user settings from C:\User\me\AppData\Roaming\ and restarted DR)

     

    What am I missing? What am I doing wrong? Thanks.

     

    P.S. Saw Reload Shaders > Reload Materials, cool stuff, thanks Greebo.

  11. This means that the entities you have currently selected gets floored to the ground. For example you create a stool or a bed, use this and the entity does stand on the ground nicely, without you having to do this manually.

     

    As most models don't have their origin at the bottom and the distance between the origin's z-coordinate and those of the bottom plane doesn't neccessarily have to be a factor of an often used grid size, this is extremely useful and will safe the mappers a whole lot of time.

     

    Cool feature, but what about objects that hang on the walls, ceiling, flying enemies, etc. ?

     

    EDIT: Nm, I didn't notice second page :) So select the object, press a button, get object dropped to the floor. Got it. Cool feature, Greebo rules :)

  12. I made several observations:

     

    The following settings in the .game file are ignored:

     

    <filesystem>

    <shaders>

    <basepath>materials_v1</basepath>

    <extension>mtr</extension>

    </shaders>

     

    Regardless of what folder name I use for materials, DR always uses base/materials/ (the reason I use base/materials_v1/ is that idTech 4 uses it, and BFG engine uses base/materials/)

     

    "Reload Shaders" in the File menu should probably be "Reload Materials" since shaders are in glprogs/ and are actually called OpenGL shaders, while mtr files are called materials.

     

    Particles that use materials containing ARB shaders don't render in the Particle Editor. They show "Shader Not Found" on each particle. Are shaders supported in material stages? If not, maybe it's better to render "OpenGL shader used" instead of "Shader Not Found" on those particles?

     

    Other than that old maps load fine, animation viewer works.

     

    I haven't tested projected lights (supposedly rendering light material flipped) as I don't have any handy. Can someone please test it and confirm/disprove that issue?

     

    EDIT: I can file those as bug reports, if you think I should.

  13. I need to read EULA on it.. I know for a fact I can use MSVC2010 Express to make commercial apps. Not sure if that's the case with MSVC2012 Express. Also, I don't know if I can have both 2010 and 2012 installed side by side, because dhewm3 and Doom 3 BFG don't come with 2012 solutions, and I don't really want to mess with them if converting solution for 2010 into 2012 doesn't go well.

     

    If I can have 2010 and 2012 side by side, without one affecting another, I will look into it.

     

    I hope DR 1.7.4 will be out rather sooner, so I don't have to mess with all that :P

×
×
  • Create New...