Commit graph

302 commits

Author SHA1 Message Date
Anders Jenbo
bfb3c11c2b 🎨 Change namespace to devilution 2021-04-06 15:21:25 +02:00
Anders Jenbo
630e507f63 🚚 Apply namespace 2021-04-06 15:21:25 +02:00
Juliano Leal Goncalves
9021f8daa5 ♻️ Pluralize global 'item' array variable 2021-04-06 11:45:28 +02:00
FluffyQuack
c0f57f3020
🐮 Draw outline for color in index 0 for inventory icons. (#1318) 2021-04-03 03:39:44 +02:00
Anders Jenbo
ca2c2ba5e7 🚨 Handle a bunch of warnings from CLang 2021-03-29 06:26:31 +02:00
Gleb Mazovetskiy
92fbd21b11 Fix SDL_Rect warnings on SDL1 2021-03-22 20:48:17 +01:00
Gleb Mazovetskiy
70d1d633bd Get rid of SCREEN_X / SCREEN_Y
GlobalOutputBuffer() now returns a clipped subregion
2021-03-17 23:37:58 +01:00
Gleb Mazovetskiy
4d6de74eb8 Don't rely on BORDER_LEFT/TOP in cursor rendering
The code there previously implicitly relied on BORDER_LEFT/TOP being
large enough.
2021-03-13 15:34:53 +01:00
Gleb Mazovetskiy
cd59a1c323 Completely replace gpBuffer with CelOutputBuffer
`CelOutputBuffer` now contains an `SDL_Surface` and an `SDL_Rect`.

We now have access to SDL surface manipulation functions.

`gpBuffer` and `gpBufEnd` are completely gone 🧹

This results in some FPS loss (250 -> 195) recovered in a subsequent
commit.
2021-03-13 05:13:26 +01:00
Gleb Mazovetskiy
4b45b642a7 Migrate scrollrt_draw_cursor_back_buffer away from gpBuffer 2021-03-13 02:26:11 +01:00
Gleb Mazovetskiy
afa3a6bf27 Migrate capture.cpp away from gpBuffer 2021-03-13 02:26:11 +01:00
Gleb Mazovetskiy
599d2e5e38 Migrate QOL away from gpBuffer 2021-03-13 02:26:11 +01:00
Gleb Mazovetskiy
bafbad6b5b Migrate RedBack away from gpBuffer 2021-03-13 02:26:11 +01:00
Gleb Mazovetskiy
e7c9ba40f5 Migrate DrawLife/ManaFlask away from gpBuffer 2021-03-13 02:26:11 +01:00
Gleb Mazovetskiy
f607807c95 Migrate the rest of drawing away from gpBufEnd 2021-03-13 02:26:11 +01:00
Gleb Mazovetskiy
3c4ccfc2e4 CelOutputBuffer: Replace subregion with subregionY
We can't do anything with X yet
2021-03-13 02:26:11 +01:00
Anders Jenbo
58a1c1db95 ♻️ Clean up function in scrollrt.cpp with swaps 2021-03-08 18:34:36 +01:00
Anders Jenbo
f97adef2dd 🐛 Fix render assertions on Big Endian systems 2021-03-08 09:45:57 +01:00
Gleb Mazovetskiy
ba6a78ebc8 Migrate Cl2DrawOutline to accept a buffer 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
819b5b05df Migrate Cl2DrawLightTbl to accept a buffer 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
07f4dbbd2e Migrate Cl2Light to accept a buffer 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
bb3ba369df Migrate Cl2Draw to accept a buffer 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
eadc5a20a3 Migrate CelDrawLightRedSafe to CelDrawLightRedSafeTo 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
a70de3cecd Migrate CelClippedDrawSafe to CelClippedDrawSafeTo 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
9ca1fd8996 Migrate CelBlitOutline to CelBlitOutlineTo 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
242341c0b3 Migrate CelClippedDraw to CelClippedDrawTo 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
88bf59f355 Migrate CelClippedBlitLightTrans to CelClippedBlitLightTransTo 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
14ae63d37d Migrate CelClippedDrawLight to CelClippedDrawLightTo 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
379b45e021 Migrate CelDrawLight to CelDrawLightTo 2021-03-06 09:55:14 +01:00
Gleb Mazovetskiy
b43325028f Migrate CelDraw to CelDrawTo 2021-03-06 09:55:14 +01:00
Anders Jenbo
e280432b92 🚨 Fix all SDL1 warnings 2021-03-06 05:56:47 +01:00
qndel
82ab76b22b Experience bar 2021-03-05 06:10:48 +01:00
qndel
be895274dc Monster health bar 2021-03-05 05:12:15 +01:00
Anders Jenbo
6be9d37a57 🐛 Fix unitialized variables in the rendere 2021-03-04 19:27:05 +01:00
Gleb Mazovetskiy
d55a1c8a7d
Pass CelOutputBuffer to game text printing (#1095)
* Pass CelOutputBuffer to game text printing
* DrawHalfTransparentRectTo: minor cleanup
2021-03-03 18:20:24 +01:00
Gleb Mazovetskiy
83ce7c27af Enginify trans_rect
Moves `trans_rect` to `engine` as `DrawHalfTransparentRectTo` and makes
it operate on `CelOutputBuf`.
2021-03-03 12:07:07 +01:00
Gleb Mazovetskiy
588458d500 Remove gpBufStart
Was only set once and used in one place since #964
2021-03-01 02:20:21 +01:00
Gleb Mazovetskiy
8283f85e24 Engine: Functions to render to any buffer
Refactor the rendering functions to allow rendering to any output
buffer.

New functions that accept a buffer have the `To` suffix.

The functions that render to the global buffer now always accept
coordinates.
2021-02-27 17:49:39 +01:00
Anders Jenbo
36a196389b Fix remaning basic compiler errors and warnings 2021-02-22 13:51:42 +01:00
qndel
0958cd456c
fix typos (#1028) 2021-02-20 20:28:21 +01:00
Anders Jenbo
3dae37501c Fix partial screen updating 2021-02-20 06:56:14 +01:00
Anders Jenbo
a90922939f Log errors in game state during rendering 2021-02-19 23:26:01 +01:00
pionere
f5c1079d6f eliminate unused code 2021-02-19 22:04:11 +01:00
pionere
d5a0fa8e85 get rid of a few warnings 2021-02-19 22:04:11 +01:00
FluffyQuack
790c8e17e5 Implemented blended tranparency 2021-02-19 05:57:48 +01:00
Anders Jenbo
60d3e9ceb1 Clean up rendering 2021-02-19 03:05:12 +01:00
qndel
ab9911064f unify checks for single and multiplayer 2021-02-18 22:32:01 +01:00
Anders Jenbo
01590d3757 Merge a section of the Hellfire item and quest code 2021-01-07 02:29:06 +01:00
Anders Jenbo
d20eddf48e Unifcy a chunk of Hellfire's code pathts 2020-12-28 01:11:25 +01:00
Anders Jenbo
61b2d0de95 Merge branch 'master' of github.com:diasurgical/devilution 2020-12-16 02:24:39 +01:00