haasn / libplacebo

Official mirror of libplacebo
http://libplacebo.org/
GNU Lesser General Public License v2.1
544 stars 69 forks source link

Native Metal backend #284

Open rweichler opened 1 month ago

rweichler commented 1 month ago

Hi, I saw this: https://github.com/mpv-player/mpv/issues/12486#issuecomment-1734630662

I was wondering what the rough plan for this is? Has it been started yet? I was actually considering pulling MoltenVK into my project but if there's been any progress made on the Metal backend I think I would rather use that, even if it's incomplete. I looked at the OpenGL backend which is ~3KLOC, assuming the Metal backend is in the same ballpark I would rather maintain something like that (vs bring in MoltenVK as a dependency).

Thanks

haasn commented 1 month ago

Hey,

The idea has been effectively put on hold. I am too busy these days with other projects, and my personal life. I didn't even get around to upgrading my aging laptop. (The catalyst was that I was planning on picking up a Macbook and using that for development, but this is also on hold for the time being)

I wouldn't say the idea is completely dead, just that I have other priorities at the moment. Even in the context of libplacebo, there are things I'd say are more important (e.g. finishing the refactor of the queue and swapchain APIs)

Edit: That said, if you are interested enough in this, I can definitely find the time to provide guidance on how to implement a new GPU backend.

rweichler commented 1 month ago

Maybe I'll give it a shot. Porting it to Metal might still be easier than trying to fit MoltenVK into my project. If I were to attempt this, I would try porting the OpenGL code to Metal, as I'm only familiar with those two.

rweichler commented 1 month ago

No guarantees though.