mirror of
https://github.com/yawut/SDL.git
synced 2026-08-19 23:34:04 -05:00
render/wiiu: Fix compiler warnings
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
#include <gx2/clear.h>
|
||||
#include <gx2/mem.h>
|
||||
#include <gx2/event.h>
|
||||
#include <gx2r/surface.h>
|
||||
#include <gx2r/buffer.h>
|
||||
#include <gx2r/draw.h>
|
||||
|
||||
|
||||
@@ -189,7 +189,6 @@ void WIIU_SDL_DestroyRenderer(SDL_Renderer * renderer)
|
||||
int WIIU_SDL_RenderReadPixels(SDL_Renderer * renderer, const SDL_Rect * rect,
|
||||
Uint32 format, void * pixels, int pitch)
|
||||
{
|
||||
WIIU_RenderData *data = (WIIU_RenderData *) renderer->driverdata;
|
||||
SDL_Texture* target = WIIU_GetRenderTarget(renderer);
|
||||
WIIU_TextureData* tdata = (WIIU_TextureData*) target->driverdata;
|
||||
|
||||
|
||||
@@ -9,8 +9,9 @@
|
||||
#include "SDL_render_wiiu.h"
|
||||
|
||||
#include <whb/gfx.h>
|
||||
#include <gx2/draw.h>
|
||||
#include <gx2/registers.h>
|
||||
#include <gx2/state.h>
|
||||
#include <gx2/draw.h>
|
||||
#include <gx2r/buffer.h>
|
||||
#include <gx2r/draw.h>
|
||||
|
||||
|
||||
@@ -188,17 +188,23 @@ int WIIU_SDL_UpdateTexture(SDL_Renderer * renderer, SDL_Texture * texture,
|
||||
int WIIU_SDL_SetTextureColorMod(SDL_Renderer * renderer, SDL_Texture * texture)
|
||||
{
|
||||
WIIU_TextureData *tdata = (WIIU_TextureData *) texture->driverdata;
|
||||
|
||||
/* Compute color mod */
|
||||
tdata->u_mod.r = (float)texture->r / 255.0f;
|
||||
tdata->u_mod.g = (float)texture->g / 255.0f;
|
||||
tdata->u_mod.b = (float)texture->b / 255.0f;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int WIIU_SDL_SetTextureAlphaMod(SDL_Renderer * renderer, SDL_Texture * texture)
|
||||
{
|
||||
WIIU_TextureData *tdata = (WIIU_TextureData *) texture->driverdata;
|
||||
|
||||
/* Compute alpha mod */
|
||||
tdata->u_mod.a = (float)texture->a / 255.0f;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void WIIU_SDL_DestroyTexture(SDL_Renderer * renderer, SDL_Texture * texture)
|
||||
|
||||
Reference in New Issue
Block a user