Forums

Sega Master System / Mark III / Game Gear
SG-1000 / SC-3000 / SF-7000 / OMV
Home - Forums - Games - Scans - Maps - Cheats
Music - Videos - Development - Translations - Homebrew

SMS Power! 17th Anniversary Competitions are now in progress! Listen, play, vote!


View topic - Meka 0.80 with new sound engine *TESTERS WANTED!*

Reply to topic Goto page 1, 2, 3, 4, 5, 6  Next
Author Message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Meka 0.80 with new sound engine *TESTERS WANTED!*
Post Posted: Wed Apr 06, 2011 3:06 pm
Last edited by Bock on Sun May 27, 2012 9:40 pm; edited 7 times in total
We started working on converting MEKA to Allegro 5 API.
It is a rather major change and may take a while.

//// If you are curious the working branch is here:
//// svn://svn.smspower.org/meka/branches/20110530-allegro5-sound
*EDIT* Moved back into trunk: svn://svn.smspower.org/meka/trunk/meka

CHECK LATEST POSTS IN THIS THREAD FOR THE NEWEST BUILD
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Mon May 02, 2011 2:30 pm
The code now compiles and link with Allegro 5.
But of course:
- nothing work (still welcomed by a back screen)
- many features were disabled
Hopefully I'll have more time today and may try to get it to a semi working state. I expect a lot of video rendering to be off, timing and sound to be off, using slow software rendering, etc. Still, it is on a good path :)
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Mon May 02, 2011 11:27 pm
Its starting to work (GUI shows) but with a lot of glitches and very slow because of the amount of locking and transfert/conversion between various memory formats and WGL contexts.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Mon May 09, 2011 12:03 am
Games plays in GUI mode (very slowly), and fixed a lot of the small visual glitches in the GUI.
Also now using stock precompiled versions of Allegro and moved zlib inside the MEKA package so compiling MEKA is now becoming a lot easier,

It should now be, finger crossed:
- Get Allegro precompiled binaries (eg: allegro-5.0.2-1-msvc-9.0.zip from http://www.allegro.cc/files/) and unzip.
- Setup Allegro librairies and include directories in Visual Studio setup.
- Compile MEKA.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sat May 14, 2011 11:43 am
I reduced the number of lock/release and transfer/conversion between formats and memory and got Psycho Fox running smoothly in GUI mode now.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
C++
Post Posted: Sun May 15, 2011 12:52 am
MEKA now compiles in C++ mode. I have fixed all implicit casts, enumerations, external definitions, mangling issues for NASM linkage, etc.. The codebase can now use all of C++ features.

(The commit is r176, there's about 200 files changed.)

Even if the architecture is probably gonna stay in C++-with-struct style, things like function overloading, declaration of local variable mid-scope, default parameters, etc. are helping making new code easier to write and maintain.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Trimming
Post Posted: Wed May 25, 2011 12:22 am
Working better now, lots of bug fixes.

I am also trimming a lot of the very old features, MS-DOS code, mini game easter eggs and NES emulation. Make it lighter and more maneuverable for the future.

I am considering porting to direct OpenGL and completely removing Allegro 5 but this is still undecided, I will probably keep working on completing the Allegro 5 port first.

Have to fix the sound and hopefully this will become MEKA 0.80.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sat May 28, 2011 10:34 pm
Fixed a lot of more bugs.
Still missing:
- sound (completely disabled now)
- proper sync (i think it just wait for vsync)
- various video/blitter settings

Its a bit early but i would be happy if some people would be interested in checking out the code and giving it a try.

I forgot to mention above that NASM is still required to compile under Windows. I am considering including it in the package to simplify deployment.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sat May 28, 2011 10:44 pm
NASM is now included in the MEKA repository so there's no need to download it anymore.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
OpenGL/DirectX
Post Posted: Sun May 29, 2011 3:58 pm
The codebase can now works with both OpenGL and DirectX under Windows and I removed the requirement of specific pixel format making things hopefully faster.

I am getting ~500 FPS unthrottled for game only display but lower framerate in GUI with many apps enabled because tile viewer and tilemap viewer requires locking a video memory bitmap for now. ~500 FPS isn't actually a great speed but there's lots of overhead with all the Allegro subsystems right now. I guess it should be enough I'm just hoping that GUI applets won't be a problem.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sun May 29, 2011 7:06 pm
Re-added throttling code and made various other fixes. Still no sound and a few missing bitters (HQ2X etc.).
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Sound
Post Posted: Mon May 30, 2011 1:05 am
I branched to svn://svn.smspower.org/meka/branches/20110530-allegro5-sound

And deleted absolutely all references to SEAL and the old Sasound sound engine. This is the best day of my life. Now on to reconstruct it properly, hopefully.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Mon May 30, 2011 9:31 pm
I rewrote the sound streaming system today and got sounds (along with sampled audio) working OK. Its not perfect and there's quite a lot of issues with the timing of video and sound, but I've got brand new code here so its easy to improve on it.

There's no dependency anymore on SEAL and none of the old "gap" problem (although the sound still have latency issues I am working on).

  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
TODO
Post Posted: Mon May 30, 2011 11:58 pm
Here's a list of the main things to do:

- Finish the sound engine, make it work under various speeds and generally solidify and fix remaining glitches.

- Improve performance drops, mostly related to interface render (fonts drawing seems to be rather slow with Allegro 5, and there's lots of black voodoo the library is trying to do to help instead of directing the programmer toward better solution so its tricky to find out bottleneck).

- Video mode switch (GUI<>game and windowed<>fullscreen) are currently very slow.

- Re-implement missing blitters/effects and make video settings more friendly (e.g.: remove black border in windowed modes).

- General tweaks to make MEKA more friendly with today's OS and applications best practices.

- Lots of minor fixes and probably broken features.

Do we have a GNU/Linux package maintainer reading this thread? From now on, provided the GNU/Linux version is made up to date with the latest changes the sound should be working. I also imagine MEKA should easily compile for MacOS now.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Test build
Post Posted: Wed Jun 01, 2011 12:03 am
Attached is a test build for Win32 using Allegro 5 and the new sound engine. I'd be interested in getting feedback about how it works, graphics and sound wise. I would expect the build to have many issues but its a first test.

I am aware that the sound engine sometimes have latency issues and samples output is not perfect, but it should be miles above previous versions of MEKA for Windows.

Also please note that sound in this version is only supported if you are running a NTSC machine with 60 Hz speed.

For the sake of testing you can change "directx" for "opengl" in the configuration file, but I think DirectX works better.

  View user's profile Send private message Visit poster's website
  • Joined: 18 Aug 2006
  • Posts: 60
Reply with quote
Post Posted: Wed Jun 01, 2011 11:35 pm
Okay, I just tested the new build and here's what I found so far (ready to sleep):

- Yay, new MEKA :)
- The loading takes a bit longer but not complaining in DirectX mode.
- Opengl mode however loads really... slow... except fullscreen mode in a game where it runs fine.
- Sound has much improved as in no clicking or distortion for the most part. Due to tone deaf and timing, not sure whether any sound is out of sync apart from when a sound triggers and when you load a new ROM/reset game it plays.
- Frameskip 1/1 seems to be faster than it should. I thought 1/1 meant that it is normal speed?
- When pausing with the F12 button, the screen becomes out of align by showing a bottom border and a right border.
- The Documentation and the Tilemap Windows show garbage when you move them. (This happened before in previous Meka builds)
- If a word uses unicode in the Documentation Window, the rest of the line gets skipped.
- Sometimes the mouse freezes for a couple of seconds. (I got this 3 times in about a 20 minute play).
- You can no longer print screen with the Alt-Print Screen command, it automatically makes a screenshot in the Screenshot folder (like when you just press Print Screen).
- The Deep Duck Trouble/ Sonic Chaos bug might be fixed but it is very hard to trigger the bug due to it being random.
- Apart from that, it is pretty good for a first test.
Great Soccer (Japan)-05.png (55 KB)
When pausing, it goes out of align
Great Soccer (Japan)-05.png
meka-02.png (70.04 KB)
The window and the unicode glitch
meka-02.png

  View user's profile Send private message
  • Joined: 27 Apr 2005
  • Posts: 402
  • Location: Australia
Reply with quote
Post Posted: Thu Jun 02, 2011 12:32 am
Input configuration - I had no gamepad or joystick plugged in and tried to configure joypad 1, and that crashed
I plugged in a USB-PSX converter before starting again and it did not crash then but any input instantly went Stick 0 Axis 0 -
Went and checked the analog calibration in windows control panel and it seemed ok there.

Bloodlust theme (dripping cursor) KILLS performance, many frames dropped
Girl Power (hearts) also affected, less so, plus they leave a 'burnt trail'

Taking note of the 60Hz NTSC issue
Loading 50Hz games (space harrier 50hz, california games 50hz and sonic 2?)
I noticed the bugging out sound buffer messages.
Setting frameskip Auto 50Hz before loading the rom makes it work just fine.

Super Wonder Boy in Monster World (JP)
not exactly sure this is a bug related to Meka, but waiting at the title screen will cause a repeating sound. (only happens on export, jap mark3 is ok)
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Test build
Post Posted: Fri Jun 03, 2011 12:04 am
Thanks for the bug reports guys! I am moving house this week-end so may not have much time to work on MEKA.

Attached is new build
- Fixed crash in INPUTS CONFIGURATION window when joystick is not found.
- Disabled blood/heart effects for the moment (i actually made them fast today but then decided they looked quite lame.. I'll eventually get them back when they look better).
- Fixed UTF-8 in documentation.
- Fixed glitches in documentation viewer.
- Preserving order of windows between runs (quite convenient not sure why i didn't do it before).

  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Fri Jun 03, 2011 12:15 am
Now to answer questions

Quote
- Yay, new MEKA :)
- The loading takes a bit longer but not complaining in DirectX mode.
- Opengl mode however loads really... slow... except fullscreen mode in a game where it runs fine.


You mean the booting of MEKA is slow or take longer?
Here I get MEKA booting up in ~2s which I think is quite good.

About GUI being slow. The paradigm for accessing video buffers changed quite a bit with Allegro 5 so the slow down may be due to a certain window in particular. Can you try turning off window see if it gets better or not? Additionally the behavior between DirectX and OpenGL are different with Allegro drivers so its a bit of a pain to see some bugs (for example the tilemap glitch you mentioned I think only happens with DirectX driver).

Quote
- Frameskip 1/1 seems to be faster than it should. I thought 1/1 meant that it is normal speed?


No, 1/1 is unthrolled "max" emulation speed. It can however be limited by vsync in some cases. Its a bit of an artifact of early days when emulators had to skip frames so I plan to actually remove this feature, and instead replace it by a "fast" throttled setting for fast forwarding.

Quote
- When pausing with the F12 button, the screen becomes out of align by showing a bottom border and a right border.

Couldn't reproduce. Does it happen with both DirectX and OpenGL? Does it happens everytime?

Quote
- The Documentation and the Tilemap Windows show garbage when you move them. (This happened before in previous Meka builds)

Documentation is fixed now. About Tilempa, do you mean garbage when moving the cursor when the tilemap is not showing (eg: before loading a game)? or is it something else.

Quote
- If a word uses unicode in the Documentation Window, the rest of the line gets skipped.

Fixed now, thanks.

Quote
- Sometimes the mouse freezes for a couple of seconds. (I got this 3 times in about a 20 minute play).

Let me know if you eventually find a pattern to that.

Quote
- You can no longer print screen with the Alt-Print Screen command, it automatically makes a screenshot in the Screenshot folder (like when you just press Print Screen).

I am not sure what you mean. You mean you want to use the native Windows way of capturing the screen? Both PrintScreen and Alt-PrintScreen gave me the fullscreen and single window buffer in Windows clipboard here (using Windows 7).

Quote
- The Deep Duck Trouble/ Sonic Chaos bug might be fixed but it is very hard to trigger the bug due to it being random.

I am not sure which bug you are talking about, sorry.

DMEnduro:
DMEnduro wrote
Input configuration - I had no gamepad or joystick plugged in and tried to configure joypad 1, and that crashed

Fixed.

Quote
I plugged in a USB-PSX converter before starting again and it did not crash then but any input instantly went Stick 0 Axis 0 -
Went and checked the analog calibration in windows control panel and it seemed ok there.

Will investigate. I had lots of problem with joystick recently (i installed a driver to use PS3 controllers and it is messing with my controllers quite a lot) and haven't really tested the feature thoroughly.

Quote
Bloodlust theme (dripping cursor) KILLS performance, many frames dropped
Girl Power (hearts) also affected, less so, plus they leave a 'burnt trail'

I disabled them for now as stated above. They will be back when they look better.

Quote
Super Wonder Boy in Monster World (JP)
not exactly sure this is a bug related to Meka, but waiting at the title screen will cause a repeating sound. (only happens on export, jap mark3 is ok)

Its in the game I think, its a sort of "attract" mode.

Thanks again!
  View user's profile Send private message Visit poster's website
  • Joined: 27 Oct 2009
  • Posts: 138
Reply with quote
Post Posted: Fri Jun 03, 2011 2:18 am
Nice work Bock! I use MEKA when needing to debug and verify some things quickly, so having it work better on Windows will be good. One of my favourite emulators.
  View user's profile Send private message Visit poster's website
  • Joined: 15 Jun 2011
  • Posts: 4
Reply with quote
Post Posted: Wed Jun 15, 2011 4:27 pm
I can't get this to run in full screen.. is this a known issue?
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Wed Jun 15, 2011 5:06 pm
What happens when you press ALT+ENTER ?

I am also having problems i can't explain on my work PC with resolutions above 640x480 with DirectX driver, can't get to fullscreen (it shows nothing and i can see my windows desktop).
  View user's profile Send private message Visit poster's website
  • Joined: 15 Jun 2011
  • Posts: 4
Reply with quote
Post Posted: Wed Jun 15, 2011 9:31 pm
Bock wrote
What happens when you press ALT+ENTER ?

I am also having problems i can't explain on my work PC with resolutions above 640x480 with DirectX driver, can't get to fullscreen (it shows nothing and i can see my windows desktop).


That did it!!

So far no real complaints here and the sound is good to go!

EDIT: "complaint" was a wrong choice of words lol.. Meant to say "issues"...

Thanks for the great emu!
  View user's profile Send private message
  • Joined: 15 Jun 2011
  • Posts: 4
Reply with quote
Post Posted: Wed Jun 15, 2011 9:48 pm
Ahhh I have to add to the joypad issues... Mine won't map properly either. I noticed when you go to map the controller it will map everything to axis 0 and wont let you select anything else.

But if you hold down the button on the joypad you want to map it to BEFORE you click on the map it will assign it.

But I cant map U/D on the D Pad for some reason.. only L/R
  View user's profile Send private message
  • Joined: 18 Aug 2006
  • Posts: 60
Reply with quote
Post Posted: Thu Jun 16, 2011 1:07 pm
Quote
You mean the booting of MEKA is slow or take longer?
Here I get MEKA booting up in ~2s which I think is quite good.

About GUI being slow. The paradigm for accessing video buffers changed quite a bit with Allegro 5 so the slow down may be due to a certain window in particular. Can you try turning off window see if it gets better or not? Additionally the behavior between DirectX and OpenGL are different with Allegro drivers so its a bit of a pain to see some bugs (for example the tilemap glitch you mentioned I think only happens with DirectX driver).


- It was noticeable in the earlier build but in the new build, both DirectX and OpenGL take the same time to open in 2 seconds so it seems fixed. It must have been related to them themes.

Quote
Couldn't reproduce. Does it happen with both DirectX and OpenGL? Does it happens everytime?


- It happens every time in DirectX and OpenGL. Both in the 2011-06-01 and the 2011-06-03 builds.

Quote
Documentation is fixed now. About Tilempa, do you mean garbage when moving the cursor when the tilemap is not showing (eg: before loading a game)? or is it something else.


- I don't know why but it seems to be fixed in the new build. It happened when you had no game and when a game is running.

Quote
I am not sure what you mean. You mean you want to use the native Windows way of capturing the screen? Both PrintScreen and Alt-PrintScreen gave me the fullscreen and single window buffer in Windows clipboard here (using Windows 7).


- Whether pressing Print Screen or Alt-Print Screen, it doesn't do the Windows clipboard at all and instead outputs a png file. The reason why I use the clipboard is because there's something that I do and don't want to result in 100s of files just to delete them afterwards. Then again I'm using Windows XP so it might be different on 7.

Quote
I am not sure which bug you are talking about, sorry.


- it was this one: http://www.smspower.org/forums/viewtopic.php?p=43098&highlight=deep+duck+cha...

Right I figure that I give you my computer specifications just in case (its nearly 5 years old) they are needed:

Windows XP Media Center Edition Service Pack 3
Intel Core 2 Duo 6300 @ 1.86Ghz
1GB RAM
Graphics Card: ATI Radeon X1650SE
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Thu Jun 16, 2011 1:15 pm
Sorry joypad issue is fixed now, i will post a new build shortly.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Thu Jun 16, 2011 11:29 pm
New executable (unzip over previous build full install), i only fixed joystick mapping and running MEKA from the command-line from another directory.

(off-topic: I have now moved all my collection from France to England, sorting it out will keep me busy for a bit)

  View user's profile Send private message Visit poster's website
  • Joined: 07 Jun 2010
  • Posts: 107
  • Location: Greece
Reply with quote
Post Posted: Fri Jun 17, 2011 11:55 am
I still can't map my usb joypad... Basically, the up and down directions can't be configured... Anyone who tried last update and worked..?

Off-topic:
Are you kidding, how did you move your collection? Did you borrow an aircraft-carrier..?
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Fri Jun 17, 2011 1:15 pm
Wha happens when you try to map up/down?
Can you try messing with meka.inp see if you can map them in the configuration file and they would work?

I rented a 16 m3 Luton van and we drove London->Paris->Guildford. Ended up using about two third of the volume :)
  View user's profile Send private message Visit poster's website
  • Joined: 07 Jun 2010
  • Posts: 107
  • Location: Greece
Reply with quote
Post Posted: Fri Jun 17, 2011 2:43 pm
Bock wrote
Wha happens when you try to map up/down?

At input configuration of Joypad 1, I click on up/down and normally should be waiting to press the key I want, but automatically adds "Stick 0, Axis 0, -". The same happens with all actions/buttons adding itself "Stick 0, Axis 0, -" when you click on them. For the others if you press first the button you want and then click on action it's ok, but for up/down the trick doesn't work...

Bock wrote
Can you try messing with meka.inp see if you can map them in the configuration file and they would work?

Yes, after editing meka.inp, it works fine! Thanks!

Btw, another thing I just realized, when I press fullscreen it stays in the same window size, without enlarging at the whole screen as previous version was doing...
Edit:
Pressing Alt+Enter goes fullscreen! If I find anything else I'll tell you...
  View user's profile Send private message
  • Joined: 15 Jun 2011
  • Posts: 4
Reply with quote
Post Posted: Fri Jun 17, 2011 3:26 pm
yep, editing Meka.inp did the trick! thanks.
  View user's profile Send private message
  • Joined: 14 May 2006
  • Posts: 27
Reply with quote
Post Posted: Sat Jun 18, 2011 5:20 pm
I tried to compile meka under Fedora15 but the UNIX version and its makefile are not in good shape.

The rule to build buildupd.exe is broken and do not specify CC, CFLAGS, ecc.

Makefile is full of references to seal even though it is no longer used.

There is no rule to generate m6502/m6502.c in the Makefile (AFAIK 6502 emulator has been stripped out).

Now g++ is mandatory to compile meka (and therefore compiling with gcc is useless and you'll get tons of errors).

TRUE and FALSE are not defined.

stricmp and strupr are not defined under UNIX.

I stopped here... and gave up.
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sun Jun 19, 2011 9:15 am
Thanks for the checking the UNIX version. You are correct that the Makefile is not up to date and need maintainance, seeing as the Windows version is not using it. I don't think there's lots of effort needed to fix it tho.

musuruan wrote
The rule to build buildupd.exe is broken and do not specify CC, CFLAGS, ecc.

buildupd.exe was made obsolete and doesn't exist anymore.

Quote
Makefile is full of references to seal even though it is no longer used.
There is no rule to generate m6502/m6502.c in the Makefile (AFAIK 6502 emulator has been stripped out).

Yes all of this has to go as well.

Quote
Now g++ is mandatory to compile meka (and therefore compiling with gcc is useless and you'll get tons of errors).

Yes this has to be changed as well. I kept .c extension at the moment to avoid renaming everything and I imagine it would be ok to call G++ instead.

Quote
TRUE and FALSE are not defined.

Fixed.

Quote
stricmp and strupr are not defined under UNIX.
I stopped here... and gave up.

I #defined stricmp to strcasecmp which seems to be the version under UNIX. strupr() has been used previously so I'm not sure where it comes from. It could easily be reimplemented.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sun Jun 19, 2011 9:22 am
In r258, r259 i removed references to SEAL, M6502 and buildupd.exe from the Makefile. I haven't tested anything beside checking that the Makefile parse properly.
  View user's profile Send private message Visit poster's website
  • Joined: 10 Jun 2006
  • Posts: 29
Reply with quote
Post Posted: Thu Jun 23, 2011 5:08 pm
I just tried the latest file you posted and replaced the other EXE file with it, but it's still got the same problem with the game controllers. I just had to set them using the Meka.inp file like I used to in the older days of Meka, so at least there is a way around it.

But is there a way to *disable* the reset button on the controller from the Meka.inp file? I've tried typing just a number zero and tried putting "key Backspace" in there to just make reset backspace, but no matter how I change it, it then won't load Meka at all because it says something was changed, and basically, the only way Meka will load is if I have *one of* the buttons on the controller set as a reset button, but I don't want to have it that way because I don't like having a reset button on the actual controller because it's too easy to accidentally hit it and cut the whole game off. I much prefer reset to be on the keyboard *only*.

One other problem I noticed is that if you have a game running and then you hold alt and push enter to get back out of full screen so that you can load a different game or whatever, the window doesn't show any of Meka's menu items at the top, so to get it to show those, you then have to push escape, but when you do that, it causes everything to slow down *tremendously*, like to a crawl, and the only thing I can do then and the only way I can get out of Meka is to click on the X in the upper right of the window. I can't even quit using Meka's quit option because everything in the program becomes horrendously slow. So basically, now I just remember that when switching from one game to another, you have to hold alt and push enter to get out of full screen to where you can see the X in the upper right of the window and then just click on that X to close Meka completely and then reload it and load the next game you want. So there's a way around this issue too for now, but of course I still wanted to let you know about it.

Other than these annoying controller issues and the problem when switching back from full screen, it does seem like you did a very good job in fixing the sound problems that have plagued the otherwise great Meka for years. I've had it running on a separate laptop the whole time I've been writing this with it playing Wonder Boy 3: The Dragon's Trap and I have Bock -- I'm talking about the game character, not the creator of Meka -- standing there in that tropical, Florida-like place and I've been listening to that tropical-sounding music the whole time in order to see if the sound would screw up at some point like it used to do after a while on the previous versions of Meka, and this whole time it's been sounding great and flawless, just like it used to on the actual Sega Master System. That's *excellent*! I've been waiting *years* for this! It looks like once these few little kinks with the controllers are worked out, and maybe some other minor things that I haven't noticed yet, Meka will be on its way to once again being the best Sega Master System and Game Gear emulator hands down.
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Thu Jun 23, 2011 5:58 pm
Zillion Knight wrote
I just tried the latest file you posted and replaced the other EXE file with it, but it's still got the same problem with the game controllers. I just had to set them using the Meka.inp file like I used to in the older days of Meka, so at least there is a way around it.

Sorry for that I will give it a check.

Quote
But is there a way to *disable* the reset button on the controller from the Meka.inp file?

Just delete the corresponding line, it seems to work here.

Quote
One other problem I noticed is that if you have a game running and then you hold alt and push enter to get back out of full screen so that you can load a different game or whatever, the window doesn't show any of Meka's menu items at the top, so to get it to show those, you then have to push escape, but when you do that, it causes everything to slow down *tremendously*, like to a crawl, and the only thing I can do then and the only way I can get out of Meka is to click on the X in the upper right of the window. I can't even quit using Meka's quit option because everything in the program becomes horrendously slow. So basically, now I just remember that when switching from one game to another, you have to hold alt and push enter to get out of full screen to where you can see the X in the upper right of the window and then just click on that X to close Meka completely and then reload it and load the next game you want. So there's a way around this issue too for now, but of course I still wanted to let you know about it.


You have to press ESCAPE to switch between "game" and "interface" mode.
ALT-ENTER switches between "windowed" and "fullscreen" modes.

Now the problem you're havnig seems to be that in a certain combination - interface+windowed - everything run slow, is that right?

Can you try editing mekaw.cfg and see if this happens with both 'directx' and 'opengl' video driver? directx should be the default and there might be a bug currently maybe related to your desktop depth, resolution, driver, etc. I will investigate and probably create a version to get more information from your setup.
Can you try closing the various applet in MEKA interface and see if one is responsible for slowing down everything?


Great to hear news about the sound! :)
There's still a problem to fix where it start lagging behind video something but it shouldn't be too difficult to fix.
  View user's profile Send private message Visit poster's website
  • Joined: 10 Jun 2006
  • Posts: 29
Reply with quote
Post Posted: Fri Jun 24, 2011 6:10 pm
Well, it starts out in interface and windowed, so it's when switching to full screen and then switching *back* again and then trying to bring up the interface while it's in windowed form. Actually, though, I just found out that once I hold alt and push enter the first time to go to full screen, I can then toggle between full screen and the GUI by pressing escape, so I can just push escape to change games. The problem occurs if I go from full screen to pushing alt and enter to get back out of full screen and *then* pushing escape, but now that I see this isn't necessary, it's almost pointless to even worry about trying to fix it, especially when there are other things that are more important to fix. For some reason, I thought that on this version I had to push alt and enter again before going back to the GUI. I don't know why I thought that. Sorry for the confusion this caused.

Oh, and you mentioned closing all the windows in Meka. Actually, I always have all of the extra windows closed when I play a game just in case one of them might slow things down at all. Speaking of which, this isn't a huge deal, but I was wondering, is there any way to close that sound-debug window at the bottom? I guess that's there 'cause this is a version to test the new sound code in, but I was just wondering if there's a way to close it like with the other windows. Like I said, though, it's not a big deal since I don't think it messes emulation up at all. I was just wondering.

Oh, and yes, I deleted the entire line pertaining to the reset button being on the controller, and it works like that now with no reset button on the controller. I thought that I had to leave that line intact but enter another value in there. I didn't know I could just take it out completely and have it still work.

Well, I haven't noticed any problems with the sound at all, but if there's still some kinks to work out, I would say that's the most important thing to perfect first. Like I said, that issue with it slowing down is very easily avoided, and even the problem with the controller setup not working right is pretty easy to get around and then you only have to set the controllers up once by editing Meka.inp and then you don't have to worry about it anymore, but sound problems are something you would keep running into while trying to play games and it's something you'd have to keep dealing with every time.

I am very excited to see Meka on its way to becoming perfect again, or at least about as close as emulators ever get to being totally perfect. There's a lot of games I haven't played in years and others that I never got to play because I never got to obtain the cartridges, but I didn't want to play these games on flawed emulation. Yes, I know, I'm picky when it comes to video games. And other SMS emulators had issues with compatibility or video issues. Meka was the only one that had superb compatibility and video and all-around excellent emulation. The only thing missing was the sound quality. With that perfected, it would be the last piece of the puzzle of the most basic essentials for a top-of-the-line emulator. So yes, I'm very glad that this is finally happening. :-)
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Fri Jun 24, 2011 11:06 pm
I would like to fix those video issues you have. This is important to me, because at the point where MEKA 0.80 can be released I'd like it to be good enough to attract people back. If this issue you're having is happening and giving a bad impression to even 10% people it isn't a good thing and I can't expect everybody will want to give MEKA another chance.

Can you have a look at changing video drivers in mekaw.cfg between opengl and directx to see if this makes any change with your bugs?

Design note: I have removed the possibility to have different resolution between interface and game modes. This may be temporary and could be back later, but the state of thing right now is that the resolution switch was taking too long and just giving a bad impression of the software. If there's one thing MEKA should be based on its age, it should be a smooth and reliable software. Boot up fast and doing the job. Obviously there's still other issues to fix and Allegro 5 frankly is making it slow, but enforcing same resolution between interface and game modes had the enormous benefit of making the switch instantaneous and pleasant.

I will make it possible to hide the sound debugging window. As you mentioned this is debug stuff for testing. I was literally in the middle of working on the code when I made those builds and didn't see them as proper releasable builds so didn't put too much attention to hiding that thing yet,
  View user's profile Send private message Visit poster's website
  • Joined: 10 Jun 2006
  • Posts: 29
Reply with quote
Post Posted: Sat Jun 25, 2011 10:23 pm
Bock wrote
I would like to fix those video issues you have. This is important to me, because at the point where MEKA 0.80 can be released I'd like it to be good enough to attract people back. If this issue you're having is happening and giving a bad impression to even 10% people it isn't a good thing and I can't expect everybody will want to give MEKA another chance.


Well, yeah, I see what you're saying, and if it's important to you, then it's important to me. It would be nice to see Meka listed at the *top* of online lists of "best SMS emulators" where it rightfully should be. Honestly, even this current beta version outperforms every other SMS emulator I've ever tried and it *seems* perfect to me so far, although I haven't had time yet to test it extensively. Like I said in the last post, it seems like all the other SMS emulators all have some big problem or another, be it compatibility or video display problems, and one even didn't have an option to make it full screen and the games had to be played in a window. Also, I've always loved how Meka starts the games with that thing that plays the tune of, "Se-ga!" while it shows the Sega logo. It just doesn't feel right to me when an SMS game starts up without that.

But anyway, I'll try to do what you were asking me to do in that last post. However, let me make it clear that I'm not super great at changing settings from within a document, as you could probably tell by how I had a hard time turning off the reset button on the controller. Back when Meka's controller setup had to be done by editing the file, it took me kind of a long time to painstakingly figure out what I was doing enough to finally manage to get the buttons set up the way I wanted them because I had never done anything like that before and I didn't know what was what. I'll try, though. I should probably be able to figure it out.

If I manage to successfully change the video modes to what you're asking, I'll try to repeat this bug and tell you what happens.
  View user's profile Send private message
  • Joined: 14 May 2006
  • Posts: 27
Reply with quote
Post Posted: Sun Jun 26, 2011 4:43 pm
Bock wrote
In r258, r259 i removed references to SEAL, M6502 and buildupd.exe from the Makefile. I haven't tested anything beside checking that the Makefile parse properly.


I have to switch again from gcc to g++ to compile. Otherwise I got a lot of these errors:
* unknown type name
* expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘<’ token
* initializer element is not constant
* ‘XXX’ undeclared (first use in this function)
* request for member ‘XXX’ in something not a structure or union
etc

With g++ I get a lot of warnings of these type:
* warning: deprecated conversion from string constant to ‘char*

And it fails here:
debugger.c: In function ‘void Debugger_Symbols_ListByName(char*)’:
debugger.c:1225:27: error: ‘strupr’ was not declared in this scope
debugger.c: In function ‘t_debugger_symbol* Debugger_Symbol_Add(u16, int, const char*)’:
debugger.c:1332:34: error: ‘strupr’ was not declared in this scope
debugger.c: In function ‘void Debugger_Applet_Redraw_State()’:
[...]

BTW is there a way to compile under x86_64? Is nasm still required?
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sun Jun 26, 2011 4:59 pm
musuruan wrote

I have to switch again from gcc to g++ to compile. Otherwise I got a lot of these errors:

Yes it requires a C++ compiler that is correct.

Quote
With g++ I get a lot of warnings of these type:
* warning: deprecated conversion from string constant to ‘char*

Can you paste a few example of them?
I assume string constants are 'const char*' and reside in non-writable text memory nowadays by default.

Quote
And it fails here:
debugger.c: In function ‘void Debugger_Symbols_ListByName(char*)’:
debugger.c:1225:27: error: ‘strupr’ was not declared in this scope
debugger.c: In function ‘t_debugger_symbol* Debugger_Symbol_Add(u16, int, const char*)’:
debugger.c:1332:34: error: ‘strupr’ was not declared in this scope
debugger.c: In function ‘void Debugger_Applet_Redraw_State()’:


I've committed a StrUpper() implementation and using that now.

Quote
BTW is there a way to compile under x86_64? Is nasm still required

NASM is still required but I hope to obsolete it shortly and switch to pure C. There's still from x86 code used.
  View user's profile Send private message Visit poster's website
  • Joined: 10 Jun 2006
  • Posts: 29
Reply with quote
Post Posted: Sun Jun 26, 2011 6:42 pm
Well, Bock, I just tried to do what you said, and it was actually *very* easy to figure out how to change it. I feel silly now for making it into such a big deal. And it was right at the top of the document too...

But anyway, when I change it to the Opengl video driver and then try to load Meka, it just comes up with a blank window, like Meka is on but it's just showing all black and it's totally inactive. Then I tried to click on the X to close the window, and the little X button was "pressing down" like it was working, unlike how when you don't even see the X button get pushed in when a window is totally not responding, and I did control, alt, delete and it said it was running, but I can't do anything with it and can't even close the window no matter how many times I click on the X. The only way I can close it at that point is by shutting it down with control, alt, delete. I tried this a couple of times and it did it every time. I changed the setting back to the DirectX one and tried loading Meka again, and then it loaded just fine and worked perfectly. I guess my computer's video card doesn't support the Opengl video driver at all.

If there's anything else you'd like me to try, just let me know. I'll do whatever I can to help. But ya know, I was thinking, this might be something that's happening only on my computer. Maybe some other people should try doing this same thing and see if this extreme slowdown happens to them. Scroll up in this thread if anyone wants to see again how this problem is occurring, since I explained it earlier.

In case it helps, I have a Dell Latitude D610 laptop with Microsoft Windows XP Professional Service Pack 2. And before anyone tells me I should upgrade, the reason I'm using this older laptop is because I want to have the screen be a 4:3 aspect ratio because these older games were designed before all this wide-screen crap and they're made to run on a 4:3 aspect ratio, which means that running them on a wide screen causes the images to be stretched horizontally, which, for example, causes a square block to become a rectangle block and so on, and plus it just looks crappy. Another reason is because I hate Windows Vista, and I'm not exactly thrilled about the idea of switching to Windows 7 because there's really no reason to. I'm not one of these computer people that's always gotta constantly change and update, change and update. I say if it ain't broke, don't fit it, and it ain't broke, so I want everything to stay the way it is unless there's some significant *benefit* to changing, and simply lining Bill Gate's pocket with more money doesn't count as a benefit to me.

But anyway, like I said, let me know if there's anything else I can do to help.
  View user's profile Send private message
  • Joined: 25 Dec 2005
  • Posts: 420
  • Location: São Paulo - Brazil
Reply with quote
Post Posted: Mon Jun 27, 2011 1:59 am
Deeyou wrote
yep, editing Meka.inp did the trick! thanks.


Hey, decided to work out this thing, and indeed this trick works for me too =)

(although it should be fixed on the interface).

Otherelse, I had to install subversion just to grab the source and configuration files. Perhaps it would be more test friendly to attach a complete zip file to this thread, not only the executable.

Otherwise, great work on sound! Not a single glitch here Bock =)

EDIT: How do one sets the save slots again ? ^^
EDIT2: Analog directions are working, but arrows are not, on a PS3 controller using DS3Tool.
  View user's profile Send private message
  • Joined: 25 Dec 2005
  • Posts: 420
  • Location: São Paulo - Brazil
Reply with quote
Post Posted: Mon Jun 27, 2011 2:45 am
Niloct wrote
EDIT: How do one sets the save slots again ? ^^


Quote
- Save states. You can load and save in-game, using F5 and F7 keys, with
up to a hundred slots for storing a game state (change with F6 and F8).
  View user's profile Send private message
  • Joined: 16 Mar 2005
  • Posts: 23
  • Location: Houston metro area, TX, USA
Reply with quote
Post Posted: Mon Jun 27, 2011 4:38 am
Okay, binding to the . key on the number pad doesn't work, it gives a "KeyInfo_FindByScancode(7b) failed" message
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Test build 2011-07-26
Post Posted: Tue Jul 26, 2011 8:53 am
Last edited by Bock on Tue Jul 26, 2011 2:37 pm; edited 1 time in total
I couldn't work on MEKA much last month but here's a build with minor changes.

- Fixed mapping of '.' key.
- You can close the SOUND DEBUG window.
- Fixed Up/Down keys not working in the debugger.
- Increased joystick dead-zone, can you guys check if it fixes your joystick mapping issue?
- Filebrowser: backspace is a shortcut to get to parent directory, and when getting to parent directory the last directory is automatically set as current selection.
- Minor other fixes i can't recall.
- Various sources fixes for GNU/Linux compilation (untested).

  View user's profile Send private message Visit poster's website
  • Joined: 27 Apr 2005
  • Posts: 402
  • Location: Australia
Reply with quote
Post Posted: Tue Jul 26, 2011 1:20 pm
Joystick mapping seems good now.

Memory Editor is a tiny box.
Help/About crashes.
  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Tue Jul 26, 2011 2:35 pm
Hmm something went wrong with my local config and thats what went into the ZIP file above. I have now fixed it, otherwise you can delete the .cfg file as well.

Also fixed the About box here but its not included in the ZIP yet, sorry and thanks for finding that.
  View user's profile Send private message Visit poster's website
  • Joined: 31 Aug 2006
  • Posts: 34
  • Location: United Kingdom, Glasgow
Reply with quote
Post Posted: Sat Aug 06, 2011 1:06 am


In Hang-On I've noticed that part of the track shows in the background where it shouldn't (shown in screen shot with a highlighted red square box), also in regards to the track itself when it turns left or right, the track kind of looks like it judders.

Other than that not noticed any other problems and nice work on the sound :), works fine with my Creative X-Fi Xtreme Gamer, also forgot to mention I'm using the latest 0.80 build.
see.png (2.32 KB)
Attachment fairy
see.png

  View user's profile Send private message
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 6513
  • Location: London, UK
Reply with quote
Post Posted: Sun Aug 21, 2011 6:08 pm
Meman87: it is the actual standalone Hang On ROM or the Hang On / Safari Hunt one?
Hang On / Safari Hunt behave differently and has those glitches in NTSC systems as far as I know. However having checked it now the glitches happens in MEKA evens in PAL emulation mode which is incorrect. In the meanwhile you can use the standalone Hang On version and it should be OK.
  View user's profile Send private message Visit poster's website
Reply to topic Goto page 1, 2, 3, 4, 5, 6  Next



Back to the top of this page

Back to SMS Power!