Gran Turismo 4 regression
#21
@Flatout,
Can I let you handle the search of the regression ?
Reply

Sponsored links

#22
I'll have another look at it this weekend.
Reply
#23
(09-29-2016, 01:16 AM)pepiczech Wrote: Please try build 588 and 589. Just to make sure.
Yes, it is 589. I missed your earlier edit where you mentioned this build as the cause of the issue.

@gregory: That's this commit:
https://github.com/PCSX2/pcsx2/commit/22...801cd61ea4
Reply
#24
In order to avoid bad revert. I need tests on some patches. Could you tell me which one fix the issue (or not, or might need both)

Code:
diff --git a/plugins/GSdx/GSTextureOGL.cpp b/plugins/GSdx/GSTextureOGL.cpp
index 5625614..397d1d4 100644
--- a/plugins/GSdx/GSTextureOGL.cpp
+++ b/plugins/GSdx/GSTextureOGL.cpp
@@ -392,6 +394,8 @@ bool GSTextureOGL::Map(GSMap& m, const GSVector4i* _r)
        glBindFramebuffer(GL_READ_FRAMEBUFFER, m_fbo_read);
        glFramebufferTexture2D(GL_READ_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, m_texture_id, 0);
 
+       glPixelStorei(GL_PACK_ALIGNMENT, 1u << m_int_shift);
+
        glReadPixels(r.x, r.y, r.width(), r.height(), m_int_format, m_int_type, m_local_buffer);
 
        glBindFramebuffer(GL_READ_FRAMEBUFFER, 0);


Code:
diff --git a/plugins/GSdx/GSTextureOGL.cpp b/plugins/GSdx/GSTextureOGL.cpp
index 5625614..397d1d4 100644
--- a/plugins/GSdx/GSTextureOGL.cpp
+++ b/plugins/GSdx/GSTextureOGL.cpp
@@ -356,6 +356,8 @@ bool GSTextureOGL::Update(const GSVector4i& r, const void* data, int pitch)
 
    PboPool::Unmap();
 
+   glPixelStorei(GL_UNPACK_ALIGNMENT, 1u << m_int_shift);
+
    glTextureSubImage2D(m_texture_id, GL_TEX_LEVEL_0, r.x, r.y, r.width(), r.height(), m_int_format, m_int_type, (const void*)PboPool::Offset());
 
    // FIXME OGL4: investigate, only 1 unpack buffer always bound
@@ -432,6 +436,8 @@ void GSTextureOGL::Unmap()
 
        PboPool::Unmap();
 
+       glPixelStorei(GL_UNPACK_ALIGNMENT, 1u << m_int_shift);
+
        glTextureSubImage2D(m_texture_id, GL_TEX_LEVEL_0, m_r_x, m_r_y, m_r_w, m_r_h, m_int_format, m_int_type, (const void*)PboPool::Offset());
 
        // FIXME OGL4: investigate, only 1 unpack buffer always bound
Reply
#25
The first patch (GL_PACK_ALIGNMENT) fixes the issue. The second does not.
Reply
#26
Ok it make sense. I forget to set a default value to read back the texture. The default is 4 (or 32 bits). I guess GT4 uses a 16 bits RT.
Reply
#27
Good, 1 less bug. Only remain 1600.
Reply
#28
(10-02-2016, 12:17 PM)gregory Wrote: Good, 1 less bug. Only remain 1600.
Only 1600? That must mean the emulator is alsmost finished. Laugh
Reply
#29
Yeah 1600 broken games on 2000.
Reply
#30
It's still a lot of progress. Comparing from 1.2.1
CPU: I7-4770 3.9GHZ
Motherboard: Asrock B85M - DGS
RAM: Hyper X Savage 2x8GB 1.6GHZ CL9
GPU: GTX1070 8GB GDDR5
OS: Windows 10 Pro 64bit
Reply




Users browsing this thread: 1 Guest(s)