hansschmucker / NVStreamer1080

Utility to automatically detect NVidia GameStream activity and set a fitting resolution or switch to a second screen.
Apache License 2.0
112 stars 8 forks source link

Error when launching the program #2

Closed SeeDborg closed 2 years ago

SeeDborg commented 2 years ago

Hi, I have this error when trying to launch your program : image

Full error log :

Consultez la fin de ce message pour plus de détails sur l'appel du débogage juste-à-temps (JIT) à la place de cette boîte de dialogue.

** Texte de l'exception ** System.NullReferenceException: La référence d'objet n'est pas définie à une instance d'un objet. à NVStreamer1080.NVStreamerMainUI.get_DesiredWidth() à NVStreamer1080.NVStreamerMainUI.NVStreamerMainUI_Load(Object sender, EventArgs e) à System.Windows.Forms.Form.OnLoad(EventArgs e) à System.Windows.Forms.Form.OnCreateControl() à System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible) à System.Windows.Forms.Control.CreateControl() à System.Windows.Forms.Control.WmShowWindow(Message& m) à System.Windows.Forms.Control.WndProc(Message& m) à System.Windows.Forms.Form.WmShowWindow(Message& m) à System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

** Assemblys chargés ** mscorlib Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4515.0 built by: NET48REL1LAST_C CodeBase : file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll

NVStreamer1080 Version de l'assembly : 1.0.0.0 Version Win32 : 1.0.0.0 CodeBase : file:///D:/02.T%C3%A9l%C3%A9chargements/Firefox/NVStreamer1080.exe

System.Windows.Forms Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4515.0 built by: NET48REL1LAST_C CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll

System Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4536.0 built by: NET48REL1LAST_C CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll

System.Drawing Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4395.0 built by: NET48REL1LAST_B CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll

System.Configuration Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4341.0 built by: NET48REL1LAST_C CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll

System.Core Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4536.0 built by: NET48REL1LAST_C CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll

System.Xml Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4161.0 built by: NET48REL1 CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll

mscorlib.resources Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4161.0 built by: NET48REL1 CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/mscorlib.resources/v4.0_4.0.0.0_fr_b77a5c561934e089/mscorlib.resources.dll

System.Windows.Forms.resources Version de l'assembly : 4.0.0.0 Version Win32 : 4.8.4161.0 built by: NET48REL1 CodeBase : file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms.resources/v4.0_4.0.0.0_fr_b77a5c561934e089/System.Windows.Forms.resources.dll

** Débogage JIT ** Pour activer le débogage juste-à-temps (JIT), le fichier de configuration pour cette application ou cet ordinateur (machine.config) doit avoir la valeur jitDebugging définie dans la section system.windows.forms. L'application doit également être compilée avec le débogage activé.

Par exemple :

Lorsque le débogage juste-à-temps est activé, les exceptions non gérées seront envoyées au débogueur JIT inscrit sur l'ordinateur plutôt que d'être gérées par cette boîte de dialogue.

hansschmucker commented 2 years ago

Sorry about that... it's a bug. As a workaround you can open regedit and and a key at HKEY_CURRENT_USER\SOFTWARE\TapperWare\NVStreamer1080

I'll fix it tonight.

SeeDborg commented 2 years ago

No problem, I'll wait until you fix this.

Thanks for your kindness and reactivity !

hansschmucker commented 2 years ago

No problem, the new release is up now. Let me know if I did it right this time :)

SeeDborg commented 2 years ago

I don't see it live yet, would you have a download link please ?

hansschmucker commented 2 years ago

Whoops, sorry.... it didn't indicate anywhere that it was still in draft status: https://github.com/hansschmucker/NVStreamer1080/releases/tag/v1.1.0.1

SeeDborg commented 2 years ago

I tested it and wow... It does the job perfectly... I was looking for that for a while, thanks !

Another little but report though, when I quit the game, it does restore my main screen but not the resolution and framerate (my pc monitor is 3440x1440@120Hz and I stream on a 2560x1440@120Hz monitor via Nvidia Shield (tested) or another PC (not tested yet).

hansschmucker commented 2 years ago

Hmmm... usually Windows does that by itself. In my case I have a real 5120x1440@120 screen and a virtual (dummy dongle) 1920x1080@60. When I run a game, it switches to the second screen and when I return to the first screen Windows also returns to the initial resolution.

I can add a workaround mode where it also restores the resolution 10 seconds or so after returning to the primary screen, but honestly, I wonder why that's necessary in your case... it really shouldn't be.

hansschmucker commented 2 years ago

I'll mark this issue as solved, feel free to open another one for that fallback if you can't get your primary screen to play nicely ^^