mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-04-24 21:56:10 +03:00
[GH-ISSUE #2788] Fonts are too wide / wrong size in some games compared to original system (PSP) fonts #1122
Labels
No labels
Atrac3+
Audio
CPU emulation
D3D11
D3D9 (removed)
Depth / Z
Feature Request
Font Atlas
GE emulation
Guardband / Range Culling
HLE/Kernel
I/O
Input/Controller
MP3
Multithreading
Needs hardware testing
Networking/adhoc/infrastructure
No Feedback / Outdated?
OpenGL
PGF / sceFont
PSMF / MPEG
Platform-specific (Android)
Platform-specific (Windows)
Platform-specific (iOS)
PowerVR GPU
SDL2
Saving issue
User Interface
Vulkan
arm64jit
armjit
armv6
x86jit
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ppsspp#1122
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @sceckSukoSuLi on GitHub (Jul 15, 2013).
Original GitHub issue: https://github.com/hrydgard/ppsspp/issues/2788
See screenshot than you see the Problem.
@TallgeeseHeaven commented on GitHub (Jul 15, 2013):
You need the actual PSP font I think. It's illegal for the emulator authors to distribute.
@solarmystic commented on GitHub (Jul 15, 2013):
It is as @TallgeeseHeaven has mentioned.
Rip your own PSP's original fonts, or live with it for now.
@hrydgard commented on GitHub (Jul 15, 2013):
We could probably make a custom font file that looked better, but it's a lot of work so I haven't really prioritized it.
@thedax commented on GitHub (Jul 16, 2013):
You can also try one of the various PGF font packs out there on the web, but there are no promises they'll look good or work well with PPSSPP.
@papel commented on GitHub (Sep 2, 2013):
We need to know what games use PSP fonts.
Lunar: The Silver Star and Phantasy Star Portable 2 do.
According to the log, the English version of both games loaded all fonts, including jpn0.pgf and kr0.pgf.
In the last versions, the fonts in Phantasy Star are acceptable, despite they are not perfect. The fonts in Lunar continue bad.
@unknownbrackets
PGF is rasterized, is not it? Do you know a PGF editor?
Do you know which file from ltn0.pgf to ltn15.pgf is used by Lunar?
I will try to edit the file on Paint to improve Lunar.
@unknownbrackets commented on GitHub (Sep 2, 2013):
Some games I know of that use (or at least link) sceFont to one degree or another:
(Marked with * means very limited usage afaik.)
They are raster, yes. This is a tool to generate PGF fonts:
https://github.com/tpunix/pgftool
As far as the fonts, I don't remember which one is Lunar. You can tell relatively easily by renaming I guess. IIRC it's a large one, probably 0?
0 is Latin large
1 is Latin large with serifs
2 is Latin large in italics
3 is Latin large in italics with serifs
4 in Latin large in bold
5 in Latin large in bold with serifs
6 in Latin large in bold italic
7 in Latin large in bold italic with serifs
8-15 are the same again, but Latin small.
Lunar uses one of the small ones in the initial intro, iirc, and large ones in dialogs. The small one is too large, but the ascenders/etc. are approximately correct. The large one is too large also, but the ascenders are also wrong.
-[Unknown]
@papel commented on GitHub (Sep 2, 2013):
Thanks.
Lunar uses ltn12.pgf. The size is 33% larger.
I dumped the bmp files, but I have problems to assembly it back to pgf.
@unknownbrackets commented on GitHub (Sep 2, 2013):
Width is also an issue. All the characters need to basically fit neatly within their box. Th is i s wh yyou get bad kerni ng i n Di ssi di a, or at least used to.
IIRC the width is not far off (which can matter since some games hard wrap, including Lunar) but the height is too much.
-[Unknown]
@papel commented on GitHub (Sep 3, 2013):
I resized some bmp files and I need to test them.
How to convert the bmp files to pgf? I do not understand what mix_pgf does.
@thedax commented on GitHub (Feb 3, 2014):
Is there much of a point keeping this open anymore? We've been through various fonts, and if the user doesn't like the ones we supply, it's not difficult to swap them out for real PSP fonts (though IIRC Android/iOS users are still out of luck).
@unknownbrackets commented on GitHub (Feb 3, 2014):
You can swap out on all platforms, but it'd be nice to improve the fonts shipped by default to have a similar size...
-[Unknown]
@solarmystic commented on GitHub (Feb 3, 2014):
@thedax
Actually, I've managed to successfully swap the real PSP fonts in PPSSPP on my JB'ed Ipad 3 retina by manually going to where the program has been installed by Cydia, and using FTP (OpenSSL on the Ipad 3 and winscp551 on the Windows 7 laptop), transferring it from my the ppsspp folder on my PC to that particular folder.
The font folder on the JB'ed iOS Cydia ppsspp installation (using angelxwind's repo) is located in
(from the root of the file system)
/private/var/stash/Applications.ReFxd1/PPSSPP.app/assets/flash0/fontThe only issue with this method is that once I remove that version of PPSSPP to upgrade it to the latest one on her repo, I have to replace the font files again, since they are considered to be a part of the orignal package. The ini files are actually saved in between installations, so are the games on the iOS device (obviously).
@unknownbrackets commented on GitHub (Feb 3, 2014):
@solarmystic you don't have to do that. You can place them in a flash0 directory inside the PSP folder. Specifically, it looks for a folder
ms0:/PSP/flash0/font/. If any file exists there, it is used instead of the standard one by sceFont.This works on all platforms.
-[Unknown]
@solarmystic commented on GitHub (Feb 3, 2014):
@unknownbrackets
The only thing about what you suggested that does not quite work out is the fact that the iPad (and indeed all iOS devices) don't use/have any external storage that would use the ms0: (memory stick) moniker. Hmm...
@unknownbrackets commented on GitHub (Feb 3, 2014):
Well, assuming that you can save games on your iPad, it means there is a PSP directory somewhere. That is what I'm referring to. On Windows, "ms0:/" means "memstick/ in either the PPSSPP directory or My Documents".
On Android, "ms0:" typically means "/sdcard/".
On Linux, "ms0:" typically means "~/.config/ppsspp/PSP/".
I don't remember what it means on iOS. But it is the same place your savedata and savestates reside.
-[Unknown]
@solarmystic commented on GitHub (Feb 3, 2014):
Ahh, I see what you mean, but the location is different for the JB'ed iOS PPSSPP installation.
It's over here instead:-
/private/var/mobile/Documents/PSP/flash0/fontI have to create the flash0 and font folders manually. And yes, it does work that way, thanks for the heads up.
@unknownbrackets commented on GitHub (Feb 3, 2014):
Right. Like the ini files and your savedata, this won't be deleted when you upgrade.
-[Unknown]
@dbz400 commented on GitHub (Apr 26, 2014):
Probably this one should be closed ? I think @thedax ask the same question 3 months ago :)
@unknownbrackets commented on GitHub (Apr 26, 2014):
If you think this should be closed, you haven't played many games with the default fonts.
-[Unknown]
@thedax commented on GitHub (Apr 26, 2014):
We definitely need to ship a better default font before this can be worthy of closing. The current one isn't that great.
@unknownbrackets commented on GitHub (Jan 25, 2015):
So, I'm implementing a little font editor. I'm thinking this will be the best way to get correct metrics.
So far it can load pgf fonts and display characters for editing, but can't save yet, shadows not supported yet, and the character map is not implemented yet. For simplicity, I'm just implementing it for the web browser (client side only.)
Anyway, I'm thinking to allow loading a font to work on, and a "reference font". The reference font would show the metrics (advance, w/h, etc.) for next to your glyph's metrics. Need to allow editing those, and maybe ideally visualizing them but I'm probably not gonna do that.
Also need to add a "palette" or something. There's 16 colors, dragging over each box 15 times to make it 100% is kinda too much, heh.
-[Unknown]
@hrydgard commented on GitHub (Jan 25, 2015):
Very cool! Could generate the shadows automatically with a little darken + blur, too.
@unknownbrackets commented on GitHub (Mar 27, 2017):
Well, sometime after that I lost a bit of interest. Seemed like a lot to expect someone else to do, because I wasn't really interested in drawing the font itself. Anyway, I quickly fixed saving + minor refactoring and build scripts, and pushed it up here:
https://github.com/unknownbrackets/ppsspp-font
https://ppsspp-font.netlify.com/
All that works right now is loading, drawing, and saving. Drag a pgf in, hit Save, draw over some letters, and it exports a working (but totally uncompressed) pgf. Can't change w/h or anything else for now, and it strips out shadow maps.
The UI is pretty ugly, just enough to test that the loading and saving was working, really.
-[Unknown]
@hrydgard commented on GitHub (Mar 27, 2017):
Nobody expects you do to everything. Thanks for pushing it! It's a good reference for future work in this area.
I think the way to go is probably not to hand-draw, but to take an existing free font and stretch it to fit the metrics of the official font, then manually touch up the result as needed.
@unknownbrackets commented on GitHub (Mar 27, 2017):
Right sure, just that touching up might be a bit involved. We want the same "aspect ratio" for the font glyphs. Maybe we just leave whitespace in one direction or the other, but match the size...
-[Unknown]
@hrydgard commented on GitHub (Mar 27, 2017):
Well yeah, I mean stretch each individual character to the correct dimensions for that one, both horizontally and vertically. Inevitably the result will be that some chars look a little malformed, and that can be manually touched up. Needs to be tested to see how much touching up is needed, hard to predict. Just inserting whitespace will probably not look very good, can probably do better.
@superostrich commented on GitHub (Mar 4, 2020):
I've been using the texture replacement feature to replace the individual characters for specific titles, and the results are quite good, but it is extremely labor intensive and has to be done on a per-game, per-language basis.
Would it be possible to have a similar dump -> load feature for the entire system font? If the entire font could be dumped-to / loaded-from a single texture it would be ideal.
@unknownbrackets commented on GitHub (Mar 4, 2020):
Essentially, that is what a PGF is - the font textures, plus numbers about how big and how wide each character is.
Of course, only a fraction of games use PGFs (system fonts.) A lot of games don't. There's no way to just do it once for those. I'd guess around 15%, but lower if you don't count minis.
But note that PGFs are rendered to RAM and the way the API works - it's much more complicated to upscale them than regular textures. We could try to track as they are copied around in RAM or something, but it might become per-game and labor intensive for that to work everywhere too.
-[Unknown]
@nassau-tk commented on GitHub (Nov 23, 2020):
Fixed these PGF font below.
Jpn0.pgf (Including : Japanese/Chinese/English)
ltn0.pgf / ltn2.pgf / ltn4.pgf / ltn6.pgf
ltn1.pgf / ltn3.pgf / ltn5.pgf / ltn7.pgf
I want check & test by many user.
I can't make "ltn8~15" (Small size English PGF font) now.
But,Many games will become playing smooth by above modified fonts.
(...I believe....)
@nassau-tk commented on GitHub (Nov 29, 2020):
I made Small Fonts.
And, It was merged.
Please test it everyone!
modified pgf files are below.
ltn8.pgf
ltn9.pgf
ltn10.pgf
ltn11.pgf
ltn12.pgf
ltn13.pgf
ltn14.pgf
ltn15.pgf
Test Target)
QIX++
LUNAR
etc....
@nassau-tk commented on GitHub (Dec 2, 2020):
@hrydgard
@unknownbrackets
and ALL
This issue is started 8 years ago.
I think can be closed now.
Because,All PPSSPP original fonts are modified/fixed already now.
(Of course,Not perfectlly yet.)
If you need to more brush up about "shape/gap/margin" then we should reopen it or open other topic.
How do you think about it?
@unknownbrackets
It was possible to make with the history of your making.
Thank you very much.
@Sanaki commented on GitHub (Dec 2, 2020):
Just disabled my own font dumps and tested the new ones out on Jeanne d'Arc (one of the sensitive titles). Gotta say, it looks fantastic, and damn close to the real fonts. The prior experience without those dumps was... unpleasant to say the least.
@nassau-tk commented on GitHub (Dec 2, 2020):
@Sanaki
Even if there was a conversion tool, font making was handwork.
I didn't have knowledge of a programming conversely, but it was fitting work for me with leisure time.😄
Because I don't know how much users there are on earth in the whole world, but it's wasteful that this wonderful emulator seems regrettable because of just characters.
Thank you very much for your wonderful report!
@hrydgard commented on GitHub (Dec 2, 2020):
Thanks again for your great work @nassau-tk :)