Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Libretro: add D3D11 support / fix GL context reset. #10809

Merged
merged 8 commits into from
Mar 27, 2018
Merged

Libretro: add D3D11 support / fix GL context reset. #10809

merged 8 commits into from
Mar 27, 2018

Conversation

aliaspider
Copy link
Contributor

D3D11 support is still experimental but it does seem to work well enough. this includes a small change to thin3d_d3d11 by adding a BeginFrame implementation.

incidentally, I also found a fix for the GL context reset problem which was to simply request for the context to be cached during a reset. DeviceLost/Restore for GL and D3D11 are still unable to switch to a new context, but this is good enough for now I think.

fixes #10784

Copy link
Owner

@hrydgard hrydgard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems fine.

@@ -1274,6 +1276,34 @@ void D3D11DrawContext::Clear(int mask, uint32_t colorval, float depthVal, int st
}
}

void D3D11DrawContext::BeginFrame() {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess this is needed to restore state after RetroArch has done its drawing? I don't mind really, should be very cheap.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, I was a bit worried about the cost.

@@ -70,6 +70,8 @@ ConsoleListener::ConsoleListener() : bHidden(true)
bUseColor = false;
#elif PPSSPP_PLATFORM(UWP)
bUseColor = false;
#elif defined(_MSC_VER)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looked weird to me first but I see that it's just in the non-UI case.

@hrydgard hrydgard merged commit 29de4b5 into hrydgard:master Mar 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

(libretro) context_reset is broken
3 participants