sjoerd222's picture

Strange Behaviour. 'System.AccessViolationException' occurred in OpenTK.dll , Destroying Windo, Creating Graphics context.

The code I use here was taken from another working application. (But of course I could have forgot something). I debug the application in Visual Studio. The programm works. After a certain amount of startups this messages start to appear in the output. Nothing does start. OpenTK tries to create a content and fails all the time. I wonder what could be the reason for this. I saw there was once a with similar output. I use Nvidia GeForce GTS240. But the problem did not occur before some days. (After installing glslDevil, can this affect it? Though uninstall made no difference). Of course the I did update the Nvidia Driver to 260.99.

Does anybody have a proposal for further investigations I could do?

Output:

Creating GraphicsContext.
Creating GraphicsContext.
Device context: 604055740
Selecting pixel format... GraphicsMode: Index: 11, Color: 24 (8880), Depth: 0, Stencil: 0, Samples: 0, Accum: 64 (16161616), Buffers: 2, Stereo: False
IWindowInfo: Windows.WindowInfo: Handle 201316, Parent (Windows.WindowInfo: Handle 201326, Parent (null))
GraphicsContextFlags: Default
Requested version: 1.0
OpenGL will be bound to handle: 201316
Setting pixel format... 11
Using WGL_ARB_create_context... A first chance exception of type 'System.AccessViolationException' occurred in OpenTK.dll
Destroying window: Windows.WindowInfo: Handle 201326, Parent (null)
Creating GraphicsContext.
Creating GraphicsContext.
Device context: 1879124189
Selecting pixel format... GraphicsMode: Index: 11, Color: 24 (8880), Depth: 0, Stencil: 0, Samples: 0, Accum: 64 (16161616), Buffers: 2, Stereo: False
IWindowInfo: Windows.WindowInfo: Handle 266852, Parent (Windows.WindowInfo: Handle 266862, Parent (null))
GraphicsContextFlags: Default
Requested version: 1.0
OpenGL will be bound to handle: 266852
Setting pixel format... 11
Using WGL_ARB_create_context... A first chance exception of type 'System.AccessViolationException' occurred in OpenTK.dll
Destroying window: Windows.WindowInfo: Handle 266862, Parent (null)
Creating GraphicsContext.
Creating GraphicsContext.
Device context: 1879124189
Selecting pixel format... GraphicsMode: Index: 11, Color: 24 (8880), Depth: 0, Stencil: 0, Samples: 0, Accum: 64 (16161616), Buffers: 2, Stereo: False
IWindowInfo: Windows.WindowInfo: Handle 332388, Parent (Windows.WindowInfo: Handle 332398, Parent (null))
GraphicsContextFlags: Default
Requested version: 1.0
OpenGL will be bound to handle: 332388
Setting pixel format... 11
Using WGL_ARB_create_context... A first chance exception of type 'System.AccessViolationException' occurred in OpenTK.dll
Destroying window: Windows.WindowInfo: Handle 332398, Parent (null)
...
and so on


Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler's picture

Can you please try with the latest beta drivers for Nvidia (266.xx)?

260.99 contain a known crash bug.

sjoerd222's picture

After Installing 266.35 this error did not occur any more. So this was really a driver issue and the problem seems to be fixed in current beta.

the Fiddler's picture

Thanks for confirming that!

As a workaround for 260.99, you can toggle the "enable threaded optimization" option in the Nvidia control panel.