Closed ulao closed 10 years ago
i don'f find the function to flash the screen to see the white square in zapper mode ?, any help would be very appreciate :)
Do you guys have a public repo with the changes you've made? That would help me understand what your issues are.
As you may know, this repo is under heavy development right now and none of the interface code should be considered "stable" until I tag the next release. Are you guys working with interface code, or directly with the core?
if you want i can send you the link with all the source, yes i've modified the core, NstApiInput and NstInpZapper for example
i've just added another method to use zapper, so i've added Zapper to add 2 buttons one for trigger one for light on (which means that the gun detect a white square)
it woul be great if you want to add this on nestopia, so nestopia would be the first emulator which can use the original zapper, just need a CRT to use the zapper of course :)
in fact i found how use these 2 new buttons, but I don't find the function which flash the screen to see the white squares for ducks (i try with duck hunt) i hope i'm clear :)
I can make an svn if you want. Can we branch a version maybe?
Ok, i've just succeeded to flash the screen to see the white squares in zapper mode, just need to try some little things and I will show you the source code I modified
here is the code source for the zapper support, we need more tests cause the timing need to be very accurate, probably need to double frame for black screen frame and for white square frame. if you can help us, if you see how double or triple frame (it's possible ?), it's been very nice
the bin file : http://www.video-games-museum.com/public/temp/nestopia_1.45-blissboxmode-win32.zip the src file : http://www.video-games-museum.com/public/temp/nestopia-1.45-src.zip
for some clarification and what I know, the gun looks for a black screen ( 16.666 ms later ( one frame at 60hz ) ) it looks for a white square and has 16.666ms to see it. Now today's hardware is not as precise. FPS is not what it once was. Also I'm not sure the emulator syncs to refresh-rates? So frames are of no importance, only time is important ( why does that remind me of 5th element?). Anyways, black for 16.666 white square for 16.666. If the emulator can calculate time like most game engines then it will figure out the frames to display. This depends on the speed of the computer and other such things. Though I think most emulators sync to audio or video. In that case its going to be near impossible.
If we are able to figure out time in the emulator we could get better resolution by going to 75hz. If the game can not calculate the right time I dont think this will ever work right. Timing is everything with that gun. I'm not sure what DX has to offer for timing really.
Sorry for all the info and bother, I'm sure your busy with more pressing things... Nestopia seems well written but like so many projects little direct in code in the way of comments, so we turn to you for help. Any ifo you can offer is greatly appreciated.
Since you guys are using the win32 port I can't really explain how timing works. I sync to sound in the Linux/Unix port when using libao audio, and sync to video when using SDL audio in combination with vsync... without vsync it syncs to audio. Yeah, it's crazy, but dealing with timing in emulators is always crazy. I literally spent 2 months trying to wrap my head around timing in emulators and probably still don't fully understand it.
Also, just so you guys know, I separated the win32 code from the main repo for licensing reasons. If you clone this repo, and place the overlay on top you'll have the latest revision for win32. The repo is at: https://github.com/rdanbrook/nestopia-win32
Thanks for posting the source, I will look through it as soon as I have some time.
I dont think win32 is all that important, I gather using the 64 port is better in many ways? We coudl try that. As for timing you answered my question so we must rely on video sync. Know of any apps that can time the frames? Or some code that would count from draw to draw and give us the ms trip cost?
is the 64 build only for linux at the moment?
The Linux/Unix port is being converted into a universal cross-platform port right now. It compiles on Windows with MinGW and SDL, and is purely command-line based. On Linux you also get a GUI which is under heavy development and contains segfaults (which will all be gone by the release). But it does work on Windows, for the most part.
The win32 port is too old to maintain. It would require quite a bit of work to bring it up to speed, so I gave up on it and decided to focus on a cross-platform port.
hey that sounds good, a command line is fine for what we need of it. When are we talking here within the month year?
"When it's ready."
My goal is to release by the end of June or July, for whatever that's worth ;). At the very latest October because I want to get a release done before the next Debian package freeze.
ah makes sense. ok, then we will continue our efforts with other emulators till we have something we know works and get back with you then. I didnt know nestopia was cycle-accurate, very nice to see more of that in the way of emulation. We are also adding the arkanoid paddle ( working via mouse at the moment ). Some emulators have analog support built in so it works a bit better, our plan is to add that to nestopia. All the best till we talk again!
The Arkanoid paddle is emulated, it's just a matter of hooking into the API. You may want to check out the /doc directory for more information. Also don't feel like you need to wait for a release. If you make improvements to the codebase in general it would help make a release happen faster if the changes benefit both of our goals ;).
Right we saw that but it didnt show up in a definable sense( and that makes sense since it uses a mouse). I'll check the doc thx .
Hello all, I'm the developer for Bliss-box a usb adapter for any controller you can thing of. I had a request from a user Space1 that really wanted to use the gun. Now I know about the issues with screens so no need to go in to that. He wants to try this on a CRT and depending on the timing vs usb of the emulator it just may work.
So far we have made the trigger response to a button and when the gun see's light it presses another button(very briefly, this can be extended). We set up the zapper in Nestopia to take gamepad button presses. Looks like Nestopia is hard coded to work with a mouse. I get that, makes perfect since. So we changed the code to poll for gamepad buttons. There are some issues with staring game but the biggest issue is the part in the code where it makes the white box and how to deal with it. Looks like the original author ( like many of us ) didnt have time for comments so its hard to get familiar with it.
That said, I'm going to turn this over to space1 here, look for his input as well. If you have any hardware questions for me just ask but space1 is making the code changes in Nestopia.