Previous Thread
Next Thread
Print Thread
Page 1 of 7 1 2 3 4 5 6 7
#26072 01/23/07 03:11 AM
Joined: Jan 2007
Posts: 23
P
Member
Member
P Offline
Joined: Jan 2007
Posts: 23
Thanks for sdl mame, this stuff is great.

I searched the forums but didn't find anything, so here goes w/ some questions:

With a tiny-little fiddling, I got sdl mame 111u4 to compile & run (albeit with caveats) on a sony ps3 under (yellow dog) linux.

If you don't have a patch already, I can clean it up and hand it over (set PPC = 1 in the makefile, and a handful of #define & #undefs in some source files to make headers happy (maybe better moved to CFLAGS?)).

I had to compile libsdl 1.2.11 from sources (w/ --disable-opengl or so).

I got it to run it w/ command line like this:
./mameppc -switchres -screen_aspect 16:9 -r 1124x644 mspacman

The -r 1124x644 is compatible w/ the ps3's "video mode 3" - the only "mode" through which I was able to get something other than a blank display. I don't think 1124x644 is a 'standard hd resolution', but it worked here.

The image occupies only a fraction of the available screen-space - a 1:1 mapping w/ the original resolution? I tried -prescale (& -maximize) without any difference. I'll keep digging around, but is there something else I should try?

The sound is garbled. Fwiw, I think the SDL test suite playloop sound test has similar issues. I see a reported 96000 hz speed for the sound in mspacman - seems high? - so maybe something there.

Thanks for your time,
Phil

Joined: Mar 2001
Posts: 17,258
Likes: 267
R
Very Senior Member
Very Senior Member
R Online: Content
Joined: Mar 2001
Posts: 17,258
Likes: 267
It's stuff like this that makes me a Fedora supremecist wink On PS3 FC5 SDLMAME compiles and runs literally out of the box with 2 quick makefile edits.

Anyway, the next release will have a CELL target that automates the necessary edits. Post a patch and I'll see what can be integrated without breaking the mainstream distros.

ALSA audio seems to be broken on PS3 Linux - I noticed this in MPlayer and Xine also. You might try setting whatever SDL environment variable to use OSS instead. And finally, running SDLMAME under X will make it much, much happier. You will get (software) stretch when you go full-screen, for instance.

Joined: Jan 2007
Posts: 23
P
Member
Member
P Offline
Joined: Jan 2007
Posts: 23
Cool - yeah, the yellow dog was supposed to be sony's favorite pet- but it seems relatively unremarkable? Debian distro was near and dear to me a ways back, good times. Maybe I should get another hard drive and install fedora.

Patch was next-to-nothing in terms of changes, as above, but let me go verify & make it a little more pleasent.

I only got the ps3 a few days ago, so I haven't tried out much in the way of anything yet. Rebuilt the kernel, rebuilt kboot, messed around with advancemame, then found this, ...

Thanks, I'll play w/ the OSS switches & SDL and see if anything gives, try running in X (been running from a virtual console), etc.

Joined: Jan 2007
Posts: 23
P
Member
Member
P Offline
Joined: Jan 2007
Posts: 23
The diff is appended - works w/ small additions to the makefile.

I added a couple of comments to clarify use of some of the CFLAGS.

I'm noticing a message now (might've missed a change in my CFLAGS cleanup? Or perhaps stale build file?):
Unexpected boolean option rdtsc queried
... but this doesn't seem to matter, mame continues to execute normally.

mspacman runs @ almost perfect frame rate- though I'm still only able to use the virtual console w/ ps3 video mode 3. Trying under X11, it doesn't pop up a window; I'll poke around more, probably something dumb I did.

[root@localhost sdlmame0111u4]# diff makefile ../sdlmame0111u4-new/makefile
110a111,116
> PS3 = 1
>
> ifdef PS3
> PPC = 1
> endif
>
211a218,223
> ifdef PS3
> NAME = ${PREFIX}${TARGET}ppc
> # add -march for cell
> ARCH =
> endif
>
307a320,324
> ifdef PS3
> # -uX86_ASM needed for issue w/ src/sdl/sdltime.c
> # -DPPC_ASM for src/sdl/osinline.h
> CFLAGS += -DSDLMAME_LINUX -uSDL_PROTOTYPES_ONLY -DSDL_VIDEO_DRIVER_X11 -uX86_ASM -DPPC_ASM
> endif
[root@localhost sdlmame0111u4]#

Joined: Mar 2001
Posts: 17,258
Likes: 267
R
Very Senior Member
Very Senior Member
R Online: Content
Joined: Mar 2001
Posts: 17,258
Likes: 267
The rdtsc message is normal, it'll go away in u5.

Joined: Jan 2007
Posts: 23
P
Member
Member
P Offline
Joined: Jan 2007
Posts: 23
Recompiled & reinstalled SDL a few times, tried a bunch of stuff:


SOUND: SDL w/ --disable-alsa does something to the sound- seemingly sounds better than alsa, though not perfect. The SDL loopwave test also still is distorted (in the high-end).


GL: I rebuilt SDL w/ --enable-opengl (found libGL.so in /usr/lib). Yellow dog distro doesn't appear to include <GL/glu.h> (which SDL wanted) - though yd /usr/lib/libGLU.so exists. Commented the #include out and SDL built.

While SDL/test/testgl compiles & links, it fails w/ "Couldn't set GL mode: OpenGL not available".


WINDOW: *none* of the SDL test suite runs in a window -- all video tests go fullscreen, including testwin.c. Even after explicit unset of SDL_FULLSCREEN in video_flags before the call to "screen=SDL_SetVideoMode(h,w,bpp,video_flags)", (screen->flags & SDL_FULLSCREEN) returns set. So no windows - something's fishy.

SDL's testvidinfo reports only a fbcon device with capability of a singular fullscreen resolution of 1280x1024x32.

But if I change to /sbin/ps3videomode -v 2 (or 7) from a console, I can see a testvidinfo "Current resolution" of 576x384 (or 576x460) - even though the log still reports only the capability of a single resolution of 1280x1024x32.

In -v 2 (or -v 7), none of the graphical SDL tests work properly: either presenting a blank screen, or presenting what looks like a "scrambled interlaced" pattern of what the normal image might be.

Seems fbcon driver lacks the knowledge of ps3videomode capabilities, perhaps is the source of the SDL_FULLSCREEN bit always getting set, is the root of all evil?


I'll hack on this a bit longer- but your suggestion of FC5 install seems path of least headache- the yellow dog might do well to get a flea collar.

Joined: Jan 2007
Posts: 23
P
Member
Member
P Offline
Joined: Jan 2007
Posts: 23
Got alternate console resolutions to work, finally. Still no SDL window, just fullscreen console. Plays fine, gotta fix sound, figure out how to get joystick & driving wheel working, ...

Made some interesting finds along the way - may be old news, but in case somebody doesn't know:

If you want "true HD 720p" (1280x720 - not have bars on the sides of the screen as per- "margins" as described in linux/drivers/video/ps3fb.c), then use ps3videomode 131 -- NOT 3.

Or, /sbin/ps3videomode -v 3 -f

-f is for "full screen" which I'd've called "no-margin" or "no-border", probably got lost in translation.

If you want a "good mame experience", try ps3videomode 130 (480p) or 135 (576p), if your display device can handle it. After you switch modes (I do it from a virtual console (shift+ctrl+f2), and you have to be su), run mame as per:

./mameppc -switchres -r 720x480 mspacman
./mameppc -switchres -r 720x576 mspacman

You have to match the -r values with the ps3videomode- didn't work for me until I explicitly specified these on command line.

While it doesn't maximally fill the screen, its waaaay better (at least for me w/ a ~200 inch screen via front projector).

Now onto sound...

Joined: Jan 2007
Posts: 23
P
Member
Member
P Offline
Joined: Jan 2007
Posts: 23
Ooops, I must be more whacked on yellow-dog scooby-snacks than I realize; fwiw that key sequence for virtual console is ctrl+alt+(f1 or f2 ... f7 brings back x11-rooted console) - not shift+ctrl+f2

whatever, just bang on the keyboard a lot until it gets right.

Joined: Jan 2007
Posts: 23
P
Member
Member
P Offline
Joined: Jan 2007
Posts: 23
So trip out - alsa works cleanly for me - its oss (/dev/dsp) that is garbled.

Thanks for the environment variable tip! Maybe that's what you meant to type above, or maybe I'm reading cross-eyed, or whatever. I'm a newbie smile

I'm using a kernel built from yellow-dog sources.

btw, fc5 is 'not optimized for the [crappy] ram in ps3'. Or at least so says wikipedia: http://en.wikipedia.org/wiki/PS3 Guess the old yellow dog might still have a few tricks up its sleeve. Whatever. Once again, maybe old news, but my reaction is no shit- where's that PSGL???

So, before launching mame, typing this:

export SDL_AUDIODRIVER=alsa

gets nice audio. It works for the SDL loopwave test too, just in case you like hearing the same "I met a woman one night, crying black & blue tears & [something or other]". Where's that from?

I'd like to get the controllers working, throw a stupid front(al lobe)-end in kernel arg init= via an iso9660 image's etc/kboot.conf; I could make a disc even my girlfriend could use. That'd be nice, she likes ms. pac man. Its crazy how anorexic chicks dig games where you eat stuff.





Last edited by Phil Hopely; 01/25/07 09:22 AM.
Joined: Jan 2007
Posts: 15
Z
Member
Member
Z Offline
Joined: Jan 2007
Posts: 15
I know it's asking a lot, but could you post a step-by-step guide on how you got this working, like what to what and where to download, how to compile , what options to use, etc...?

Thanks,
Zep--

Page 1 of 7 1 2 3 4 5 6 7

Moderated by  R. Belmont 

Link Copied to Clipboard
Who's Online Now
2 members (Pernod, MAMEBase), 127 guests, and 0 robots.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics9,355
Posts122,423
Members5,082
Most Online1,283
Dec 21st, 2022
Our Sponsor
These forums are sponsored by Superior Solitaire, an ad-free card game collection for macOS and iOS. Download it today!

Superior Solitaire
Powered by UBB.threads™ PHP Forum Software 8.0.0