Homebrew Project SDL 2 port ongoing

JeffRuLz

Well-Known Member
Member
Joined
Sep 14, 2018
Messages
165
Trophies
0
XP
2,595
Country
United States
If you are willing to create a branch of Abbaye which calls SDL_SetWindowDisplayMode to set the video mode, then it will be easier for me to add the missing support.
Apologies dude, I didn't notice you requested this until now. I made a branch here: https://github.com/JeffRuLz/abbayedesmorts-3ds/tree/wii

First of all, I made it so it sets the display mode to 320x240 if it detects a file called 240p.txt (here). I'm not really sure if I did that correctly.
Also, setting SDL_WII_JOYSTICK_SIDEWAYS doesn't seem to change anything. The d-pad is still oriented like the remote is upright. It's set before SDL_Init so I'm not sure what I'm doing wrong there.

And lastly, since this game runs at 256x192 I wanted to display it in the center of the screen with a border filling the remaining space. When the window size doesn't match the logical size then the game is displayed in the top left corner. I believe the standard SDL behavior is to center the screen to the window, but I may be remembering wrong.
 

Fancy2209

Member
Newcomer
Joined
Aug 8, 2021
Messages
16
Trophies
0
Age
23
XP
113
Country
Portugal

Fancy2209

Member
Newcomer
Joined
Aug 8, 2021
Messages
16
Trophies
0
Age
23
XP
113
Country
Portugal
Also, I (succesfully this time) ported Sonic Robo Blast 2.1.25 to the Wii, but the Joystick api reports there are 0 Joysticks avaliable, this prevents me from using any kind of controller, Wii Remote, Classic Controller or GameCube Controller.
Any ideas? It's not that great to need to plug a keyboard in.
This is the repo: https://github.com/Fancy2209/SRB2/tree/Wii2125
 
Last edited by Fancy2209,

mudrik

Member
OP
Newcomer
Joined
Nov 18, 2022
Messages
23
Trophies
0
Age
31
XP
207
Country
Turkey
Also, I (succesfully this time) ported Sonic Robo Blast 2.1.25 to the Wii, but the Joystick api reports there are 0 Joysticks avaliable, this prevents me from using any kind of controller, Wii Remote, Classic Controller or GameCube Controller.
Any ideas? It's not that great to need to plug a keyboard in.
This is the repo: https://github.com/Fancy2209/SRB2/tree/Wii2125
The problem is that joysticks take some time to appear. You can either change to the polling API, or add this at the beginning of the game (after SDL_init()):
while (SDL_NumJoysticks() == 0) { SDL_PumpEvents(); }
 

MoiCJarod

New Member
Newbie
Joined
Jun 15, 2024
Messages
1
Trophies
0
Age
43
XP
7
Country
France
Hello !
I'm a french computer science teacher triing to make my pupils code some retro games on the wii. Since this year I was using GRRLIB for graphics and asndlib for the sound. Found that sound library was not so good (only 1 sound at a time) and was seeking for other solutions. Then I saw that SDL2 was available in pacman for the wii and wanted to give it a try.

So i tried to compile an exemple (SudokuL) but I went into the "undefined reference to `SDL_main'" error.

steps :
Installing SDL2, SDL2_mixer, SDL2_ttf ... from pacman
downloading SudokuL sources and unzipping
renaming makefile_wii to Makefile
launching make then

/opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.2.0/../../../../powerpc-eabi/bin/ld: /opt/devkitpro/portlibs/wii/lib/libSDL2main.a(SDL_wii_main.o): in function `main': /home/davem/projects/devkitpro/pacman-packages/wii/SDL2/src/SDL2-2.28.5/_build/../src/main/wii/SDL_wii_main.c:86:(.text.startup.main+0xcc): undefined reference to `SDL_main' collect2: error: ld returned 1 exit status

What am I doing Wrong ?

Thanks in advance :-)

System : Ubuntu 22.04
 
Last edited by MoiCJarod,

Mode8fx

Active Member
Newcomer
Joined
Nov 14, 2019
Messages
31
Trophies
0
XP
215
Country
United States
Hello !
I'm a french computer science teacher triing to make my pupils code some retro games on the wii. Since this year I was using GRRLIB for graphics and asndlib for the sound. Found that sound library was not so good (only 1 sound at a time) and was seeking for other solutions. Then I saw that SDL2 was available in pacman for the wii and wanted to give it a try.

So i tried to compile an exemple (SudokuL) but I went into the "undefined reference to `SDL_main'" error.

steps :
Installing SDL2, SDL2_mixer, SDL2_ttf ... from pacman
downloading SudokuL sources and unzipping
renaming makefile_wii to Makefile
launching make then

/opt/devkitpro/devkitPPC/bin/../lib/gcc/powerpc-eabi/13.2.0/../../../../powerpc-eabi/bin/ld: /opt/devkitpro/portlibs/wii/lib/libSDL2main.a(SDL_wii_main.o): in function `main': /home/davem/projects/devkitpro/pacman-packages/wii/SDL2/src/SDL2-2.28.5/_build/../src/main/wii/SDL_wii_main.c:86:(.text.startup.main+0xcc): undefined reference to `SDL_main' collect2: error: ld returned 1 exit status

What am I doing Wrong ?

Thanks in advance :-)

System : Ubuntu 22.04
You have to also move the makefile up a directory into SuDokuLVS2019. I put the makefiles in their own subdirectory a while back and forgot to update the readme accordingly; sorry about that!
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Xdqwerty @ Xdqwerty: @Psionic Roshambo, i don't have money