three-d
three-d copied to clipboard
Access violation using headless context
I encountered an access violation while using the headless context. I created a minimum reproducible example here.
Run Instructions
- Compile with
cargo run, it will exit unsuccessfully without any other information. - Launch the debug executable created with windbg and it indicates an access violation.
OS
Using Microsoft Windows 11 Home, Version: 10.0.26120 Build 26120
I'm very unsure what you want to do. You created an eframe window app and a headless rendering context. I don't think that combination will work. Either you want to do headless rendering (no rendering to the screen) and use a headless context or you want to render to the screen and use a normal context.
Btw, I get this error:
`winit` requires control over the principal class. You must create the event loop before other parts of your application initialize NSApplication
Which means that you need to create an event loop if you want to use eframe, the headless context does not do that.