mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-02-06 00:40:11 +00:00
OpenGL: do not align buffers
This commit is contained in:
parent
6cd62a9fd0
commit
1c890f85c5
@ -1118,8 +1118,8 @@ void GLGSRender::onexit_thread()
|
||||
{
|
||||
glDisable(GL_VERTEX_PROGRAM_POINT_SIZE);
|
||||
|
||||
if (m_program)
|
||||
m_program.remove();
|
||||
//if (m_program)
|
||||
// m_program.remove();
|
||||
|
||||
if (draw_fbo)
|
||||
draw_fbo.remove();
|
||||
@ -1445,8 +1445,8 @@ void GLGSRender::init_buffers()
|
||||
.format(format.format)
|
||||
.swizzle(format.swizzle.r, format.swizzle.g, format.swizzle.b, format.swizzle.a);
|
||||
|
||||
__glcheck m_draw_tex_color[i].pixel_pack_settings().swap_bytes(format.swap_bytes);
|
||||
__glcheck m_draw_tex_color[i].pixel_unpack_settings().swap_bytes(format.swap_bytes);
|
||||
__glcheck m_draw_tex_color[i].pixel_pack_settings().swap_bytes(format.swap_bytes).aligment(1);
|
||||
__glcheck m_draw_tex_color[i].pixel_unpack_settings().swap_bytes(format.swap_bytes).aligment(1);
|
||||
|
||||
__glcheck draw_fbo.color[i] = m_draw_tex_color[i];
|
||||
__glcheck draw_fbo.check();
|
||||
@ -1743,6 +1743,9 @@ void GLGSRender::flip(int buffer)
|
||||
.type(gl::texture::type::uint_8_8_8_8)
|
||||
.format(gl::texture::format::bgra);
|
||||
|
||||
m_flip_tex_color.pixel_unpack_settings().aligment(1);
|
||||
m_flip_tex_color.pixel_pack_settings().aligment(1);
|
||||
|
||||
__glcheck m_flip_fbo.recreate();
|
||||
__glcheck m_flip_fbo.color = m_flip_tex_color;
|
||||
}
|
||||
@ -1759,7 +1762,7 @@ void GLGSRender::flip(int buffer)
|
||||
glDisable(GL_CULL_FACE);
|
||||
|
||||
__glcheck m_flip_tex_color.copy_from(vm::get_ptr(buffer_address),
|
||||
gl::texture::format::bgra, gl::texture::type::uint_8_8_8_8, gl::pixel_unpack_settings().row_length(buffer_pitch / 4));
|
||||
gl::texture::format::bgra, gl::texture::type::uint_8_8_8_8);
|
||||
}
|
||||
|
||||
areai screen_area = coordi({}, { (int)buffer_width, (int)buffer_height });
|
||||
|
@ -1119,7 +1119,7 @@ namespace gl
|
||||
{
|
||||
save_binding_state save(*this);
|
||||
pixel_settings.apply();
|
||||
glTexSubImage2D((GLenum)get_target(), level(), 0, 0, width(), height(), (GLenum)format, (GLenum)type, src);
|
||||
__glcheck glTexSubImage2D((GLenum)get_target(), level(), 0, 0, width(), height(), (GLenum)format, (GLenum)type, src);
|
||||
}
|
||||
|
||||
void copy_from(const buffer& buf, texture::format format, texture::type type, class pixel_unpack_settings pixel_settings)
|
||||
@ -1142,7 +1142,7 @@ namespace gl
|
||||
{
|
||||
save_binding_state save(*this);
|
||||
pixel_settings.apply();
|
||||
glGetTexImage((GLenum)get_target(), level(), (GLenum)format, (GLenum)type, dst);
|
||||
__glcheck glGetTexImage((GLenum)get_target(), level(), (GLenum)format, (GLenum)type, dst);
|
||||
}
|
||||
|
||||
void copy_to(void* dst, texture::type type, class pixel_pack_settings pixel_settings) const
|
||||
|
Loading…
x
Reference in New Issue
Block a user