1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-29 09:44:52 +01:00

Use named casts instead of old-style casts

Change prepared with clang-tidy and google-readability-casting check
This commit is contained in:
Michał Janiszewski
2020-04-22 17:09:29 +02:00
committed by GitHub
parent cfd94d4fa5
commit 2323cc1596
114 changed files with 604 additions and 560 deletions

View File

@@ -46,7 +46,7 @@ void scrolling_text_initialise_bitmaps()
{
uint8_t drawingSurface[64];
rct_drawpixelinfo dpi;
dpi.bits = (uint8_t*)&drawingSurface;
dpi.bits = reinterpret_cast<uint8_t*>(&drawingSurface);
dpi.width = 8;
dpi.height = 8;
@@ -1596,7 +1596,7 @@ static void scrolling_text_set_bitmap_for_ttf(
int32_t pitch = surface->pitch;
int32_t width = surface->w;
auto src = (const uint8_t*)surface->pixels;
auto src = static_cast<const uint8_t*>(surface->pixels);
// Pitch offset
src += 2 * pitch;