5#ifndef _GDL_WII_IMAGE_H
6#define _GDL_WII_IMAGE_H
11#include <mgdl/wii/mgdl-wii-texture.h>
12#include <mgdl/wii/mgdl-wii-types.h>
54 void _PrepareImage(
short xRes,
short yRes);
55 bool _ProcessImage(png_structp png_ptr, u_int minFilt, u_int magFilt, u_int format,
bool mipmapped,
short maxMips);
90 bool Create(
short xRes,
short yRes, u_int filterMode, u_int format =
RGBA8);
113 bool CreateMipmapped(
short xSize,
short ySize, u_int minFilt, u_int magFilt,
short maxMipmaps, u_int format =
gdl::RGBA8);
139 bool LoadImage(
const char *fileName, u_int filterMode, u_int format =
RGBA8);
180 bool LoadImageMem(
void *imagePtr, u_int filterMode, u_int format);
200 bool LoadImageBuffer(
const void *buffer,
size_t size, u_int filterMode, u_int format);
230 void Put(
short x,
short y,
Color4f* col,
short cx = 0,
short cy = 0,
float scale = 1.f,
float angle = 0.f);
245 void PutS(
short x1,
short y1,
short x2,
short y2,
Color4f* col);
Image handling class.
Definition mgdl-wii-image.h:47
void PutS(short x1, short y1, short x2, short y2, Color4f *col)
Draws an image as a stretchable rectangle.
Definition wii-image.cpp:927
virtual ~ImageWii()
Deconstructor.
Definition wii-image.cpp:698
bool LoadImage(const char *fileName, u_int filterMode, u_int format=RGBA8)
Loads an image.
Definition wii-image.cpp:730
void Put(short x, short y, Color4f *col, short cx=0, short cy=0, float scale=1.f, float angle=0.f)
Draws the image onto the screen with more options.
Definition wii-image.cpp:920
bool LoadImageBuffer(const void *buffer, size_t size, u_int filterMode, u_int format)
Loads an image from memory.
Definition wii-image.cpp:857
bool LoadImageMem(void *imagePtr, u_int filterMode, u_int format)
Loads an image from a memory block.
Definition wii-image.cpp:834
bool Create(short xRes, short yRes, u_int filterMode, u_int format=RGBA8)
Creates an image.
Definition wii-image.cpp:708
gdl::Texture Texture
gdl::Texture object containing the actual texture data of the image.
Definition mgdl-wii-image.h:61
ImageWii()
Constructor.
Definition wii-image.cpp:689
short Ysize()
Returns the Y size of the image in pixels.
Definition wii-image.cpp:914
short Xsize()
Returns the X size of the image in pixels.
Definition wii-image.cpp:908
bool CreateMipmapped(short xSize, short ySize, u_int minFilt, u_int magFilt, short maxMipmaps, u_int format=gdl::RGBA8)
Creates a mipmapped image.
Definition wii-image.cpp:719
bool LoadImageMipmapped(const char *fileName, u_int minFilt, u_int magFilt, short maxMipmaps, u_int format=gdl::RGBA8)
Loads an image with mipmap generation.
Definition wii-image.cpp:800
Texture handling class.
Definition mgdl-wii-texture.h:58
void SaveScreen(const char *fileName)
Saves a screenshot.
Definition wii-image.cpp:937
@ RGBA8
32-bit RGBA8 pixel format (4 bytes per pixel).
Definition mgdl-wii-texture.h:38
Color struct and functions.
Library namespace.
Definition wii-globals.cpp:12
Definition mgdl-color.h:54