mirror of
https://github.com/encounter/SDL.git
synced 2025-12-17 00:47:15 +00:00
Readability: remove redundant cast to the same type
This commit is contained in:
@@ -1466,7 +1466,7 @@ Blit_RGB565_32(SDL_BlitInfo * info, const Uint32 * map)
|
||||
/* Set up some basic variables */
|
||||
width = info->dst_w;
|
||||
height = info->dst_h;
|
||||
src = (Uint8 *) info->src;
|
||||
src = info->src;
|
||||
srcskip = info->src_skip;
|
||||
dst = (Uint32 *) info->dst;
|
||||
dstskip = info->dst_skip / 4;
|
||||
|
||||
@@ -56,7 +56,7 @@ SDL_Blit_Slow(SDL_BlitInfo * info)
|
||||
|
||||
while (info->dst_h--) {
|
||||
Uint8 *src = 0;
|
||||
Uint8 *dst = (Uint8 *) info->dst;
|
||||
Uint8 *dst = info->dst;
|
||||
int n = info->dst_w;
|
||||
srcx = -1;
|
||||
posx = 0x10000L;
|
||||
|
||||
@@ -88,7 +88,7 @@ SDL_CalculateShapeBitmap(SDL_WindowShapeMode mode,SDL_Surface *shape,Uint8* bitm
|
||||
pixel = (Uint8 *)(shape->pixels) + (y*shape->pitch) + (x*shape->format->BytesPerPixel);
|
||||
switch(shape->format->BytesPerPixel) {
|
||||
case(1):
|
||||
pixel_value = *(Uint8*)pixel;
|
||||
pixel_value = *pixel;
|
||||
break;
|
||||
case(2):
|
||||
pixel_value = *(Uint16*)pixel;
|
||||
@@ -141,7 +141,7 @@ RecursivelyCalculateShapeTree(SDL_WindowShapeMode mode,SDL_Surface* mask,SDL_Rec
|
||||
pixel = (Uint8 *)(mask->pixels) + (y*mask->pitch) + (x*mask->format->BytesPerPixel);
|
||||
switch(mask->format->BytesPerPixel) {
|
||||
case(1):
|
||||
pixel_value = *(Uint8*)pixel;
|
||||
pixel_value = *pixel;
|
||||
break;
|
||||
case(2):
|
||||
pixel_value = *(Uint16*)pixel;
|
||||
|
||||
@@ -153,7 +153,7 @@ SDL_bool Wayland_Vulkan_CreateSurface(_THIS,
|
||||
(PFN_vkGetInstanceProcAddr)_this->vulkan_config.vkGetInstanceProcAddr;
|
||||
PFN_vkCreateWaylandSurfaceKHR vkCreateWaylandSurfaceKHR =
|
||||
(PFN_vkCreateWaylandSurfaceKHR)vkGetInstanceProcAddr(
|
||||
(VkInstance)instance,
|
||||
instance,
|
||||
"vkCreateWaylandSurfaceKHR");
|
||||
VkWaylandSurfaceCreateInfoKHR createInfo;
|
||||
VkResult result;
|
||||
|
||||
@@ -182,7 +182,7 @@ SDL_bool X11_Vulkan_CreateSurface(_THIS,
|
||||
if(videoData->vulkan_xlib_xcb_library)
|
||||
{
|
||||
PFN_vkCreateXcbSurfaceKHR vkCreateXcbSurfaceKHR =
|
||||
(PFN_vkCreateXcbSurfaceKHR)vkGetInstanceProcAddr((VkInstance)instance,
|
||||
(PFN_vkCreateXcbSurfaceKHR)vkGetInstanceProcAddr(instance,
|
||||
"vkCreateXcbSurfaceKHR");
|
||||
VkXcbSurfaceCreateInfoKHR createInfo;
|
||||
VkResult result;
|
||||
@@ -213,7 +213,7 @@ SDL_bool X11_Vulkan_CreateSurface(_THIS,
|
||||
else
|
||||
{
|
||||
PFN_vkCreateXlibSurfaceKHR vkCreateXlibSurfaceKHR =
|
||||
(PFN_vkCreateXlibSurfaceKHR)vkGetInstanceProcAddr((VkInstance)instance,
|
||||
(PFN_vkCreateXlibSurfaceKHR)vkGetInstanceProcAddr(instance,
|
||||
"vkCreateXlibSurfaceKHR");
|
||||
VkXlibSurfaceCreateInfoKHR createInfo;
|
||||
VkResult result;
|
||||
|
||||
Reference in New Issue
Block a user