Eldred Habert
f4463b1708
Honor -c with rgbgfx -r ( #1254 )
...
Fixes #1166
2023-11-24 13:19:04 -05:00
Eldred Habert
99671b8eb5
Avoid building test support programs by default with CMake ( #1244 )
...
Copy CMake-built test executables to test directory
Fixes CI failures on Windows.
CI should also have failed on Unices, but it turns out
we instead merely hit the fallback that the `make` path
relies on (building those executables with `make`),
which fails on Windows since `make` is not set up to
find libpng.
2023-11-21 09:54:22 -05:00
Eldred Habert
d390db5c57
Remove references to C compiler from CI ( #1234 )
2023-11-11 20:50:36 -05:00
Eldred Habert and Rangi
968c6f7ab7
Compute height and width directly in tile units
...
Co-authored-by: Rangi <[email protected] >
2023-11-06 08:14:13 +01:00
ISSOtm
cfe432ea65
Enforce that transparent colours take slot #0 in all palettes
2023-08-26 23:23:28 +02:00
ISSOtm
36bfeea8dc
Silence spurious GCC warning
2023-08-26 22:57:06 +02:00
Eldred Habert
e634888a50
Improve description of rgblink -O ( #1162 )
2023-08-19 11:52:09 +02:00
Eldred Habert and Antonio Vivace
168950855d
Create statically-linked Linux binaries on release ( #1148 )
...
Co-authored-by: Antonio Vivace <[email protected] >
2023-07-08 22:04:00 +02:00
ISSOtm
6d806238fb
Improve bit rotation/shift explanations by using Unicode box diagrams
...
The existing explanations have proven confusing to many,
and presenting the instructions in a more visual manner should help a lot.
Additionally, the Unicode codepoints are typed as-is in the source,
because that allows much more WYSIWYG editing, and god damn it this is the year
two thousand and twenty three, if your man and/or terminal software does't
support Unicode, then what are you *doing*.
2023-06-17 12:38:52 +02:00
Eldred Habert
9748524ef6
Fix incorrect options in RGBGFX zsh completions
2023-06-13 07:57:24 +02:00
Eldred Habert
2023d9ed99
Fix palmap option using wrong file name
2023-02-21 12:05:39 +01:00
ISSOtm
6828f7bf49
"Hook up" new releases' docs
2023-02-08 01:45:35 +01:00
ISSOtm
33a0857b8d
Properly detect tiles with more than 4 colours
...
Fixes #1127 , which was caused by a dumb logic error. Duh me.
2023-02-08 00:21:05 +01:00
ISSOtm
2d15e40539
Fix WRAM0/WRAMX test
...
The previous test did not expect failure when trying to stuff
$3000 bytes into $2000-byte WRAM; this is now fixed, and we
also test the reverse now (that we cannot stuff more than
$1000 bytes into WRAM0 without `-d`/`-w`.
2023-01-07 22:20:42 +01:00
Eldred Habert
50aaa6524d
Fix -w not coercing WRAMX sections to WRAM0
...
Fixes #1116
2022-12-21 23:43:57 +01:00
ISSOtm
7eb4ecea8b
Remove use of std::filesystem
...
This appears to break compatibility with macOS 10.9
2022-12-03 01:51:14 +01:00
ISSOtm
599ce757a1
Force Windows builds to use our zlib and libpng
...
Otherwise we will have a few problems if, say, a system version was
detected and picked up instead of ours...
2022-12-03 00:58:50 +01:00
ISSOtm
75a07a90f8
Always initialise section->data to avoid an uninit read
...
The addition of SDCC objects required a change in the logic of
`mergeSections()` to dispatch based on `->data` instead of
`sect_HasData`, which implicitly assumes that `->data` is
always initialised (maybe NULL).
However, RGBDS sections did not do that!
2022-12-02 22:39:31 +01:00
ISSOtm
ec2d1312ef
Remove auto parameter to -flto
...
Not all supported compilers support the argument;
the move was a bit premature.
2022-11-15 19:49:04 +01:00
ISSOtm
03b6dd9321
Only cache dependency directories instead of whole test/
...
Otherwise, changes made to the test suite are not picked up
2022-11-15 19:49:04 +01:00
ISSOtm
a16d3d6405
Fail RGBGFX test suite if support test programs fail to be built
2022-11-15 19:49:04 +01:00
ISSOtm
3e5cd8ce1a
Use a special name for stdin/stdout in diagnostics
2022-11-15 19:49:04 +01:00
ISSOtm
6902387991
Allow rgbgfx - for stdin and stdout
...
Closes #1087
2022-11-15 19:49:04 +01:00
ISSOtm
62b4f2b264
Upgrade to checkout action v3
...
No code changes, just uses Node 16 instead of the
deprecated Node 12
2022-11-13 14:33:03 +01:00
ISSOtm
48248faab0
Suppress CMake project maintainer warnings in CI
2022-10-16 12:21:54 +02:00
ISSOtm
58181c2d73
Hoist common Windows dep grabbing code to a script
...
Function courtesy of @aaaaaa123456789
2022-10-16 12:21:54 +02:00
ISSOtm
0f86084e08
Rename actions folder as scripts
...
It's clearer this way.
2022-10-16 12:21:54 +02:00
ISSOtm
c8e602dec1
Mangle the name of absolute sections
...
They are unlikely to be unique across files, actually
2022-10-15 23:16:04 +02:00
ISSOtm
b168717e91
Update zlib to 1.2.13
...
1.2.12 is no longer provided by upstream anymore,
which fails Windows CI
2022-10-15 22:02:34 +02:00
ISSOtm
930c2ac328
Require Bison 3.0.0 in CMakeLists
...
We actually require that version, so be explicit about it
to provide better error messages.
2022-10-13 11:02:33 +02:00
ISSOtm
28737d5778
Enable GLIBCXX_ASSERTIONS in make develop
...
Not sure it's very portable, but this is only the dev config
2022-10-12 01:23:37 +02:00
ISSOtm
12ba057b4f
Check that colour slot is non-empty before checking for gray-ness
...
This is otherwise UB, and trips a GLIBCXX assertion (when enabled).
2022-10-11 21:39:32 +02:00
ISSOtm
0e0876b17f
Print addr ranges for empty blocks as well
...
Mirrors what sections do, for clarity & consistency
2022-10-07 16:04:02 +02:00
Eldred Habert and Rangi
b28eea24fc
Update .github/workflows/create-release-artifacts.yaml
...
Co-authored-by: Rangi <[email protected] >
2022-10-04 12:50:46 -04:00
ISSOtm
a1e59ddc3d
Avoid -x c++ affecting ${PNGLDLIBS}
...
version.c doesn't link to anything from libpng, so it'll be fine
2022-10-04 12:50:46 -04:00
ISSOtm
3fbdba31bf
Build macOS binaries as well for releases
2022-10-04 12:50:46 -04:00
ISSOtm
d90a7e4302
Terminate RGBGFX when opening a file fails
...
`std::filebuf::open`'s result must be checked, though that's not obvious.
2022-10-04 13:58:05 +02:00
ISSOtm
7377a14245
Improve RGBASM's "input files" error messages slightly
2022-10-03 17:17:19 +02:00
Eldred Habert
e2136d60b2
Print a more user-friendly error message for leftover diff marks ( #1089 )
2022-10-03 16:52:29 +02:00
ISSOtm
74e40654e6
Sync release docs CI workflow with master
...
We should look into reusable workflows, really.
https://docs.github.com/en/actions/using-workflows/reusing-workflows
2022-10-03 01:50:17 +02:00
ISSOtm
ab12c474d2
Properly exclude GCC from macOS matrices
2022-10-02 02:50:38 -04:00
ISSOtm
8ccbd9dc36
Properly build and link against libpng
...
Doing it right this time.
Also bundling the newly required DLLs.
2022-10-02 02:50:38 -04:00
ISSOtm
b8307432b8
Fix use of bitwise OR instead of logical
...
Thanks, Clang!
2022-10-02 02:50:38 -04:00
ISSOtm
80a62a8a03
Update CI target OSes
...
Remove platforms deprecated by GitHub Actions
Add new platforms supported by the same
2022-10-02 02:50:38 -04:00
Eldred Habert and Rangi
c10345f26d
Comply with sym file spec ( #1078 )
...
Co-authored-by: Rangi <[email protected] >
2022-10-01 12:35:00 -04:00
ISSOtm
6fd5c94b27
Document gbc pal spec format
...
I *knew* I had forgotten something!
2022-10-01 10:48:40 +02:00
Eldred Habert
a1a919579c
Add support for GBC palette dumps to -c ( #1075 )
...
Fixes #1063
2022-09-30 17:09:28 -04:00
ISSOtm
3567faf395
Use backslash escape instead of "backwards slash" in man pages
...
The latter is in the "Lines" category, which seems inappropriate.
2022-09-26 09:45:25 +02:00
Eldred Habert and Rangi
6502ed3919
Add -I as an alias for -i in rgbasm ( #1056 )
...
Co-authored-by: Rangi <[email protected] >
2022-09-26 03:42:30 -04:00
ISSOtm
02923a67f3
Use tabs for indentation in map files
...
As requested by #1012
2022-09-24 12:58:48 +02:00
ISSOtm
0794da22bc
Clarify at-files documentation
2022-09-13 08:34:41 +02:00
ISSOtm
0105779789
Fix incorrect Bash completions after --long-opt=
...
This is because `$COMP_CWORD` points to that `=` "word".
2022-08-10 08:44:41 +02:00
ISSOtm
9ef7954670
Fix some lint warnings in Bash completions
2022-08-10 00:16:05 +02:00
ISSOtm
d7d524294b
Fix shebangs in Bash completion scripts
...
Not that you are really supposed to run them stand-alone?
2022-08-09 22:32:18 +02:00
ISSOtm
12fed4c68e
Harden Bash completion scripts against invalid states
...
Printing an error message is better than locking the shell up, honestly.
2022-08-09 22:30:50 +02:00
ISSOtm
3db3421f07
Correct wrong state transitions in RGBGFX Bash completion script
...
Isn't strinly-typed programming just lovely?
Fixes #1018
2022-08-09 22:28:12 +02:00
ISSOtm
92eb0a133b
Allow rgbgfx -r to read an infinite amount of tiles without tilemap
...
Previously, indices would be wrapped after 256 even without a tilemap;
since RGBGFX can generate arbitrarily large tile data if `-N` is not used,
it should be possible to read those in.
Of course, this won't work if a tilemap is provided, but such "big blobs"
can't generate a meaningful tilemap anyway.
2022-08-04 20:50:08 +02:00
ISSOtm
b02ccf8f4a
Check before attempting to generate empty image
...
This causes a libpng warning then error, but print a better error message
Fixes #1016
2022-08-04 20:40:20 +02:00
ISSOtm
2e0991f32b
Use proper 16-bit type for image reversing width
...
Fixes #1015
2022-08-04 20:40:20 +02:00
Eldred Habert and Antonio Vivace
f3f2c2ca16
Improve object file format documentation ( #1010 )
...
Replacing the big pre-formatted text block with a list brings:
- Better accessibility, obviously
- Responsiveness
- Better formatting (bold, etc.)
- Sub-sections that can now be linked to
- Hyperlink cross-refs to other pages
The slight disadvantage is that `ENDC` etc. are now individual
list items, whereas they'd be better as part of the same item.
No big deal though, it was much worse before.
Some descriptions have been overhauled for clarity, and some
outright corrected (such as Assertions' "Offset" field).
Co-authored-by: Antonio Vivace <[email protected] >
2022-07-29 22:48:55 +02:00
ISSOtm
9ec8186ac6
Switch linkdefs from scattered arrays to an array of structs
...
The info is better organized this way
2022-07-19 19:11:02 +02:00
ISSOtm
ab9945c1ee
Avoid using fscanf to detect RGBDS object files
...
This function is made for text, e.g. accepts spaces, leading zeros, etc. before `%u`.
This way checks that the correct amount of bytes are read instead.
2022-07-19 19:10:58 +02:00
ISSOtm
18e4f132a8
Fix labels subtraction docs
...
Fixes #1009
2022-07-14 13:43:36 +02:00
ISSOtm
828b2adcdf
Make RGBLINK able to link SDCC object files
...
This requires a LOT of tricky code, mostly due to the format itself being,
er, not the most straightforward.
Everything is converted to existing RGBLINK concepts (sections, patches,
etc.), so the core code is essentially unchanged.
(A couple of genuine RGBLINK bugs were uncovered along the way, so some of
the core code *is* changed, notably regarding `SECTION FRAGMENT`s.)
All of this code was clean-roomed, so SDCC's GPLv2 license does not apply.
2022-07-11 21:17:34 +02:00
ISSOtm
1c2965467d
Process linker script before doing sanity checks
2022-07-11 21:17:34 +02:00
ISSOtm
d243e50390
Do not perform any sanity checks for bad section types
...
Otherwise, the arrays get overflowed
2022-07-11 21:17:34 +02:00
ISSOtm
acb33777c6
Sort RGB colors as specified in the docs
2022-07-10 12:36:10 +02:00
ISSOtm
d15916b1bd
Clarify sorting order of RGB colors
2022-07-10 12:32:57 +02:00
ISSOtm
28fcef0ecd
Improve some wording slightly
2022-07-10 12:30:18 +02:00
ISSOtm
b53c115ec2
Fix width and height being reported in wrong order
2022-07-10 12:14:24 +02:00
ISSOtm
6a51e39a5c
Print error if reverse() fails to open a file
2022-07-10 11:55:56 +02:00
ISSOtm
43a487f0bf
Fix two inverted column widths
2022-07-02 17:48:28 +02:00
ISSOtm
6b2dc37f43
Release 0.6.0-rc1
2022-07-02 17:08:54 +02:00
ISSOtm
2b83a81ceb
Update completion scripts
...
Also correct minor blunders in the man page
2022-07-02 17:04:17 +02:00
ISSOtm
ca8693690a
Cancel -U option
...
As it turns out, it is really difficult to implement, and can be dealt with later.
2022-07-02 17:04:17 +02:00
ISSOtm
87092208bc
Stop passing options.columnMajor explicitly everywhere
2022-07-02 17:04:17 +02:00
ISSOtm
0d32775a1f
Add more sanity checks when reversing an image
2022-07-02 17:04:17 +02:00
ISSOtm
0df07d3688
Add note on supporting extra pal formats
2022-07-02 17:04:17 +02:00
ISSOtm
3f70372308
Implement slicing input image
2022-07-02 17:04:17 +02:00
ISSOtm
9646f15b59
Add error message for nigh-impossible proto-palette overflow
2022-07-02 17:04:17 +02:00
ISSOtm
973fbb91bc
Improve error message when a tile has too many colors
2022-07-02 17:04:17 +02:00
ISSOtm
903862c451
Improve flag set generation of RGBGFX tests
...
Less duplication = good
2022-07-02 17:04:17 +02:00
ISSOtm
3f5983358c
Add proper error message for bad manual palettes
2022-07-02 17:04:17 +02:00
ISSOtm
7a7126f3b8
Implement bit flipping with a lookup table
...
Should improve performance.
This version is cooler, and also does not suffer from iteration limits
2022-07-02 17:04:17 +02:00
ISSOtm
b4dadd35b6
Use an iterator zip
...
Simplifies iterating over tiles and attributes at the same time
2022-07-02 17:04:17 +02:00
ISSOtm
d9b1402ef8
Fix RGBGFX number parsing
2022-07-02 17:04:17 +02:00
ISSOtm
832e0ec972
Report position in color errors
2022-07-02 17:04:17 +02:00
ISSOtm
caaf7a8444
Test VRA0 size as well in randtilegen tests
2022-07-02 17:04:17 +02:00
ISSOtm
a5ed0292b1
Reject colors with ambiguous alpha channel
2022-07-02 17:04:17 +02:00
ISSOtm
05e36767b0
Implement "palette map" output
2022-07-02 17:04:17 +02:00
ISSOtm
531092f5bd
Add corrupted PNGs to check error handling
...
This is not intended to test libpng as much as checking that
we behave correctly if libpng gives us an error
2022-07-02 17:04:17 +02:00
ISSOtm
4c51792f15
Allow testing RGBGFX with specific images as input
...
No such tests yet, but the infrastructure will be there.
2022-07-02 17:04:17 +02:00
ISSOtm
c4359c1058
Ignore -b and -N when reversing without tilemap
...
These offsets should only be applied to a tile ID read as input... but this ain't one!
2022-07-02 17:04:17 +02:00
ISSOtm
159efe1257
Transfer test programs as well for cross-testing
2022-07-02 17:04:17 +02:00
ISSOtm
3cfe7800c7
Make randtilegen and rgbgfx_test compile with MSVC
2022-07-02 17:04:17 +02:00
ISSOtm
01cf0c5f98
Print RGBGFX test names
2022-07-02 17:04:17 +02:00
ISSOtm
0dbcebfeb4
Have CMake build and install steps be verbose
2022-07-02 17:04:17 +02:00
ISSOtm
491b6746ab
Clean RGBGFX test programs with make clean
2022-07-02 17:04:17 +02:00
ISSOtm
cbf6fadcdb
Add RGBGFX tests
2022-07-02 17:04:17 +02:00
ISSOtm
a77b0b396a
Fix grayscale sorting not setting palette size
...
A black+white palette would turn into white+transparent, removing black pixels
from the palette (the third slot would be empty, and the 4th slot be set directly)
2022-07-02 17:04:17 +02:00