Commit Graph
27 Commits
Author SHA1 Message Date
Pieter-Jan BriersandGitHub f3a3f564e1 System font API (#5393)
* System font API

This is a new API that allows operating system fonts to be loaded by the engine and used by content.

Fonts are provided in a flat list exposing all the relevant metadata. They are loaded from disk with a Load call.

Initial implementation is only for Windows DirectWrite.

* Load system fonts as memory mapped files if possible.

This allows sharing the font file memory with other processes which is always good.

* Use ArrayPool to reduce char array allocations

* Disable verbose logging

* Implement system font support on Linux via Fontconfig

* Implement macOS support

* Add "FREEDESKTOP" define constant

This is basically LINUX || FREEBSD. Though FreeBSD currently gets detected as LINUX too. Oh well.

* Compile out Fontconfig and CoreText system font backends when not on those platforms

* Don't add Fontconfig package dep on Mac/Windows

* Allow disabling system font support via CVar

Cuz why not.
2025-10-28 22:07:55 +01:00
metalgearslothandGitHub 25007a743f Remove lights component reference (#4316) 2023-09-11 19:17:28 +10:00
eoineoineoinandGitHub f7eebce14e Add padding to glyphs in atlas (#4011) 2023-05-14 04:19:31 +10:00
Pieter-Jan Briers 8121c3c41b Move freetype font data to POH.
Avoids stuff getting stuck in gen0.
2022-11-18 00:50:20 +01:00
Pieter-Jan Briers 38bc58e77c Reduce dictionary lookups when doing char glyph stuff. 2022-06-05 00:38:00 +02:00
Jezithyr 4d19790b3d This should fix the font caching issue? 2022-03-13 16:51:09 -07:00
de4d255841 Analyzer to enforce classes to be either [Virtual], abstract, or sealed. (#2469)
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2022-02-05 19:31:58 +01:00
Acruid 98e009b38f Removed the GameController dependency from Clyde.
Removed the ConfigurationManager dependency from FontManager.
2021-03-25 11:36:57 -07:00
AcruidandGitHub 2183cd7ca1 Massive Namespace Cleanup (#1544)
* Removed the Interfaces folder.
* All objects inside the GameObjects subfolders are now in the GameObjects namespace.
* Added a Resharper DotSettings file to mark the GameObjects subfolders as not providing namespaces.
* Simplified Robust.client.Graphics namespace.
* Automated remove redundant using statements.
2021-02-10 23:27:19 -08:00
Pieter-Jan Briers 8e2a9cc597 Font atlasses are now dynamic and can render all glyphs in the font file. 2020-12-29 03:58:16 +01:00
b8e5b47e7a Use 'new' expression in places where the type is evident for the engine (#1415)
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2020-11-26 00:16:55 +01:00
6bbc4b01e9 Change cvar usages to use CVarDef and define them in CVars (#1330)
Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
2020-10-24 15:40:06 +02:00
Tyler YoungandGitHub 47f307dd2a Upgrades SixLabors.ImageSharp (#1128)
adds InlineIl.Fody for fast access to image backing buffers
2020-06-13 03:08:29 +02:00
Pieter-Jan BriersandGitHub 6674be3adc Client NRTs (#1121) 2020-06-12 12:57:39 +02:00
Pieter-Jan Briers 4be2f8c780 Render greek glyphs. 2020-05-26 16:20:47 +02:00
Pieter-Jan Briers fd204e5a99 Fix rounding error in font atlas code.
This could cause the atlas to be too small at certain configurations.
2020-05-26 16:20:47 +02:00
Pieter-Jan Briers 3095952dcb Use our own SpaceWizards.SharpFont for better .NET Core support. 2019-12-11 06:46:26 +01:00
Pieter-Jan Briers 814b686cb7 Explicitly dispose ImageSharp images. 2019-08-28 12:08:05 +02:00
Pieter-Jan Briers d0ec77e804 Blit fonts manually to reduce created garbage. 2019-08-27 23:13:06 +02:00
Pieter-Jan Briers c0eca4f6c2 .NET Core support. 2019-08-02 02:07:03 +02:00
Pieter-Jan Briers 85a4375905 Various performance optimizations. 2019-08-01 00:10:20 +02:00
Pieter-Jan Briers 0c1c6cee0e Generate basic cyrillic for font atlasses. 2019-07-19 14:13:37 +02:00
Pieter-Jan BriersandGitHub bb4a1eda8e Project file refactor (#819)
* Project file refactor

Move all the .csproj files to the new .NET Core style.
This doesn't make any difference for compiling for Framework,
but it does reduce a ton of useless boilerplate.

As an extension of this, killed a bunch of uncompiled & unmaintained .cs files.

Compiling for release (to profile) works now.
Removed AnyCPU targets from the solution file.

* Fix compiler warnings.
2019-05-28 00:16:01 +02:00
Pieter-Jan BriersandGitHub 17ebeac107 UI Scaling Support. (#809)
Not quite perfect, but quite usable.

Adds the ability to scale the UI. Scaling is controlled via a cvar,
and can be changed at runtime.
Fractional scaling is supported.

Some controls could be better (SpriteView, TextureRect),
but for now it's a good start.
2019-05-11 16:04:14 +02:00
Pieter-Jan Briers 296d39bee6 Make fonts use A8 textures.
Reduces VRAM usage.
2019-05-04 22:17:06 +02:00
Pieter-Jan Briers 772b680723 Render extended ASCII font glyphs. 2019-05-04 21:20:06 +02:00
SilverandGitHub 25926a17b7 Renames SS14.* to Robust.* (#793)
RobustToolbox projects should be named Robust.* 

This PR changes the RobustToolbox projects from SS14.* to Robust.*

Updates SS14.* prefixes/namespaces to Robust.*
Updates SpaceStation14.sln to RobustToolbox.sln
Updates MSBUILD/SS14.* to MSBUILD/Robust.*
Updates CSProject and MSBuild references for the above
Updates git_helper.py
Removes Runserver and Runclient as they are unusable
2019-04-15 20:24:59 -06:00