mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-06-04 17:53:17 +00:00
video_core: CPU flip relay (#415)
* video_core: cpu flip is propagated via gpu thread now * tentative fix for cpu flips racing * libraries: videoout: better flip status handling
This commit is contained in:
parent
ad3b6c793c
commit
27cb218584
8 changed files with 98 additions and 33 deletions
|
@ -48,13 +48,14 @@ public:
|
|||
VAddr cpu_address, bool is_eop) {
|
||||
const auto info = VideoCore::ImageInfo{attribute, cpu_address};
|
||||
const auto image_id = texture_cache.FindImage(info);
|
||||
texture_cache.UpdateImage(image_id, is_eop ? nullptr : &flip_scheduler);
|
||||
auto& image = texture_cache.GetImage(image_id);
|
||||
return PrepareFrameInternal(image, is_eop);
|
||||
}
|
||||
|
||||
Frame* PrepareBlankFrame() {
|
||||
Frame* PrepareBlankFrame(bool is_eop) {
|
||||
auto& image = texture_cache.GetImage(VideoCore::NULL_IMAGE_ID);
|
||||
return PrepareFrameInternal(image, true);
|
||||
return PrepareFrameInternal(image, is_eop);
|
||||
}
|
||||
|
||||
VideoCore::Image& RegisterVideoOutSurface(
|
||||
|
@ -75,6 +76,11 @@ public:
|
|||
void Present(Frame* frame);
|
||||
void RecreateFrame(Frame* frame, u32 width, u32 height);
|
||||
|
||||
void FlushDraw() {
|
||||
SubmitInfo info{};
|
||||
draw_scheduler.Flush(info);
|
||||
}
|
||||
|
||||
private:
|
||||
Frame* PrepareFrameInternal(VideoCore::Image& image, bool is_eop = true);
|
||||
Frame* GetRenderFrame();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue