Closed Berserker66 closed 7 years ago
Hello @Berserker66, as you say, I think it's better to show the detailed code. Maybe we could write both of the version but it's redundant. What is your opinion about it ?
Since it is meant to serve as an example, I think it is important to preserve the "old" step by step method, but at the same time, it is also important to show the "proper" way to do it.
I'm not sure what the best way to accomplish that is. The two obvious ways, I think, are to either have two examples (at least for a time), showing both ways. Or, the example gets restructured to a more object oriented design, where you could have two methods for either way of doing it and giving some comments about how each method has their place.
Oh yeah, another plus for the old method: at some point there may be a vulkan 2 and sdl2 may not be updated as quickly as vulkan is. The manual way would then be the only way to get such a vulkan 2 working with sdl2. This is full of assumptions about the future, of course.
Indeed @Berserker66, If you want to fully manage your Vulkan instance, you need the current example. Using the pysdl2
is not the goal of this sample so we can stay as is. Still it was a good remark and we keep the trace in this ticket history.
Thanks @Berserker66 .
So, PySDL2 updated: https://github.com/marcusva/py-sdl2 News Article: https://www.pygame.org/news.html
Now uses SDL2 2.0.6, which has vulkan support, as in it can now create a vulkan instance attached to a window "for you".
Should the SDL2 example be updated to use this functionality? Or should the old way be kept to show how this might be done with other frameworks that don't have out of the box support?
It should be noted I haven't tried this yet. So I don't know if this vulkan manages to wrap the sdl2 references correctly and therefore if you even can use the new sdl2 stuff without using cffi in the application.