it's been almost 4 hours trying to load image to wii using Libwiisprite library but nothing happened . so please I need some extra help here
this is my code and when I compiling it using wiiload everything goes well , but when I run it , a black screen comes and then the program close by it self and return to the homebrew channel :
Code: Select all
#include <stdio.h>
#include <stdlib.h>
#include <gccore.h>
#include <wiiuse/wpad.h>
#include <fat.h>
#include <wiisprite.h>
using namespace wsp;
GameWindow gwd; // Initializes and renders our scene.
Sprite sprite; // The drawable object we can modify.
Image image; // Holds our image/texture from the SD Card.
int main(int argc, char **argv) {
// Initialize filesystem to load from SD Card
fatInitDefault();
gwd.InitVideo();
LayerManager manager(1);
if(image.LoadImage("I don't know how to put the path using wiiload, though I tried everything but nothing worked??") != IMG_LOAD_ERROR_NONE)exit(0);
sprite.SetImage(&image);
sprite.SetPosition(0, 0);
manager.Append(&sprite); // Gets drawn the closest.
WPAD_Init();
WPAD_SetDataFormat(WPAD_CHAN_0, WPAD_FMT_BTNS_ACC_IR);
while(1) {
WPAD_ScanPads();
if(WPAD_ButtonsDown(WPAD_CHAN_0)&WPAD_BUTTON_HOME)
break;
// Draw everything what's in the manager.
manager.Draw(0, 0);
gwd.Flush();
}
manager.Draw(0, 0);
gwd.Flush();
return 0;
}
also this is the files with the source and everything :
http://www.mediafire.com/?y6wg0gpg7a5e5kv
pleeeeeeeeeeease help !!!