Commit Graph

30 Commits

Author SHA1 Message Date
frosch b6c8f301be Codechange: Silence warnings about intentionally unused parameters. 2023-09-19 22:49:59 +02:00
Rubidium eaae0bb5e7 Codechange: automatic adding of _t to (u)int types, and WChar to char32_t
for i in `find src -type f|grep -v 3rdparty/fmt|grep -v 3rdparty/catch2|grep -v 3rdparty/opengl|grep -v stdafx.h`; do sed 's/uint16& /uint16 \&/g;s/int8\([ >*),;[]\)/int8_t\1/g;s/int16\([ >*),;[]\)/int16_t\1/g;s/int32\([ >*),;[]\)/int32_t\1/g;s/int64\([ >*),;[]\)/int64_t\1/g;s/ uint32(/ uint32_t(/g;s/_uint8_t/_uint8/;s/Uint8_t/Uint8/;s/ft_int64_t/ft_int64/g;s/uint64$/uint64_t/;s/WChar/char32_t/g;s/char32_t char32_t/char32_t WChar/' -i $i; done
2023-07-19 19:30:14 +02:00
Patric Stout 1fb101eabb
Codechange: address CodeQL issue "Multiplication result converted to larger type" (#10306)
Most are very unlikely to ever be triggered in our codebase; two
stand out: linkgraph and money cheat. Those, potentially, could
wrap earlier than expected.
2023-01-02 20:30:02 +00:00
Charles Pigott 9b800a96ed
Codechange: Remove min/max functions in favour of STL variants (#8502) 2021-01-08 11:16:18 +01:00
S. D. Cloudt 13cc8a0cee Cleanup: Removed SVN headers 2019-11-10 17:59:20 +00:00
Jonathan G Rennison db924a4681 Codechange: [Blitter] Change DrawLine to be templated
This is remove per-pixel overheads due to use of the SetPixel virtual
method.
These overheads included:
* expensive virtual method call which prevents inlining
* palette lookup for every pixel
* branch on whether palette animation is enabled on every pixel

Regenerate project files.
2019-01-24 11:12:06 +00:00
Jonathan G Rennison 17257b9620 Add: 32bpp SSE2 blitter palette animator (#6795)
Create a new blitter mode: 32bpp-sse2-anim, which is 32bpp-anim + this.
32bpp-sse2-anim is now used by default where 32bpp-anim would have been.
Also use this with the 32bpp-sse4-anim blitter.

See issue #6469.
2018-05-23 09:55:04 +01:00
rubidium 0463dbdc9e (svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values 2014-04-23 20:13:33 +00:00
planetmaker c24374f99c (svn r24900) -Fix [FS#5389]: Comments with typos (most fixes supplied by Eagle_rainbow) 2013-01-08 22:46:42 +00:00
rubidium 54e36c4ff8 (svn r24111) -Codechange: use Colour more instead of manually bitstuffing 2012-04-10 20:16:51 +00:00
rubidium 61625e53c9 (svn r23448) -Fix: keep a local copy of the palette in the 32bpp animated blitter so changes of the palette data during the game don't influence drawing (with SDL) 2011-12-08 19:37:33 +00:00
rubidium 4f87d2e88c (svn r23194) -Codechange: don't cast away const needlessly 2011-11-12 08:26:30 +00:00
frosch 004c93f9da (svn r22288) -Codechange: Deduplicate Blitter_8bppBase::DrawLine() and Blitter_32bppBase::DrawLine() into Blitter::DrawLine(). 2011-04-02 11:55:54 +00:00
alberth b2f9b0ac43 (svn r18907) -Cleanup: Smallmap was the last user of SetPixelIfEmpty(). 2010-01-23 22:37:14 +00:00
rubidium 82fc28f77f (svn r18809) -Codechange/Cleanup: remove unneeded headers from some files, if a header require a header make it include that header 2010-01-15 16:41:15 +00:00
rubidium 7fbc33dae1 (svn r17248) -Fix: add GPL license notice where appropriate 2009-08-21 20:21:05 +00:00
rubidium b25a4f8231 (svn r15718) -Cleanup: apply some comment coding style on the rest of the sources too 2009-03-15 00:32:18 +00:00
rubidium c0a8d09ca7 (svn r15428) -Codechange: consistently use colour instead of having both color and colour. 2009-02-09 02:57:15 +00:00
rubidium d03994098b (svn r12971) -Documentation: add @file in files that missed them and add something more than whitespace as description of files that don't have a description. 2008-05-06 15:11:33 +00:00
rubidium a773d45885 (svn r11684) -Codechange: split gfx.h in a type and functional header. 2007-12-23 10:56:02 +00:00
smatz 93c3e0d6ad (svn r11652) -Codechange: add the svn $ header for several files 2007-12-17 01:35:45 +00:00
rubidium 2239809bdc (svn r11169) -Fix [FS#1255]: obiwan in Blitter::Drawline(), which caused it to clip too much at screen/viewport borders. Patch by frosch. 2007-09-26 14:17:26 +00:00
truelight 6771f5ca20 (svn r10837) -Fix [FS#1102]: DrawLine didn't bound-check the first pixel that was drawn (frosch) 2007-08-10 13:11:53 +00:00
truelight 3fa3d2e365 (svn r10241) -Codechange: CopyToBuffer now produces a buffer that is unreadable from outside the blitter, so the blitter can store anything he likes
-Codechange: added CopyImageToBuffer, which produces a readable buffer for screenshots
-Fix: 32bpp-anim now holds animation on transparent objects to avoid strange graphical effects
-Fix: 32bpp-anim now works correct on mouse-movement (it holds the palette animation correctly)
2007-06-21 12:36:46 +00:00
truelight 1c4760ee06 (svn r10216) -Fix: palette animation always redid all palette entries, where in fact only a few indexes were needed
-Codechange: allow blitters to handle palette animation internally or even disable it; 8bpp uses video-backend for palette animation
2007-06-19 15:04:08 +00:00
truelight 26e9b5ca5f (svn r10206) -Codechange: more moving things to blitter-layer: ScrollBuffer 2007-06-18 20:08:21 +00:00
truelight 09879ea308 (svn r10203) -Codechange: more moving things to blitter-layer: DrawLine 2007-06-18 19:38:23 +00:00
peter1138 c31ff284c3 (svn r10201) -Codechange: Replace Blitter::SetHorizontalLine with Blitter::DrawRect, as the former was only used by the rectangle drawing code anyway. This lets us draw rectangles in one go. 2007-06-18 18:45:12 +00:00
truelight f5776a8c6b (svn r10193) -Fix r10190: somehow an other partly-patch was applied too 2007-06-17 20:47:11 +00:00
truelight 003375d375 (svn r10190) -Codechange: merged renderer and blitter to one single class API: blitter
-Codechange: introduced a hierachy of blitters to avoid a lot of code duplication
 Note: this allows much easier adding other types of video-drivers, like OpenGL
2007-06-17 20:30:28 +00:00