Commit a0328da
committed
games/NXDoom: support RGB565 framebuffers and locate WADs via Kconfig dir
blit_screen() assumed a 32-bit ARGB framebuffer unconditionally - a
real limitation for any RGB565 board (this target's framebuffer is
FB_FMT_RGB16_565), not specific to any one board. Branch on
pinfo.bpp: 16bpp uses RGBTO16(), 32bpp keeps the existing ARGBTO32()
path, and anything else fails loudly via i_error() instead of reading/
writing past the intended pixel bounds silently. Also center the
scaled viewport within the framebuffer (new xoffset/yoffset fields)
rather than pinning it to the top-left corner, since the buffer is
typically larger than SCREENWIDTH/HEIGHT * scale.
buld_iwad_dir_list() never searched CONFIG_GAMES_NXDOOM_PREFDIR - that
Kconfig option is documented as the directory where DOOM WAD files are
stored, but was previously only used for the config/save file
location, forcing every launch to rely on the current directory or
DOOMWADDIR/DOOMWADPATH being set by hand. Add it to the IWAD search
path.
Build this as a standalone loadable module (MODULE = m) unconditionally
rather than tracking CONFIG_GAMES_NXDOOM directly, so it can be
installed/launched via nxpkg/nxstore rather than only ever being a
firmware built-in.
Signed-off-by: aviralgarg05 <gargaviral99@gmail.com>1 parent 30830d9 commit a0328da
3 files changed
Lines changed: 82 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
271 | 271 | | |
272 | 272 | | |
273 | 273 | | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
274 | 286 | | |
275 | 287 | | |
276 | 288 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
95 | 102 | | |
96 | 103 | | |
97 | 104 | | |
| |||
262 | 269 | | |
263 | 270 | | |
264 | 271 | | |
265 | | - | |
266 | | - | |
267 | | - | |
268 | | - | |
269 | | - | |
| 272 | + | |
270 | 273 | | |
271 | | - | |
272 | | - | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
273 | 280 | | |
274 | | - | |
| 281 | + | |
275 | 282 | | |
276 | | - | |
277 | | - | |
278 | | - | |
279 | | - | |
280 | | - | |
281 | | - | |
282 | | - | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
283 | 315 | | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
284 | 324 | | |
285 | | - | |
| 325 | + | |
| 326 | + | |
286 | 327 | | |
287 | 328 | | |
288 | 329 | | |
| |||
724 | 765 | | |
725 | 766 | | |
726 | 767 | | |
| 768 | + | |
| 769 | + | |
| 770 | + | |
| 771 | + | |
| 772 | + | |
| 773 | + | |
| 774 | + | |
| 775 | + | |
| 776 | + | |
| 777 | + | |
| 778 | + | |
| 779 | + | |
727 | 780 | | |
728 | 781 | | |
729 | 782 | | |
| |||
0 commit comments