-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add sprite loaders for C&C Remastered Collection #18543
Conversation
2aeefba
to
c45697f
Compare
Note to self: look into https://www.nuget.org/packages/pfim as an option to offload my (too?) minimal tga and dds parsing. |
Note to self: SRGB != RGB. Before we start actually using these ingame, |
There are a few misc unpackaged TGA images that we need to load, so I will need to refactor out a separate TgaLoader. |
cb5277f
to
cc5c506
Compare
Updated:
This should now be significantly easier to understand and review. |
cc5c506
to
7d92a6a
Compare
Isn't putting those in Mods.Common running contrary to #12775? |
Neither .tga or .dds are Westwood formats. |
Indeed, both are widely used formats in games so I felt it more appropriate to put these in Common, and the remaster-specific wrapper in Mods.Cnc. |
The larger idea was to move specific formats out of common, but if they are more widely used it's ok I guess. |
7d92a6a
to
a3b7337
Compare
5e92780
to
1fcfcc1
Compare
Rebased. |
1fcfcc1
to
1aa8955
Compare
Updated to use the plumbing from #18938. |
1aa8955
to
3008458
Compare
3008458
to
faa60cb
Compare
Rebased. |
The idea on my end was mostly about moving support of proprietary formats out of Mods.Common, so any future commercial projects using OpenRA's engine don't have to rip anything out of Common for legal safety and just need to drop the Westwood/EA-specific dlls. |
Code looks good as far as I'm able to judge it, but not tested yet. |
faa60cb
to
2dc1f95
Compare
Rebased. |
2dc1f95
to
5680f3d
Compare
This PR adds sprite loaders for object (unit/structure/vfx/etc) and terrain artwork.
Object artwork is packaged as a zip file containing tga images and json metadata.
Terrain artwork is loose dds files that will need additional tileset support before a mod can use them. As noted in the code, this is intended as a first implementation of DDS that I expect we will eventually rewrite to keep the texture data compressed all the way through to the GPU.
This is best tested by combining with #18443 and then modifying TD's mod.yaml to add
/path/to/TEXTURES_TD_SRGB.MEG
in thePackages
list;ShpRemastered, Dds
to theSpriteFormats
list and.ZIP, .DDS
to the AssetBrowserSupportedExtensions
list. The sprites can then be viewed in the asset browser.