{"action":"created","issue":{"url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/6385","repository_url":"https://api.github.com/repos/dolphin-emu/dolphin","labels_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/6385/labels{/name}","comments_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/6385/comments","events_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/6385/events","html_url":"https://github.com/dolphin-emu/dolphin/pull/6385","id":297990176,"node_id":"MDExOlB1bGxSZXF1ZXN0MTY5Nzc0ODk1","number":6385,"title":"Metal Graphics Backend","user":{"login":"stenzek","id":11288319,"node_id":"MDQ6VXNlcjExMjg4MzE5","avatar_url":"https://avatars2.githubusercontent.com/u/11288319?v=4","gravatar_id":"","url":"https://api.github.com/users/stenzek","html_url":"https://github.com/stenzek","followers_url":"https://api.github.com/users/stenzek/followers","following_url":"https://api.github.com/users/stenzek/following{/other_user}","gists_url":"https://api.github.com/users/stenzek/gists{/gist_id}","starred_url":"https://api.github.com/users/stenzek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stenzek/subscriptions","organizations_url":"https://api.github.com/users/stenzek/orgs","repos_url":"https://api.github.com/users/stenzek/repos","events_url":"https://api.github.com/users/stenzek/events{/privacy}","received_events_url":"https://api.github.com/users/stenzek/received_events","type":"User","site_admin":false},"labels":[{"id":221808232,"node_id":"MDU6TGFiZWwyMjE4MDgyMzI=","url":"https://api.github.com/repos/dolphin-emu/dolphin/labels/WIP","name":"WIP","color":"0052cc","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-02-17T08:43:43Z","updated_at":"2018-08-06T23:02:42Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/dolphin-emu/dolphin/pulls/6385","html_url":"https://github.com/dolphin-emu/dolphin/pull/6385","diff_url":"https://github.com/dolphin-emu/dolphin/pull/6385.diff","patch_url":"https://github.com/dolphin-emu/dolphin/pull/6385.patch"},"body":"**Off topic comments not related to testing and feedback will be strictly moderated.**\r\n\r\nThis branch introduces (yet another) backend to Dolphin: Metal. It is largely a work-in-progress, and several features are missing. The main motivation of developing this backend was to ensure the new videocommon interface design provided sufficient capabilities to move the majority of logic currently in the backends to common code.\r\n\r\nThus, the Metal backend has the abstract framebuffer and pipeline branches as prerequisites. All functionality is built using these primitives, avoiding any Metal-specific code where possible, outside of the derived abstract classes themselves.\r\n\r\nRather than mixing Objective C and C++, I used a C++ metal wrapper library (mtlpp). This in my opinion improves code clarity, and also has the benefit of handling object lifetimes, removing the need to sprinkle release and retain calls all over the source.\r\n\r\nThese two reasons are why the diff line count is huge. The backend itself is only around 5k lines. I'm not expecting anyone to review it just yet, at least not until the prerequisites are merged.\r\n\r\nThe changes to shadergen are rather intrusive, in some ways the code we were generating did not fit well with the Metal shading language. Perhaps there is a better way to support all the languages, aside from using an external translator.\r\n\r\nAlso, being a heavier language (C++-based), shader compilation \"stutter\" is likely worse than OpenGL, ubershaders and UID caches will be the solution here. But these will be implemented in common rather than the backend, so until that happens the backend will not support ubershaders.\r\n\r\nRough TODO list is as follows:\r\n- [x] Support emitting MSL texture conversion shaders\r\n- [x] Support emitting MSL vertex/pixel shaders\r\n- [x] Basic rendering support in Metal backend\r\n- [x] Abstract object implementations (texture/framebuffer/pipeline/staging texture)\r\n- [x] Stream buffer implementation\r\n- [x] State tracking\r\n- [x] EFB to texture and RAM\r\n- [ ] Design a solution to render lines/points without geometry shaders (VS instancing perhaps?)\r\n- [x] Figure out a way to get uncapped framerates (present skipping based on notifications from display link?)\r\n- [ ] Multisampling support\r\n- [ ] Bounding box/SSBO support\r\n- [x] Ubershader/async pipeline compilation - this will be implemented in common\r\n- [ ] CPU EFB access (efb \"peeks\"/\"pokes\") - this will be implemented in common\r\n- [ ] Post processing - this will be implemented in common\r\n- [ ] Improve and optimize performance\r\n- [ ] Bug fixes"},"comment":{"url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/comments/410879659","html_url":"https://github.com/dolphin-emu/dolphin/pull/6385#issuecomment-410879659","issue_url":"https://api.github.com/repos/dolphin-emu/dolphin/issues/6385","id":410879659,"node_id":"MDEyOklzc3VlQ29tbWVudDQxMDg3OTY1OQ==","user":{"login":"MrGcGamer","id":32813275,"node_id":"MDQ6VXNlcjMyODEzMjc1","avatar_url":"https://avatars0.githubusercontent.com/u/32813275?v=4","gravatar_id":"","url":"https://api.github.com/users/MrGcGamer","html_url":"https://github.com/MrGcGamer","followers_url":"https://api.github.com/users/MrGcGamer/followers","following_url":"https://api.github.com/users/MrGcGamer/following{/other_user}","gists_url":"https://api.github.com/users/MrGcGamer/gists{/gist_id}","starred_url":"https://api.github.com/users/MrGcGamer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MrGcGamer/subscriptions","organizations_url":"https://api.github.com/users/MrGcGamer/orgs","repos_url":"https://api.github.com/users/MrGcGamer/repos","events_url":"https://api.github.com/users/MrGcGamer/events{/privacy}","received_events_url":"https://api.github.com/users/MrGcGamer/received_events","type":"User","site_admin":false},"created_at":"2018-08-06T23:02:42Z","updated_at":"2018-08-06T23:02:42Z","author_association":"NONE","body":"When will we see the metal backend get implemented in Dolphin? Or is something like a beta already out? (I have a MakBookPro mid2010 so Wind Waker runs terribly with opengl and I don’t know how to improve the performance and than I heard a Metal backend is in work)"}}
{"actor":{"display_login":"MrGcGamer"}}