-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mouse bug... #454
Comments
Thanks! I did not fully understand how MAME handles relative devices, I will update next time we do a release. |
My MAME OSD, assumes the client will do all the rendering (on iOS we use Metal) Did you do that on Android, or did you put back the option to render to a bitmap? |
Yeah. I know you do all the rendering on the client. At the moment I make a bitmap although later in the client I apply shaders and I support a lot of glsl shaders. In any case this approach has clear disadvantages with artwork of course. I want to try to get bgfx running at some point, which would be better than reinventing the wheel but so far renderer has been fast developed and works fast and well. I also wanted to respect MAME UI unlike you on iOS because on Android there are already great third-party frontends with which I integrate. I have tried to enhance the MAME UI with media scraping and including resources such as history data and mame info which authors has given permission to me. Also I made it touch enabled, so by default you have an experience very similar to the PC experience, which I like. Ahhh. One important thing mame Devs have fixed discrete sound bug in a recent commit. Al least works fine on my arm64 build without numprocessors setted to one. That is important because improves performance in threaded rendering like the one on namco system 22 which run full speed on my device. It is curious but my port has not any issue with sound. I have seen you have been struggling with sound issues on iOS devices. In fact, I'm running in a low latency path mode so buffering is setted to 2/3 frames and there is not any underun. |
YES audio bug fixed! I have bang'd my head trying to work around that. Setting num-cpu to one killed me! Thanks |
Yea hires artwork looks great when you handle the render, and vector games can draw nice hires lines |
FYI I did an update to my MAME fork to MAME 264.... I am looking at the mouse issue now, and have a question... Wouldn't relative-reset make more sense like this....
|
I have never gotten the MAME "DOS" UX to use the mouse, maybe this change will fix it!! Also the relative-reset flag was added relatively recently, thanks for letting me know about it! |
Empirically, it is working correctly for me. If you look at https://github.com/mamedev/mame/blob/master/src/osd/modules/input/input_rawinput.cpp at the poll interval, if the relative_reset is set, then they exchange the mouse data an set it to zero the member one `
` |
Making the mouse to work correctly is more important than it seems because there are artworks that are clickable.. :) For the mouse to work in the UI and in the artwork, mouse events must be injected directly. It doesn't work like it does with games. look at here: https://github.com/seleuco/MAME4droid-2024/blob/main/src/osd/myosd/myosdmain.cpp `
} and here: https://github.com/seleuco/MAME4droid-2024/blob/main/src/osd/myosd/myosd-droid.cpp `
} Also keyboard has to be inyected .... Anyway i think that @cuavas has changed a lot of this in a recent commit because it has added some type of touch support. I will dig on it when they launch 0.265 |
@ToddLa
Hi todd.
I have been updating the Android MAME port so that it works with the latest pc desktop version version
https://github.com/seleuco/MAME4droid-2024/tree/main
I started the development using your OSD modifications (libmame 250)since you have done a magnificent job and it has sense to start with.
When I implemented the mouse support I went crazy because you have a bug that makes the mouse seem to work but it is not really working it well.
Specifically, when mame invokes void ios_osd_interface::input_update(bool relative_reset) the relative_reset parameter indicates that this is when the relative data (the mouse) must be polled, therefore it must be passed to do the effective polling:
m_callbacks.input_poll(relative_reset,&g_input, sizeof(g_input));
....
I hope this helps if you still maintain the iOS port, which is great :)
The text was updated successfully, but these errors were encountered: