Rangi
3f4e8396aa
Implement warning diagnostic flags for RGBGFX ( #1738 )
2025-07-10 09:58:40 -04:00
Rangi42
276a200590
A few miscellaneous edits
2025-07-10 00:33:03 -04:00
Rangi
34cf959c9d
Refactor to reduce nesting depth some more ( #1740 )
2025-07-09 22:46:40 -04:00
Rangi
5e43ece578
Remove errx and errors.hpp ( #1737 )
2025-07-09 11:04:23 -04:00
Rangi42
8c50839109
Miscellaneous updates
2025-07-08 17:45:13 -04:00
Rangi
6869e4807c
Make file.hpp independent of gfx ( #1733 )
2025-07-08 15:16:16 -04:00
Rangi
5de05e2e4b
Replace DefaultInitVec with std::vector ( #1732 )
2025-07-08 14:55:28 -04:00
Rangi
35962dedc4
Refactor warnings and errors ( #1728 )
...
* Remove `err` and `warn`, keep `errx` and `warnx`, using them in RGBGFX too
* Separate RGBGFX and RGBLINK warnings/errors from main options
* Separate `report` function into `error` and `fatal` messages
* Implicit newlines for most RGBASM errors
2025-07-08 12:58:23 -04:00
Rangi42
185a3b29e6
Implement base palette ID
2025-07-06 12:57:20 +02:00
Rangi42
965288de38
Fix out-of-bounds image slices
2025-07-02 19:43:11 +02:00
Rangi
7054d81650
Implement grayscale DMG palette specs ( #1709 )
2025-06-30 14:53:05 -04:00
Rangi42
e7a3b9d90e
Format rgbgfx -vvvvvv string visually
2025-06-21 14:16:48 -04:00
Rangi
b13d623ad4
Encode reversed PNG images as grayscale or indexed when possible ( #1703 )
2025-06-19 09:48:27 -04:00
Rangi42
081f48404c
Remove a TODO comment about overlapping proto-palettes
...
The original algorithm makes a simplifying assumption that one
proto-palette does not fully contain another, and we have no
particular reason to violate this condition.
2025-05-03 10:19:33 -04:00
Rangi42
bdac0ce053
Remove unplanned TODO comments in src/gfx/pal_spec.cpp
...
ACT palette files support a transparent color index, but RGBGFX
cannot apply *one* such transparent color; it would need every
palette's first color to be transparent. Also ACT files tend to
say the first color is transparent anyway, which the user may
not have intended.
ACO palette files can specify version 2 color data, but it's
required to come after version 1 data, and the colors themselves
already exist in the earlier v1 data; v2 just adds UTF-16 names.
Thus, we do not need to be handling these data in those formats.
2025-05-02 21:29:14 -04:00
Rangi
122d91509f
Clear some more TODO comments ( #1677 )
2025-05-02 21:06:34 -04:00
Rangi
7c6f778ae7
Take care of miscellaneous commented TODOs ( #1676 )
2025-05-02 16:44:12 -04:00
Eldred Habert
8cf6c5423a
Implement --background-color ( #1508 )
...
Co-authored-by: Rangi42 <sylvie.oukaour+rangi42@gmail.com >
2025-05-01 23:39:52 -04:00
Rangi
2a5b9b5f98
Fix two RGBGFX bugs ( #1671 )
...
* Fix two RGBGFX bugs
* Fix clang-format idempotence
* Update src/gfx/rgba.cpp
Co-authored-by: Eldred Habert <me@eldred.fr >
---------
Co-authored-by: Eldred Habert <me@eldred.fr >
2025-04-24 15:39:14 +02:00
Rangi42
a72843748f
Avoid using indirect C++ types
2025-04-23 00:53:20 -04:00
Rangi42
df83bc31d2
Consistently use PRId* not PRIi*
2025-04-19 23:44:34 -04:00
Rangi
0150eb4bf3
Exclude more lines from test coverage ( #1663 )
...
These fall into a few categories:
- `_unreachable()`
- Verbose print messages
- Errors that should never practically occur (alloc/read/write failure,
more than UINT32_MAX anonymous labels, etc)
2025-02-17 04:56:10 -05:00
Rangi
632342b254
Use LCOV_EXCL comments to exclude some lines from test coverage ( #1662 )
2025-02-16 13:56:55 -05:00
Rangi
993879a2ed
Derive operator!= from operator== ( #1660 )
2025-02-15 12:37:42 +01:00
Rangi
62309d5c87
Define operator!= in terms of operator== ( #1659 )
2025-02-15 11:34:06 +01:00
Rangi
b35e9d86fb
Remove redundant @-style doc comment tags ( #1641 )
2025-01-29 19:56:28 -05:00
Rangi42
cae31005f8
Always use braces with InsertBraces: true in .clang-format
2025-01-27 20:12:12 -05:00
Rangi42
25c9f8f383
Add more rules to .clang-format
2025-01-27 20:12:12 -05:00
Rangi42
9c8e327ae2
Zero-initialize trimmedTile array
2025-01-27 20:12:12 -05:00
Rangi42
b8b60207f5
Use // line comments not /* block comments
2025-01-27 20:12:12 -05:00
Rangi42
a354af3d08
Reformat source files with clang-format 19.1.7
2025-01-27 20:12:12 -05:00
Rangi42
890528812e
Prefer C++ constructs to C-style sizeof-based macros
2025-01-24 18:56:41 -05:00
Rangi
d9654b752f
Support -h/--help for all programs ( #1620 )
2025-01-21 21:24:17 -05:00
Rangi42
a85d6b3b57
Remove unused readMagic function
2025-01-17 00:09:47 -05:00
Rangi
b13c0f2f8e
Use a constant for 0x8001 ( #1596 )
2025-01-04 04:03:40 -05:00
Rangi
ad95d2e06f
Allow deduplicating tiles with neither an input nor output tileset ( #1585 )
2024-12-30 18:58:07 +01:00
Rangi42
b058bb6e15
Sorting RGB palettes by luminance is not a "legacy" feature
2024-12-23 10:01:30 -05:00
Sylvie
b877c81c32
Use C++-style casts ( #1576 )
2024-12-09 21:56:54 -05:00
Eldred Habert
d5f39c8dce
Remove the use of floating-point for palette packing ( #1565 )
...
This is primarily a correctness change, *not* a performance one.
The expected performance impact is minimal anyway.
The goal is to eliminate the use of platform-inconsistent floating-point operations
for this load-bearing task.
2024-11-29 13:44:19 -05:00
Rangi42
9216485bca
Add TRACE-level verbose logging for efficiency calculations
2024-11-27 21:06:18 +01:00
Rangi42
c33acb905b
Avoid precision loss from floating-point division in calculating efficiency
...
This was breaking test results on 32-bit MinGW
2024-11-27 21:06:18 +01:00
Sylvie
e0ee9dc3ad
Add reverse_1bit RGBGFX test ( #1555 )
...
Fixes a bug to always use 2bpp `_data` in `TileData`
2024-11-24 19:30:49 -05:00
Sylvie
a7fdb2c3d3
Add more RGBGFX test coverage ( #1553 )
2024-10-27 11:32:21 -04:00
Sylvie
90286ccbbc
Fix detection of tiles with too many colors ( #1546 )
2024-10-20 13:51:39 -04:00
ISSOtm
86bf289452
Process the last line of textual palette specs even without a trailing newline
...
Fixes #1519
2024-09-30 22:26:00 +02:00
Sylvie
9783671399
Simplify some C++ abstractions ( #1518 )
...
* Remove namespaces
* Prefer `bool operator==`, not `friend auto operator==`
* Prefer not to use `using`
* Use a `constexpr` function instead of a template for `flipTable`
2024-09-26 00:07:27 -04:00
Rangi42
8037b9e10a
Run clang-format
2024-09-25 13:15:58 -04:00
Rangi42
9b3d19c3f2
Prefer snprintf to sprintf
...
This also simplifies advancing `ptr`
2024-09-15 00:01:09 -04:00
Eldred Habert
80d37f9988
Implement --input-tileset ( #1464 )
...
As discussed in https://github.com/gbdev/rgbds/issues/575#issuecomment-1991456862
2024-09-04 15:20:01 -04:00
Rangi42
26fcff831d
Run clang-format
2024-08-27 01:49:05 -04:00