mirror of
https://github.com/WinampDesktop/winamp.git
synced 2025-06-17 18:55:46 -04:00
libretro: Use framebuffer view dimensions not texture dimensions
This commit is contained in:
@ -461,13 +461,13 @@ void OpenGLHostDisplay::RenderSoftwareCursor()
|
||||
return;
|
||||
|
||||
const auto [left, top, width, height] = CalculateSoftwareCursorDrawRect();
|
||||
RenderSoftwareCursor(left, top, width, height, m_cursor_texture.get());
|
||||
RenderSoftwareCursor(left, GetWindowHeight() - top - height, width, height, m_cursor_texture.get());
|
||||
}
|
||||
|
||||
void OpenGLHostDisplay::RenderSoftwareCursor(s32 left, s32 top, s32 width, s32 height,
|
||||
void OpenGLHostDisplay::RenderSoftwareCursor(s32 left, s32 bottom, s32 width, s32 height,
|
||||
HostDisplayTexture* texture_handle)
|
||||
{
|
||||
glViewport(left, GetWindowHeight() - top - height, width, height);
|
||||
glViewport(left, bottom, width, height);
|
||||
glEnable(GL_BLEND);
|
||||
glBlendFuncSeparate(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA, GL_ONE, GL_ZERO);
|
||||
glBlendEquationSeparate(GL_FUNC_ADD, GL_FUNC_ADD);
|
||||
|
@ -69,7 +69,7 @@ protected:
|
||||
void RenderDisplay(s32 left, s32 bottom, s32 width, s32 height, void* texture_handle, u32 texture_width,
|
||||
s32 texture_height, s32 texture_view_x, s32 texture_view_y, s32 texture_view_width,
|
||||
s32 texture_view_height, bool linear_filter);
|
||||
void RenderSoftwareCursor(s32 left, s32 top, s32 width, s32 height, HostDisplayTexture* texture_handle);
|
||||
void RenderSoftwareCursor(s32 left, s32 bottom, s32 width, s32 height, HostDisplayTexture* texture_handle);
|
||||
|
||||
std::unique_ptr<GL::Context> m_gl_context;
|
||||
|
||||
|
Reference in New Issue
Block a user