View unanswered posts | View active topics It is currently Sat Dec 07, 2019 12:32 am



This topic is locked, you cannot edit posts or make further replies.  [ 234 posts ]  Go to page 1, 2, 3, 4, 5 ... 10  Next
bsnes v0.037a released 
Author Message
Post bsnes v0.037a released
byuu.org wrote:
2008-10-26 - bsnes v0.037 released

This release adds support for the SNES mouse, Super Scope and Justifier peripherals. It also simplifies cartridge loading and refines the user interface. Lastly, GZ and ZIP archives can now contain non-ANSI characters (Chinese, Japanese, Russian, ...) This support existed in the last release for all uncompressed files. Together, this means only JMA support on Windows lacks support for loading non-ANSI filenames. This is due to the library itself (really, it's more Windows' fault), and licensing issues prevent me from patching libjma as I did with zlib (bsnes is not GPL compatible.) I'm planning to work with Nach to fix this in a future release.

About the cartridge loading changes ... the emulator now determines what kind of cartridge is being loaded (eg normal, BS-X BIOS, Sufami Turbo cart, etc) by looking inside the file itself. If it detects a cart type that requires more than one ROM image to load, it will present you with the appropriate specialized load menu automatically. Aside from being more intuitive, this method also allows loading of BS-X and Sufami Turbo games from the command-line or via file association.

Changelog:
* added mouse support to DirectInput and SDL input drivers
* up to 96 buttons per controller; 8 buttons per mouse (5 per mouse on Linux) can be mapped now
* added SNES mouse support (does not support speed setting yet)
* added Super Scope support
* added Justifier support (supports both Justifiers)
* input management system almost completely rewritten to support new controllers
* "Load Special" menu removed, all cart loading merged to "Load Cartridge ..." option
* replaced "Power Cycle" and "Unload Cartridge" with "Power" -> "On" / "Off"
* when video exceeds screen size and is scaled down, aspect ratio is now maintained [Ver Greeneyes]
* zlib modified to support non-ANSI characters
* cheat code count was limited to 1,024 codes before; it now supports unlimited codes per game
* added sort by description setting for cheat code list
* polished listbox control interaction (disable buttons when nothing selected, etc)
* cleaned up OBC-1 chip emulation (code is functionally identical to v036)
* added option to toggle fullscreen mode to settings menu
* added advanced mode options to toggle base unit (none, Satellaview) and system region (Auto-detect, NTSC, PAL)


Last edited by byuu on Mon Oct 27, 2008 5:32 am, edited 1 time in total.



Sun Oct 26, 2008 10:44 am
Regular
User avatar

Joined: Thu Jul 29, 2004 8:55 am
Posts: 265
Location: The Netherlands
Post 
A very solid release :)
Any localization file available yet?

Edit: it seems I missed it on your homepage. Got it now.

_________________
"Change is inevitable; progress is optional"


Sun Oct 26, 2008 10:48 am
Profile
Post 
Great! Now I can play Shin Megami Tensei on a new version of bsnes :)


Sun Oct 26, 2008 2:09 pm
NO VOWELS >:[
User avatar

Joined: Sun Aug 31, 2008 12:59 pm
Posts: 753
Location: ALABAMA
Post 
GOTTA PATCH ALL OVER AGAIN, but it's so worth itttt ty byuu <3


Sun Oct 26, 2008 2:44 pm
Profile YIM WWW
Regular
User avatar

Joined: Tue Mar 07, 2006 10:32 am
Posts: 347
Location: The Netherlands
Post 
Franky wrote:
Great! Now I can play Shin Megami Tensei on a new version of bsnes :)

XD That's the feeling I always get too. Even if nothing relevant changed, it still feels nice and shiny!

Anyway, congrats on the release byuu, glad to see my code made it in, even if it wasn't the combined version ;) Now that you got the peripherals in, that should be a big relief! (does this give us any new games to test for core emulation bugs?)

gllt wrote:
GOTTA PATCH ALL OVER AGAIN, but it's so worth itttt ty byuu <3

You could also rename the dll file to d3d9.dll instead of using the patcher, but I doubt you mind that much :D


Sun Oct 26, 2008 2:47 pm
Profile
NO VOWELS >:[
User avatar

Joined: Sun Aug 31, 2008 12:59 pm
Posts: 753
Location: ALABAMA
Post 
Verdauga Greeneyes wrote:
You could also rename the dll file to d3d9.dll instead of using the patcher, but I doubt you mind that much :D


Hurr actually I try to keep everything clean in my life now so it's something I do in the dark of the night to avoid offending anyone :V


Sun Oct 26, 2008 2:49 pm
Profile YIM WWW
Regular
User avatar

Joined: Thu Jul 29, 2004 8:55 am
Posts: 265
Location: The Netherlands
Post 
Dutch translation for v0.037

Verdauga, maybe you could take a look at it as well. Some stuff in there was a bit difficult to translate accurately.

_________________
"Change is inevitable; progress is optional"


Sun Oct 26, 2008 3:50 pm
Profile
Regular
User avatar

Joined: Tue Mar 07, 2006 10:32 am
Posts: 347
Location: The Netherlands
Post 
I noticed something odd while playing with a filter: in point scaling mode, I set the scale to 4x, disabling aspect ratio correction, and I noticed that it is 3 pixels too big! That is, there are 3 rows and columns with a height/width of 5 pixels, and the bottom and rightmost 3 pixels are cut off. Tested on Windows with Direct3D, I'll see if I can test more cases later but I'd like to work on my filter a bit more. Can anyone confirm?

My filter, which scales to 4x manually, doesn't have this problem.


Sun Oct 26, 2008 5:49 pm
Profile
Rookie
User avatar

Joined: Mon Aug 02, 2004 5:14 am
Posts: 39
Post 
http://www.kuro-hitsuji.net/~tukuyomi/s ... french.zip
Here is the French locale for v0.037. Congrats byuu and all involved, as always :)
While testing my locale, I noticed something strange in the Cheat Code panel: Buttons labeled "Toggle Status" and "Delete Code" are not cllickable if you click twice (disable and reenable) on "Keep cheat code list sorted by description". It happens only with one cheatcode in the list. Screenshot ahead: http://www.kuro-hitsuji.net/~tukuyomi/s ... atcode.png


Sun Oct 26, 2008 7:28 pm
Profile WWW
Post 
Quote:
While testing my locale, I noticed something strange in the Cheat Code panel: Buttons labeled "Toggle Status" and "Delete Code" are not cllickable if you click twice (disable and re-enable) on "Keep cheat code list sorted by description". It happens only with one cheatcode in the list.


Yeah, I noticed that too. It's a Linux only issue. It doesn't lose its position 0 setting when resetting the list, ala Windows. It also happens with input when you switch controller subtypes. GTK+ also doesn't support clicking in blank sections of listboxes to unselect all options. The former I should be able to fix, the latter I can't. I'll probably just have to leave it as a platform difference.

Thanks for pointing this out -- I didn't realize it could get stuck with only one code, which is why I put it off for this release :/


Sun Oct 26, 2008 7:59 pm
Seen it all
User avatar

Joined: Mon Jan 03, 2005 5:04 pm
Posts: 2302
Location: Germany
Post 
german_locale_v037.rar

I'm open for corrections. :)

_________________
vSNES | Delphi 10 BPLs
bsnes launcher with recent files list


Sun Oct 26, 2008 9:38 pm
Profile WWW
Post 
I've posted v037a. It fixes the Linux listbox box reported by tukuyomi, and adds a few missing strings to the template locale.cfg file.

No need to re-do the locales. I should be able to update them all on my side and get them posted here shortly.

EDIT: posted all v037a locales. Thank you all so much for making these!

Quote:
I noticed something odd while playing with a filter: in point scaling mode, I set the scale to 4x, disabling aspect ratio correction, and I noticed that it is 3 pixels too big! That is, there are 3 rows and columns with a height/width of 5 pixels, and the bottom and rightmost 3 pixels are cut off. Tested on Windows with Direct3D, I'll see if I can test more cases later but I'd like to work on my filter a bit more. Can anyone confirm?


Probably a driver issue. Those are ridiculously common with Direct3D.

This is what I get with 4x, no ARC, point filtering:
http://img249.imageshack.us/img249/3505/11600203gv1.png


Mon Oct 27, 2008 5:32 am
NO VOWELS >:[
User avatar

Joined: Sun Aug 31, 2008 12:59 pm
Posts: 753
Location: ALABAMA
Post 
byuu wrote:
This is what I get with 4x, no ARC, point filtering:
http://img249.imageshack.us/img249/3505/11600203gv1.png


This is real.
I can tell by the pixels.


Mon Oct 27, 2008 8:34 am
Profile YIM WWW
Regular
User avatar

Joined: Tue Mar 07, 2006 10:32 am
Posts: 347
Location: The Netherlands
Post 
byuu wrote:
This is what I get with 4x, no ARC, point filtering:
http://img249.imageshack.us/img249/3505/11600203gv1.png

Strange shifting issue in the upper right and lower left corners there. Okay, I thought it might be a driver issue; I'll see if I can use OpenGL instead for the sake of my sanity.


Mon Oct 27, 2008 1:03 pm
Profile
Rookie

Joined: Sat Aug 07, 2004 7:20 pm
Posts: 46
Post 
I get quite a few warnings while compiling on Ubuntu 8.10, you might want to check it out. (g++ version 4.3.2)

[edit]And, strange, now bsnes won't work at all, locking up big time directly after loading a ROM...[/edit]


Mon Oct 27, 2008 1:31 pm
Profile
Lurker
User avatar

Joined: Fri May 11, 2007 5:28 am
Posts: 139
Post 
wertigon wrote:
I get quite a few warnings while compiling on Ubuntu 8.10, you might want to check it out. (g++ version 4.3.2)

[edit]And, strange, now bsnes won't work at all, locking up big time directly after loading a ROM...[/edit]


Personally I think g++ 4.3.2 is fucked up on ubuntu intrepid, seeing as it won't compile ZSNES right. I was able to compile bsnes 0.037 and zsnes 1.51b using 4.3.2 on debian lenny with no problems, although I haven't compiled 0.037a yet.


Last edited by dfreer on Mon Oct 27, 2008 7:04 pm, edited 1 time in total.



Mon Oct 27, 2008 5:46 pm
Profile
New Member

Joined: Sun Jun 03, 2007 2:01 pm
Posts: 6
Location: Sweden
Post 
I noticed something funny now since I've changed hardware and still don't have any graphics acceleration (using X.org VESA driver). My config file tells bsnes to use "OpenGL", which makes bsnes crash because I don't have any GLX extention atm (running a half broken setup atm):
Code:
$ bsnes
Xlib:  extension "GLX" missing on display ":0.0".
Segmentation fault


So I just edited ~/.bsnes/bsnes.cfg and set system.video = "" and started bsnes again. This is the screen I was greeted with:
Image

Just selecting something and closing the window will still save the values to the configuration file so it works. But it sure would be nice to see the buttons.

The funny thing is that I can reproduce it 100%.
1) Edit config and set system.video = "OpenGL".
2) Start bsnes and let it segfault.
3) Edit config and set system.video = "".
4) Start bsnes.
5) Repeat from step 1.

Steps 3&4 can be combined by setting video to OpenGL in the config screen that pops up.

byuu, if you want me to run any debugs or so, please send me a PM so I get a mail notice or it's likely that I'll forget about it (work keeps me busy).

_________________
Arch Linux bsnes package


Mon Oct 27, 2008 6:15 pm
Profile
Post 
Quote:
I get quite a few warnings while compiling on Ubuntu 8.10, you might want to check it out. (g++ version 4.3.2)

[edit]And, strange, now bsnes won't work at all, locking up big time directly after loading a ROM...[/edit]


I'll take a look at them, sure. If it's more int<>double crap, I probably won't rush to "fix" them (as they're not bugs in the first place. I'm well aware that the decimal place information is lost.)

I don't know why the emulator locks up on you. Try a backtrace or something, perhaps?

Quote:
So I just edited ~/.bsnes/bsnes.cfg and set system.video = "" and started bsnes again. This is the screen I was greeted with:


Yes, that's the crash handler. If the emulator crashes during startup, then it will revert your drivers to "None" the next time you start the emulator. The point is to allow recovery without having to find and edit the config file by hand. If you really want to edit the config by hand, you can change the "crash event handler" or whatever setting back to false and you won't get the handler on startup.

Ideally, we catch the crash before-hand; but some of these APIs say the last operation was a success, and the next one throws a BadMatch error and takes down your whole app, instead of returning a fail code.

Quote:
But it sure would be nice to see the buttons.


To see what buttons? The video / audio / input drop-downs are visible in your screenshot.

Quote:
Steps 3&4 can be combined by setting video to OpenGL in the config screen that pops up.


... that's what it's supposed to do :/
What were you wanting to have happen?


Mon Oct 27, 2008 6:49 pm
Lurker

Joined: Mon Mar 10, 2008 11:36 pm
Posts: 199
Post 
So mouse still not working? I can't get it to do anything. Mouse is set up.

EDIT: Never mind. I put it on super scope and now working. :roll:

_________________
Window Vista Home Premium 32-bit / Intel Core 2 Quad Q6600 2.40Ghz / 3.00 GB RAM / Nvidia GeForce 8500 GT


Mon Oct 27, 2008 7:36 pm
Profile
Rookie

Joined: Sat Aug 07, 2004 7:20 pm
Posts: 46
Post 
Did some more checking - it appears it is the ALSA driver that is the culprit. Switching to OpenAL works, but produces a ~200ms lag. >_<


Last edited by wertigon on Mon Oct 27, 2008 8:07 pm, edited 1 time in total.



Mon Oct 27, 2008 8:01 pm
Profile
Post 
Mouse needs to be on port 1 for Mario Paint. You also have to click inside the window. There's no visible cursor drawn by the emulator -- the games are supposed to draw the mouse cursor themselves.

Quote:
Did some more checking - it appears it is the ALSA driver that is the culprit. Switching to OpenAL works.


Weird ... if it happens to more people, I'll have to default to OpenAL again.


Mon Oct 27, 2008 8:02 pm
Post 
wertigon wrote:
Did some more checking - it appears it is the ALSA driver that is the culprit. Switching to OpenAL works, but produces a ~200ms lag. >_<

If you want the best audio on the linux version of bsnes, then use OSS4 instead of ALSA, and set bsnes's audio driver to OSS.


Last edited by ZH/Franky on Tue Oct 28, 2008 11:15 am, edited 1 time in total.



Mon Oct 27, 2008 10:41 pm
Rookie

Joined: Sat Aug 07, 2004 7:20 pm
Posts: 46
Post 
I would use OSS4 if it wasn't for the fact that many projects doesn't even consider OSS4 support, instead preferring to go with things like PulseAudio... Like swfdec. And most GBA emulators I've found. -_-


Mon Oct 27, 2008 11:52 pm
Profile
Post 
Hmm, rewriting the CPU / SMP register classes again.

Old:

Code:
template<int mask>
struct CPUFlag {
  uint8 &data;

  inline operator bool() const { return data & mask; }
  inline CPUFlag& operator=(bool i) { data = (data & ~mask) | (-i & mask); return *this; }

  CPUFlag(uint8 &data_) : data(data_) {}
};

class CPURegFlags {

public:
  uint8 data;
  CPUFlag<0x80> n;
  CPUFlag<0x40> v;
  CPUFlag<0x20> m;
  CPUFlag<0x10> x;
  CPUFlag<0x08> d;
  CPUFlag<0x04> i;
  CPUFlag<0x02> z;
  CPUFlag<0x01> c;

  inline operator unsigned() const { return data; }
  inline unsigned operator  = (unsigned i) { data  = i; return data; }
  inline unsigned operator |= (unsigned i) { data |= i; return data; }
  inline unsigned operator ^= (unsigned i) { data ^= i; return data; }
  inline unsigned operator &= (unsigned i) { data &= i; return data; }

  CPURegFlags() : data(0), n(data), v(data), m(data), x(data), d(data), i(data), z(data), c(data) {}
};


New:

Code:
class CPURegFlags {
public:
  bool n, v, m, x, d, i, z, c;

  inline operator unsigned() const {
    return (n << 7) + (v << 6) + (m << 5) + (x << 4)
         + (d << 3) + (i << 2) + (z << 1) + (c << 0);
  }

  inline unsigned operator=(unsigned data) {
    n = data & 0x80; v = data & 0x40; m = data & 0x20; x = data & 0x10;
    d = data & 0x08; i = data & 0x04; z = data & 0x02; c = data & 0x01;
    return data;
  }

  inline unsigned operator|=(unsigned data) { return operator=(operator unsigned() | data); }
  inline unsigned operator^=(unsigned data) { return operator=(operator unsigned() ^ data); }
  inline unsigned operator&=(unsigned data) { return operator=(operator unsigned() & data); }

  CPURegFlags() : n(0), v(0), m(0), x(0), d(0), i(0), z(0), c(0) {}
};


Faster access to individual flags, slower access to P as a whole. Seems to balance evenly, no speed gain or loss. But the code is simpler, and you can take individual flags as boolean, rather than CPUFlag<int>. And it avoids endianness entirely.

Now to merge this into the main CPU class, and drop all the CPURegBlaBla global stuff.

Quote:
I would use OSS4 if it wasn't for the fact that many projects doesn't even consider OSS4 support, instead preferring to go with things like PulseAudio... Like swfdec. And most GBA emulators I've found. -_-


You up for writing bsnes Linux audio driver # 5? ;)


Tue Oct 28, 2008 8:05 am
Rookie

Joined: Sat Aug 07, 2004 7:20 pm
Posts: 46
Post 
byuu wrote:
Quote:
I would use OSS4 if it wasn't for the fact that many projects doesn't even consider OSS4 support, instead preferring to go with things like PulseAudio... Like swfdec. And most GBA emulators I've found. -_-


You up for writing bsnes Linux audio driver # 5? ;)


It would give me an excuse to learn PulseAudio, but... Not right now. Too busy with other things. :)

Anyhow, did an LTrace, and it's definitely ALSA. Here's the relevant info:

Code:
strlen("Loaded TALES_OF_PHANTASIA.")                                                                            = 26
strcpy(0x1c04ff0, "Loaded TALES_OF_PHANTASIA.")                                                                 = 0x1c04ff0
time(NULL)                                                                                                      = 1225190533
strcmp("Loaded TALES_OF_PHANTASIA.", "Loaded TALES_OF_PHANTASIA.")                                              = 0
free(0x1c04ff0)                                                                                                 = <void>
XQueryKeymap(0x16a7890, 0x7fff91dd6030, 0x13d7e90, 0, 0x1c04ff0)                                                = 1
XQueryPointer(0x16a7890, 0x4400004, 0x7fff91dd6010, 0x7fff91dd6008, 0x7fff91dd602c)                             = 1
SDL_JoystickUpdate(1, 0, 0, 1033, 0x16a82e8)                                                                    = 0x16a01d0
gtk_window_get_type(0x856020, 0, 2, 1033, 0x16a82e8)                                                            = 0x13e5ec0
g_type_check_instance_cast(0x145bc50, 0x13e5ec0, 2, 1033, 0x16a82e8)                                            = 0x145bc50
gtk_window_is_active(0x145bc50, 0x13e5ec0, 0x13e5ec0, 918022, 0x16a82e8)                                        = 0
gtk_window_get_type(0x852c40, 0x13e5ec0, 0x13def90, 918022, 0x16a82e8)                                          = 0x13e5ec0
g_type_check_instance_cast(0x13ed020, 0x13e5ec0, 0x13def90, 918022, 0x16a82e8)                                  = 0x13ed020
gtk_window_is_active(0x13ed020, 0x13e5ec0, 0x13e5ec0, 918022, 0x16a82e8)                                        = 1
snd_pcm_writei(0x16a4a20, 0x16a76a0, 120, 0, 0


Why that is so, I do not know, but I suspect the ALSA driver not being compliant with PulseAudio, leading to the lockups. Digging around a bit, it seems like there's a "safe subset" of ALSA one *could* use, but digging around doesn't reveal anything of use.

PulseAudio in 8.10 isn't half bad btw, finally starting to understand why people find it to be a good thing - though it introduces massive lag in games. :(

[edit]Found it: http://0pointer.de/blog scroll down a bit[/edit]


Tue Oct 28, 2008 11:57 am
Profile
Display posts from previous:  Sort by  
This topic is locked, you cannot edit posts or make further replies.   [ 234 posts ]  Go to page 1, 2, 3, 4, 5 ... 10  Next

Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software.