SFML / SFML.Net

Official binding of SFML for .Net languages

Home Page:https://www.sfml-dev.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add a way to recreate a Window without invalidating the existing Object

DemoXinMC opened this issue · comments

Options to recreate a window while reusing the existing Object should be added. While the object on the native side will be changed, the new pointer should be plugged back into the same Window to avoid additional GC overhead or access violations when attempting to work with a Window after recreating it

Alternatively: Provide a create function similar to what SFML has on their window.

commented

Would graphic resources created prior to a window getting recreated still be valid? OGL context thinking sounds.

Would graphic resources created prior to a window getting recreated still be valid? OGL context thinking sounds.

After some investigation, yes, a graphics resource absolutely persists. This feature would ultimately be a minor tweak to allow the recreation of a window without invalidating the .NET object's pointer