Closed flanter21 closed 7 months ago
I'm not able to reproduce, but I'm also only getting 20fps in the lag test. On the main menu I was able to reach 45-50fps though, and it seemed fine. I'm definitely interested in this, but I'm not sure what other information you can provide to help me recreate it. Other than, is that a N3DS or N3DS XL? The differences are very slight but maybe there's a bug/feature with NTR-HR such that it functions differently between the two?
I'll ping @xzn on this, in case they have any useful insight.
I can't reproduce this on Windows 11 either, was thinking it's a Mac only problem but OP said Windows 11 and Mac Sonoma.
It could be that NTR sending more than the 40 fps that is displayed somehow causing a problem.. How is it possible that Chokistream queues up seconds worth of frames though? Or is it the wifi card being funny maybe?
Edit: Maybe UDP packets are being buffered by the OS and not received fast enough somehow.. Don't know why though?
P.S.:
I did found a bug (not sure if related to this one) while looking into this.. ( updated version here edit: okay this one has a new bug try the next release please, sorry! )
(Basically wrong variables were read if frames were skipped, and stale values were used if core count were changed, so sometimes fps is half of what it could be when number of encoding core is set to 2)
I don't know why you are only getting 20 fps though? (Quality 75 QoS 16 and I get 45 fps even with just one core). @Eiim what's your wifi setup just wondering?
I admittedly haven't poked around at the NTR code for a while, so I forgot that we do actually have a frame buffer for NTR, so if the computer isn't able to render frames fast enough, that could slowly fill up, and maybe as it consumes more RAM it slows the whole system down? Honestly we probably should get rid of the NTR frame buffer, we don't use one for HzMod/Chirunomod and it could cause these kinds of desyncs without much benefit. I'll build a fork without it and we can see if that works.
As for the 20fps thing, I'm on a fairly high-end router, ~300Mbit I believe, so it shouldn't be a bottleneck compared to the 3DS WiFi chip. I had QoS at 26 before but it's the same at 16, and I fiddled with priority factor but still couldn't get it above 20 for that particular test. Snes9x in general seems pretty slow with NTR-HR (although I'm not sure if that's the same with regular NTR 3.6 or not)
@flanter21 Try this version and see if it works for you.
@Eiim is your router set to 2.4 GHz only (i.e. 5 GHz disabled)? on 5 GHz/2.4 GHz mixed I usually get around 5 Mbps (iirc) on 3DS. 2.4 GHz b/g only then I could get up to 18 Mbps without much issue.
@xzn Yes, I have both 2.4 and 5 GHz available.
@eiim @xzn I think I've got it. It's the scaling in chokistream not the streaming function. I had the top screen set to 3.0 and would get the lag, but when I set it back to 1.0 it works perfectly. I'll check out the version you put here though and edit this reply @eiim
Edit: I think the frame counter is broken btw.
@flanter21 I'm guessing the frame counter being broken is with the version I sent? This should fix it. Make sure you check with scaling at 3.0 as well to see if that's better. It might still have decreased framerate but it shouldn't desync.
Edit: fix file
@eiim the build you sent here fixes the lag although it seems impossible to get more than 30-ish fps and while it doesn't appear to have the issue, it does still seem to have more latency compared to other clients. I'm getting about ~12 frames of delay on this compared to 4to6 with kitkatslim (in Wine). The latency seems to be higher with at higher scaled resolutions.
Edit: it seems to average 20fps even at 1.0 scale whereas the release version does get 60fps at 1.0 scale. Also i forgot but you did ask earlier; i use a n3dsxl
Edit 2: v2.0.1 does actually seem to have comparable latency to kitkatslim, so this extra lag might be because of the changes you made in this build.
@eiim cool stuff. Thank you!
That commit should hopefully fix the problem of being locked to 30 FPS. Make sure that, in the NTR Settings, the "QoS" is set high enough. Setting it around 15-20 should be good.
Here's the compiled chokistream.jar for testing: https://github.com/Eiim/Chokistream/actions/runs/7812201589
Let us know if there are still any issues. I'm gonna be looking into the latency issue soon.
Haha just kidding, I forgot to test at 3x screen scale. At any rate that should be an improvement at 1x scale, but 3x scale won't see that until scaling performance is improved.
Scaling performance improved in e6c065b
Marking as closed in v2.1, let us know if there are still issues.
Describe the bug Picture renders at a seemingly capped 40fps. This means as the stream continues, the latency between whats on the 3ds and pc becomes much larger. The framerate also seems to be choppier on the Mac (but that might just be my eyes). Also seems worse when not using separate windows.
Steps taken
Tried using a different computer (both Windows 11 and Mac M1)
For streaming issues, did you try a different mod (HzMod/NTR/ChirunoMod) or mod version (in particular with HzMod)? Issues which only occur with one mod or mod version are generally still valid, but it helps greatly in debugging them, and can provide a temporary workaround.
For connection issues, have you tried pinging the 3DS IP from your computer?
Versions/settings
Take screenshots of the Chokistream settings, including mod settings, and put them here. Difference clearly seen when using 240p test suite in snes9x. FPS ends up reaching 0 after a few minutes. Default settings
Additional context Add any other context about the problem here.