mirror of https://github.com/bsnes-emu/bsnes.git
Update to bsnes v027r09? release.
New WIP. No Windows binary. This one fixes the GTK+ fullscreen issue on Openbox completely. How do I know? Because I'm running Openbox now to verify :P It's pretty spiffy, whole thing is only consuming ~5mb of memory. Total mem usage sans the 'fox is ~40mb. The cool part with these changes is that video no longer flickers for one frame when you toggle the menubar in fullscreen mode anymore. Not even on XFCE. Just in case, verification always helps. Hopefully it'll work on all the esoteric window managers out there, so long as they honor the undecorate window request. You may have some small issues if not. I didn't need keepabove to get on top of my XFCE panel, even when I run the panel in Openbox. I'd like to keep it off if possible. void pWindow::fullscreen() { if(state.is_fullscreen == true) return; state.is_fullscreen = true; gtk_window_fullscreen(GTK_WINDOW(window)); gtk_window_set_decorated(GTK_WINDOW(window), false); gtk_widget_set_size_request(window, gdk_screen_width(), gdk_screen_height()); } void pWindow::unfullscreen() { if(state.is_fullscreen == false) return; state.is_fullscreen = false; gtk_widget_set_size_request(formcontainer, state.width, state.height); gtk_widget_set_size_request(window, -1, -1); gtk_window_set_decorated(GTK_WINDOW(window), true); gtk_window_unfullscreen(GTK_WINDOW(window)); } I also fixed the "esc" -> "escape" keysym for menu toggle, and updated the x86-64 target with OpenGL + SDL input stuff. Thanks everyone for the awesome feedback! > EDIT3: How come you haven't added the icon to the window? Need to > write another class for handling it (for MIU)? Adding the following > to the end of pWindow::create() in > 'src/lib/miu.gtk/miu.gtk.window.cpp': Yes, I need a way to do the same in Windows. Ideally, I need a way to embed the icon inside the EXE, and have an API that allows me to set the icon both on Windows and Linux from it. I'd prefer to not require another external file for bsnes binary releases. Thanks for the GTK+ code, though. It's a step in the right direction. > I tested the linux version of bsnes with my Radeon Mobility x1400, > and I don't get any video inside the bsnes window. I'm running > Ubuntu, and I've set up all the ATI driver stuff, AFAIK (Compiz, at > least, works). Aw ... well, thanks for trying. I kind of figured it wouldn't work. Perhaps ATI doesn't support GLX ... I honestly have no idea. I'll look into it. > What other package(s) do I need to install to correct these > warnings/errors? libsdl1.2-dev > My first problem when running this WIP is that my statusbar is > black. All black. No one else has complained, so this must just be > happening over here... any ideas why? Also, fullscreen won't work > for me... gameplay freezes for a moment when I toggle it and then > continues windowed, as normal. Sigh. I fixed this a while back. Certain GTK+ themes weren't painting the background of statusbars, so I embedded the statusbar inside an event box. I don't know why it still isn't working for you. It seems to work for everyone else now ... > Secondly, when attempting to map my gamepad, every single key logged > correctly... except my right directional. What? Weird. Good question. The SDL docs say axis 0 = x, axis 1 = y. but the two thumbs are axes 2, 3 left and 4,5 right. The left thumb uses 2 for X and 3 for Y, but the right uses 4 for Y and 5 for X. Since the API has no way to tell you what direction an axis is in, I decided to play it safe and do axis&1 over all axes. I guess I'll just hardcode for D-pad + two thumbs in the next version by swapping 4 and 5 ... no idea how other apps do it. > Finally, turning on Scale2x with or without opengl as video does > this to the Donkey Kong Country intro (note the statusbar)... Longstanding issue. Never modified the hq2x and scale2x filters to support hires modes. Only direct and NTSC do. Hoping to bypass the issue with pixel shaders in the future. That, or wait until I cleanup the video filter code and get it out of the core. > Does GtkSocket not do what you're looking for? > http://www.gtk.org/api/2.6/gtk/GtkSocket.html Nah, that's for other processes. I just need to convert an X11 handle back to a gtk_drawing_area GtkWidget. Sounds weird, but miu only has one handle() function for cross-platform reasons. So I make that export an X11 handle (that Xv and OGL take) rather than a GtkWidget handle (which requires gdkx.h header to extract the X11 handle from in a safe manner.) [No archive available]
This commit is contained in:
parent
4370acae2e
commit
a3f1802845