9 Commits
Author SHA1 Message Date
LibretroAdmin cd479dcbb9 VideoCommon: log, alert and build names in printf terms
Every VideoCommon message goes through the printf log and alert macros,
PRIM_LOG included; a register field or an enum in a message is printed
as its number.

The names built along the way no longer go through fmt:
- a texture's name parts (its size, hashes and format) are formatted
  into buffers on the stack, and the wildcard names concatenated;
- an EFB or XFB copy's name and dump path are made by one helper, from
  an id formatted on the stack;
- dump paths, graphics mod paths and group names are concatenated;
- the projection lookup key is formatted on the stack, on the heap only
  when a name runs past it, as before;
- the format overlay draws TextureFormatName, a constant string.

The no-op LOG_NORM and LOG_VTX macros, commented out since they were
added, are gone. The register formatters in the headers stay until the
assertions move over.
2026-11-11 20:46:56 +01:00
LibretroAdmin 58e6a6005d Video: pointer and size instead of std::span
Texture bytes travel as a TexBytes, a pointer and a size, where they
were a std::span<const u8>: TMEM and RAM runs into TextureInfo and its
mip levels, and the texel decoders the software renderer samples
through. Reads past the end still give zeros, now through three small
readers in TextureDecoder_Common, and TexBytesSkip() steps past a level
as SafeSubspan() did.

LoadPNGTexture() takes a pointer and a size. Metal's bounding box,
which the build does not compile, gets the Read() and Write() the other
backends have. GraphicsModGroup sorted its mods with std::ranges::sort,
whose <algorithm> came in through SpanUtils.h; an insertion sort by
weight takes its place, keeping mods of equal weight in load order.
2026-11-10 21:44:07 +01:00
LibretroAdmin cd38818e52 Common: pointer and size instead of spans, loops instead of STL algorithms
SHA1, HMAC, hex dumps, PNG loading, file search, DHCP options, HTTP
posts and DirectIOFile reads and writes take pointer plus size; callers
pass their buffers straight through. Contains.h is gone; lookups are
plain loops. File search and FAT FST sorting are in-place heap sorts;
min/max/clamp/copy/fill become ternaries, memcpy and memset. Watch
string import and export had no callers and are removed.
2026-11-07 13:37:26 +01:00
Jordan Woyak 5a80105555 Common and VideoCommon: Change texture data from std::vector to Common::UniqueBuffer. 2025-05-03 18:32:30 -05:00
Jordan Woyak c18c039089 VideoCommon: Move backend_info out of VideoConfig struct. 2025-03-09 01:42:45 -06:00
LillyJadeKatrin dc8f3f6eae Refactored Achievement Badges into Texture Layers
Achievement badges/icons are refactored into the type CustomTextureData::ArraySlice::Level as that is the data type images loaded from the filesystem will be. This includes everything that uses the badges in the Qt UI and OnScreenDisplay, and similarly removes the OSD::Icon type because Level already contains that information.
2024-05-23 10:41:45 -04:00
iwubcode 62fee2f3b6 VideoCommon: add loading cube maps from DDS files and loading it into our custom texture object. Custom texture object now has the concept of slices in addition to levels. Traditional custom textures have a single slice 2023-09-02 20:20:09 -05:00
iwubcode 47c40d51df VideoCommon: when loading a PNG with no custom texture data levels already, create a level, this avoids a potential segfault 2023-06-03 12:19:30 -05:00
iwubcode e028d2ead0 VideoCommon: move custom texture data to assets 2023-06-02 14:07:42 -05:00