Forums

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

View topic - Meka issues

Reply to topic
Author Message
  • Joined: 03 Jul 2005
  • Posts: 45
  • Location: Toronto, Canada
Reply with quote
Meka issues
Post Posted: Sat Feb 04, 2017 4:51 pm
I am trying to start with SMS programming using Maxim's tutorial. Here is my journal.

Issue #1: I ran into an issue with last official Meka release from 2010: it won't launch due to missing MSVCR71.dll file. I'd like Bock to kindly include it in zip file with emulator please. If you google for it, it leads to those shady "download DLL" sites that I don't want to touch with a 10-foot pole. I ended up downloading .NET Framework 1.1 from Micorsoft, extracting the MSI, doing MSI admin install to extract files in CAB and then I got my non-shady copy of MSVCR71.dll. But some users may end up downloading dodgy injected version from "the interwebs".

Issue #2: After this I tried to build latest code in master branch in Bock's GitHub Meka repository. I think the solution and project files are for Visual Studio 8.0 from 2008. I now have Visual Studio 2015, which will update those project files, but they don't work. For some reasons custom build rules for asm files do not work as part of solution build, but work fine if you right-click on a source file and choose Compile... I am yet to figure this out, but I am curious if Bock would accept a switch to CMake to generate solution/project files for any version of Visual Studio? If you are, I volunteer to do it :)

Issue #3: Meka starts slow even on a very modern high-end 6-core Xeon based Windows 10 x64 PC. And to add insult to the injury, there is a right-to-left menu animation that takes a couple of seconds on each run. For some reasons it makes me really stressed when I run through change/assemble/run in meka loop. Is it possible to request that an option to disable menu animation is made available in configuration file? Again, if the idea is acceptable, I volunteer to work on it.

Otherwise thank you very much to Bock, Maxim and Ville Helin for Meka, tutorial and assembler! You made it much easier to get into SMS development.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14983
  • Location: London
Reply with quote
Post Posted: Sat Feb 04, 2017 11:19 pm
msvcr71 is part of the Visual Studio C++ runtime, usually it is already present. It seems it should be bundled, else the .net 1.1 framework installs it - do newer versions not include it?

If you want to compile with VS2015, you can try my fork: https://github.com/maxim-zhao/meka/tree/vs2015 which has a few other things mixed in (e.g. Allegro from NuGet, some CPU timing tweaks) but is a little behind too. It's tricky to support multiple target versions of VS at the same time without resorting to something awful like CMAKE.

The slowness is probably due to frame rate issues - are you running it windowed or fullscreen? Does it lag when in-game? I think I had issues in the past if the window was not safely on a single screen, causing it to fail to accelerate anything.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 8708
  • Location: Paris, France
Reply with quote
Post Posted: Sun Feb 05, 2017 11:08 am
Or get 0.80 branch binaries from the forum thread:
http://www.smspower.org/forums/13019-Meka080WithNewSoundEngineTESTERSWANTED?star...
  View user's profile Send private message Visit poster's website
  • Joined: 03 Jul 2005
  • Posts: 45
  • Location: Toronto, Canada
Reply with quote
Post Posted: Sun Feb 05, 2017 6:03 pm
Thank you for your answers, Maxim and Bock. I noticed I used the wrong sub-forum, this thread should be under Projects -> Meka. Please move it if you can.

Maxim:

MSVCR71.dll is very old, it's from Visual C++ 7.1 in Visual Studio .NET 2003. Visual Studio 2005 and up don't come with it.

Interestingly enough, Microsoft provides standalone Microsoft Visual C++ redistributable packages for MSVCR80.dll from VS2005, MSVCR90.dll from VS2008, MSVCR100.dll from VS2010,
MSVCR110.dll from VS2012, MSVCR120.dll from VS2013 and refactored DesktopCRT runtime from VS2015. So using VC++ 6.0 would guaranty run-time is available on any Windows 2000-10, and using VC++ 8.0 (2005) or up would make run-time dependency much easier, because once you install Microsoft official redistributable, it's patched by Windows Update. And only MSVCRT70.dll and MSVCRT71.dll fall through cracks of being too old to have supported redistributable for Windows 10, but not old enough to be included in base OS, like MSVCRT.dll from VC++ 6.0.

I still think it would be great if it can be added to mekaw073.zip, so people won't need to search for it.

Maxim, basic program slowness is ok, I can deal with it, but menu right-to-left animation is very irritating. It looks good the first time you launch Meka, but adds artificial 2 seconds delay on each consecutive launch. Since Meka is primarily for development, it's unfortunate. I'll check your fork and Bock's most recent 0.80 build to see if this is still the case. If menu animation is still in, I am kindly requesting to add configuration file setting that would allow to turn it off.

About Allegro from NuGet, do you mean Chocolatey?
Update: nevermind, I think you mean this: https://www.nuget.org/packages/Allegro/

About CMake, please let me know why you think it's horrible? It is used by WLA-DX, and it makes it a breeze to build it with almost any compiler out there.

Maxim, why do you have your own fork? Do you contribute your changes back to Bock's main repository?

How soon will you move off Allegro and to something like Qt or any other modern windowed GUI framework?

Thank you for your help!

Update: nevermind, I just downloaded meka-2015-05-06-win32-proto.zip from Bock's thread, and it starts faster and doesn't have menu animation like 0.73 had.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14983
  • Location: London
Reply with quote
Post Posted: Sun Feb 05, 2017 7:38 pm
Github requires you to fork everything to do anything, especially to contribute back. I'd not considered that you might be using the non latest version, it's super out of date - but you did call that out.

CMake generates Visual Studio projects that are very ugly and I don't think it plays nicely with NuGet dependencies. Maybe it's the way to go for Meka's cross platform aspirations anyway.

Allegro is quite ingrained and relied on for a bunch of stuff, more than just blitting to the screen. Extracting it won't be trivial.
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 08 Jul 2001
  • Posts: 8708
  • Location: Paris, France
Reply with quote
Post Posted: Sun Feb 05, 2017 10:41 pm
I'll move MEKA to use my 'dear imgui' library someday and that'll remove most of the big dependencies on Allegro, will delete lots of old crappy GUI code and will make further development of tools/debugger easier. If we replace the GUI stuff which has a lot of rendering then it's easy to remove Allegro.

(I started a test branch for that a few months ago but only spent a few hours on it so far.)
  View user's profile Send private message Visit poster's website
  • Joined: 12 Jan 2005
  • Posts: 187
  • Location: Reconquista, Santa Fe, Argentina
Reply with quote
Post Posted: Thu Jun 01, 2017 4:55 pm
Bock wrote
Or get 0.80 branch binaries from the forum thread:
http://www.smspower.org/forums/13019-Meka080WithNewSoundEngineTESTERSWANTED?star...


The latest version from that thread gives me inconsistent sound speed with a lot of messages like "PushSamplesRequestBufs(): overflow [some value] : [some other value]
Streets of Rage (U) [!]-01.png (69.33 KB)
Sound errors
Streets of Rage (U) [!]-01.png

  View user's profile Send private message
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14983
  • Location: London
Reply with quote
Post Posted: Thu Jun 01, 2017 10:45 pm
Check your emulated speed (Hz) matches the TV type setting.
  View user's profile Send private message Visit poster's website
Reply to topic



Back to the top of this page

Back to SMS Power!