summaryrefslogtreecommitdiff
path: root/pcr/reicast-multilib-git/wait_if_two_frames_already_in_flight_old.patch
diff options
context:
space:
mode:
authorcoadde [Márcio Alexandre Silva Delgado] <coadde@parabola.nu>2015-08-23 22:25:37 -0300
committercoadde [Márcio Alexandre Silva Delgado] <coadde@parabola.nu>2015-08-28 18:37:18 -0300
commite6535c873331a54a21435d8e9450b09a596a6874 (patch)
tree32ae5f05f8dcb9be8316db81251295b351753903 /pcr/reicast-multilib-git/wait_if_two_frames_already_in_flight_old.patch
parent2c37cc178227a3956f82e1b2b589824028c3d269 (diff)
downloadabslibre-e6535c873331a54a21435d8e9450b09a596a6874.tar.gz
abslibre-e6535c873331a54a21435d8e9450b09a596a6874.tar.bz2
abslibre-e6535c873331a54a21435d8e9450b09a596a6874.zip
pcr/reicast{,-multilib}-git
Diffstat (limited to 'pcr/reicast-multilib-git/wait_if_two_frames_already_in_flight_old.patch')
-rw-r--r--pcr/reicast-multilib-git/wait_if_two_frames_already_in_flight_old.patch70
1 files changed, 70 insertions, 0 deletions
diff --git a/pcr/reicast-multilib-git/wait_if_two_frames_already_in_flight_old.patch b/pcr/reicast-multilib-git/wait_if_two_frames_already_in_flight_old.patch
new file mode 100644
index 000000000..ff297365c
--- /dev/null
+++ b/pcr/reicast-multilib-git/wait_if_two_frames_already_in_flight_old.patch
@@ -0,0 +1,70 @@
+diff -Nur reicast-emulator.orig/core/hw/pvr/Renderer_if.cpp reicast-emulator/core/hw/pvr/Renderer_if.cpp
+--- reicast-emulator.orig/core/hw/pvr/Renderer_if.cpp 2015-06-20 02:04:02.180069939 -0300
++++ reicast-emulator/core/hw/pvr/Renderer_if.cpp 2015-06-20 02:10:17.831402600 -0300
+@@ -184,6 +184,7 @@
+
+ bool rend_frame(TA_context* ctx, bool draw_osd) {
+ bool proc = renderer->Process(ctx);
++ FinishRender(_pvrrc);
+ re.Set();
+
+ bool do_swp = proc && renderer->Render();
+@@ -207,7 +208,7 @@
+ bool do_swp = rend_frame(_pvrrc, true);
+
+ //clear up & free data ..
+- FinishRender(_pvrrc);
++ tactx_Recycle(_pvrrc);
+ _pvrrc=0;
+
+ return do_swp;
+@@ -260,6 +261,7 @@
+
+
+ bool pend_rend = false;
++extern TA_context* rqueue;
+
+ void rend_resize(int width, int height) {
+ renderer->Resize(width, height);
+@@ -268,6 +270,10 @@
+
+ void rend_start_render()
+ {
++ if (rqueue) {
++ rend_end_render();
++ }
++
+ pend_rend = false;
+ bool is_rtt=(FB_W_SOF1& 0x1000000)!=0;
+ TA_context* ctx = tactx_Pop(CORE_CURRENT_CTX);
+@@ -314,7 +320,6 @@
+ }
+ }
+
+-
+ void rend_end_render()
+ {
+ #if 1 //also disabled the printf, it takes quite some time ...
+@@ -325,8 +330,9 @@
+ #endif
+ #endif
+
+- if (pend_rend)
++ if (pend_rend) {
+ re.Wait();
++ }
+ }
+
+ /*
+diff -Nur reicast-emulator.orig/core/hw/pvr/ta_ctx.cpp reicast-emulator/core/hw/pvr/ta_ctx.cpp
+--- reicast-emulator.orig/core/hw/pvr/ta_ctx.cpp 2015-06-20 02:04:02.186736275 -0300
++++ reicast-emulator/core/hw/pvr/ta_ctx.cpp 2015-06-20 02:07:44.202370584 -0300
+@@ -119,8 +119,6 @@
+ mtx_rqueue.Lock();
+ rqueue = 0;
+ mtx_rqueue.Unlock();
+-
+- tactx_Recycle(ctx);
+ }
+
+ cMutex mtx_pool;