![]() |
#1 |
Rookie
Join Date: Aug 2018
Posts: 23
![]() |
why does angband still use .fon files ?
I was looking at -
Code:
~/games/angband-master/lib/fonts$ ls 10x14xb.fon 12x18x.fon 16x24x.fon 6x12x.fon 7x13xb.fon 8x12x.fon 8x8xb.fon 9x15x.fon 10x14x.fon 12x24x.fon 5x8x.fon 6x13xb.fon 7x13x.fon 8x13x.fon 8x8x.fon Makefile 10x20x.fon 16x16x.fon 6x10x.fon 6x13x.fon 8x12xb.fon 8x16x.fon 9x15xb.fon There are so many foss fonts nowadays . Just to ideate there are 514 packages (font number will be higher in Debian) . See - Code:
$ aptitude search fonts | wc -l 514 https://en.wikipedia.org/wiki/TrueType https://en.wikipedia.org/wiki/OpenType#Open_Font_Format https://en.wikipedia.org/wiki/OpenType They also will work better on mobiles and SBC's if it were deployed as most platforms have support for all three font formats shared. |
![]() |
![]() |
![]() |
#2 |
Veteran
Join Date: Apr 2007
Posts: 1,951
Donated: $40
![]() |
The answer to a lot of questions like "why does Angband still do X?" is because no-one made it not do that yet. Plus, I think most of the Angband maintainers have enjoyed hacking on the game and weren't/aren't particularly interested in learning how to write e.g. a new Windows frontend, or learning how to use SDL. The platform-specific bits of Angband are for sure the least modified and least loved bits of the game. Pending people who like frontend work showing up and doing some stuff, the frontends mostly stay unmodified for years at a time.
EDIT: Also, Angband is very different on different platforms. Windows and SDL use the .fon files, but Mac doesn't, and neither does the X11 port, or curses.
__________________
takkaria whispers something about options. -more- |
![]() |
![]() |
![]() |
#3 | |
Rookie
Join Date: Aug 2018
Posts: 23
![]() |
Quote:
Code:
angband-data: /usr/share/angband/xtra/font/10x14x.fon angband-data: /usr/share/angband/xtra/font/10x14xb.fon angband-data: /usr/share/angband/xtra/font/10x20x.fon angband-data: /usr/share/angband/xtra/font/12x18x.fon angband-data: /usr/share/angband/xtra/font/12x24x.fon angband-data: /usr/share/angband/xtra/font/16x16x.fon angband-data: /usr/share/angband/xtra/font/16x24x.fon angband-data: /usr/share/angband/xtra/font/5x8x.fon angband-data: /usr/share/angband/xtra/font/6x10x.fon angband-data: /usr/share/angband/xtra/font/6x12x.fon angband-data: /usr/share/angband/xtra/font/6x13x.fon angband-data: /usr/share/angband/xtra/font/6x13xb.fon angband-data: /usr/share/angband/xtra/font/7x13x.fon angband-data: /usr/share/angband/xtra/font/7x13xb.fon angband-data: /usr/share/angband/xtra/font/8x12x.fon angband-data: /usr/share/angband/xtra/font/8x12xb.fon angband-data: /usr/share/angband/xtra/font/8x13x.fon angband-data: /usr/share/angband/xtra/font/8x16x.fon angband-data: /usr/share/angband/xtra/font/8x8x.fon angband-data: /usr/share/angband/xtra/font/8x8xb.fon angband-data: /usr/share/angband/xtra/font/9x15x.fon angband-data: /usr/share/angband/xtra/font/9x15xb.fon If it's the latter, we could simply use one or more fonts to make the game look attractive without much cost. I have 806 fonts when I have not installed all the font packages in Debian archive - Code:
$ fc-list | wc -l 806 Unicode fonts could be another idea perhaps https://en.wikipedia.org/wiki/Unicode_font One idea could perhaps be to use the popular noto font which is used quite a bit. https://web.archive.org/web/20160303...ts.debian.net/ |
|
![]() |
![]() |
![]() |
#4 |
Prophet
Join Date: Dec 2009
Posts: 9,022
![]() |
|
![]() |
![]() |
![]() |
#5 | ||
Veteran
Join Date: Apr 2007
Posts: 1,951
Donated: $40
![]() |
Quote:
Quote:
__________________
takkaria whispers something about options. -more- |
||
![]() |
![]() |
![]() |
#6 |
Prophet
Join Date: Apr 2007
Location: Seattle, WA
Posts: 6,803
Donated: $40
![]() |
Takkaria--i agree bitmaps were better choices with low resolution screens. But those are few and far between these days. Spline-fit fonts are a much better choice now.
|
![]() |
![]() |
![]() |
#7 |
Swordsman
Join Date: May 2016
Posts: 330
![]() |
.fon files are really just tilesets. IMO, it would be easier to use bmp or png file with glyphs + text file with coordinates (exactly like tiles in lib/tiles).
In fact, for my project, I've written a tool that makes such tilesets out of vector font files ![]() |
![]() |
![]() |
![]() |
#8 |
Prophet
Join Date: Apr 2007
Location: Seattle, WA
Posts: 6,803
Donated: $40
![]() |
t4nk-
It turns out to be a performance penalty to use tiles instead of glyphs. You can see the difference when running and sometimes on redraws. |
![]() |
![]() |
![]() |
#9 | ||
Swordsman
Join Date: May 2016
Posts: 330
![]() |
Quote:
Quote:
* which is, btw, not trivial and can involve such things are running bytecode on a virtual machine (part of so-called "hinting")... |
||
![]() |
![]() |
![]() |
#10 |
Prophet
Join Date: Dec 2009
Posts: 9,022
![]() |
It can be surprisingly difficult to render a large grid of anything without getting performance penalties. I discovered that when writing the Pyrel UI. The naive approach (just tell your GUI widget library to render a text symbol for every tile in view on every update) is horrifically slow. Getting clever about remembering which portions of the screen have changed and only rerendering those helps, but then scrolling the view is also horrifically slow (because every single tile "changes"). So then you start saying "well, the scrolled view re-uses a lot of tiles from the previous view, so I'll keep the previous view around, redraw it at an offset, and then draw the new/updated tiles on top of that" and you have fairly complex drawing logic that's still really not all that fast.
As for tilesets vs. software-rendered fonts, I can absolutely believe that it's faster to blit a texture to a tile than it is to draw an "@". After all, drawing the "@" involves first converting the vectors to a raster image and then...converting that raster to a texture and blitting it. ![]() |
![]() |
![]() |
![]() |
Tags |
fonts |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Spoiler Files? | Will94 | Vanilla | 4 | December 2, 2013 22:13 |
RST help files | fph | Development | 13 | September 6, 2011 20:08 |
Pref files | relic | Vanilla | 11 | August 9, 2011 20:40 |
Restoring 6x9.fon - help needed | Magnate | Vanilla | 7 | May 22, 2009 08:33 |
Z+Angband export(decode) .raw files? | PaulBlay | Variants | 2 | February 7, 2009 00:06 |