SDL2 2.0.4 iOS Multisample HIGHDPI |
spartanjjj
|
I might have found the solution.
Have to get the framebuffer from wmInfo.info.uikit.framebuffer; |
|||||||||||
|
spartanjjj
|
Just tested it and i returns ID = 0 on both framebuffer and colorbuffer. Visual results are just the same as before, so no that wasn't the solution.
Anyone ? |
|||||||||||
|
SDL2 2.0.4 iOS Multisample HIGHDPI |
Alex Szpakowski
Guest
|
If this message shows up 3 times I apologize – my email client was sending it from the wrong account…
MSAA support for the main framebuffer is not implemented on iOS right now, unfortunately. The main framebuffer on iOS is really an OpenGL ES Framebuffer Object, which means proper MSAA support involves an explicit MSAA resolve (via glBlitFramebuffer or glResolveMultisampleFramebufferAPPLE calls, depending on the OpenGL ES version.) SDL_GL_SwapBuffers would of course be able to call those functions internally and hide those details, but if you were to call glReadPixels it would fail unless you first explicitly resolved the MSAA color buffer to a non-MSAA color buffer, and then bound the non-MSAA color buffer to the read framebuffer binding point, before calling glReadPixels. So I haven’t added MSAA support for the default framebuffer on iOS (yet), because I haven’t been able to reconcile the fact that users expecting glReadPixels calls to work as expected without any modifications to their code will be surprised and disappointed. If anyone has suggestions for that, I’d be happy to hear them though.
|
|||||||||||||
|
SDL2 2.0.4 iOS Multisample HIGHDPI |
Ryan C. Gordon
Guest
|
We _could_ add a hint for this, but I'd say it's better to just do what you need to do to enable MSAA when the app requests it and assume that iOS developers will figure out what the correct steps are within their app if they really want to use it. It's not like it'll subtly break in the field for a subset of users, what you describe would be noticed and fixed before shipping. (and if it generates a FAQ on the wiki, that's okay.) (also, how many people are really using glReadPixels() on the default framebuffer in 2015?) --ryan. _______________________________________________ SDL mailing list http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org |
|||||||||||||
|
SDL2 2.0.4 iOS Multisample HIGHDPI |
slime73
|
MSAA support for the main framebuffer is not implemented on iOS right now, unfortunately.
The main framebuffer on iOS is really an OpenGL ES Framebuffer Object, which means proper MSAA support involves an explicit MSAA resolve (via glBlitFramebuffer or glResolveMultisampleFramebufferAPPLE calls, depending on the OpenGL ES version.) SDL_GL_SwapBuffers would of course be able to call those functions internally and hide those details, but if you were to call glReadPixels it would fail unless you first explicitly resolved the MSAA color buffer to a non-MSAA color buffer, and then bound the non-MSAA color buffer to the read framebuffer binding point, before calling glReadPixels. So I haven’t added MSAA support for the default framebuffer on iOS (yet), because I haven’t been able to reconcile the fact that users expecting glReadPixels calls to work as expected without any modifications to their code will be surprised and disappointed. If anyone has suggestions for that, I’d be happy to hear them though.
|
|||||||||||||
|
SDL2 2.0.4 iOS Multisample HIGHDPI |
slime73
|
MSAA support for the main framebuffer is not implemented on iOS right now, unfortunately.
The main framebuffer on iOS is really an OpenGL ES Framebuffer Object, which means proper MSAA support involves an explicit MSAA resolve (via glBlitFramebuffer or glResolveMultisampleFramebufferAPPLE calls, depending on the OpenGL ES version.) SDL_GL_SwapBuffers would of course be able to call those functions internally and hide those details, but if you were to call glReadPixels it would fail unless you first explicitly resolved the MSAA color buffer to a non-MSAA color buffer, and then bound the non-MSAA color buffer to the read framebuffer binding point, before calling glReadPixels. So I haven’t added MSAA support for the default framebuffer on iOS (yet), because I haven’t been able to reconcile the fact that users expecting glReadPixels calls to work as expected without any modifications to their code will be surprised and disappointed. If anyone has suggestions for that, I’d be happy to hear them though. (I originally sent this from the wrong email account by accident, so I apologize if the same reply is posted twice.)
|
|||||||||||||
|
spartanjjj
|
Hi Slime,
I understand the problem. what about giving us the buffers handles and so we can work with it? default color/depth buffers and render buffer when using MSAA. That would be a way. |
|||||||||||
|