mirror of
https://github.com/isledecomp/isle.git
synced 2025-10-23 16:34:06 +00:00
Implement MxVideoPresenter::PutFrame (#389)
* Implementation of MxVideoPresenter::PutFrame * Add TODOs
This commit is contained in:

committed by
GitHub

parent
ceb5339369
commit
51adb31541
@@ -71,12 +71,7 @@ void MxStillPresenter::LoadFrame(MxStreamChunk* p_chunk)
|
||||
{
|
||||
memcpy(m_bitmap->GetBitmapData(), p_chunk->GetData(), p_chunk->GetLength());
|
||||
|
||||
MxS32 height = GetHeight() - 1;
|
||||
MxS32 width = GetWidth() - 1;
|
||||
MxS32 x = m_location.GetX();
|
||||
MxS32 y = m_location.GetY();
|
||||
|
||||
MxRect32 rect(x, y, width + x, height + y);
|
||||
MxRect32 rect(m_location, MxSize32(GetWidth() - 1, GetHeight() - 1));
|
||||
MVideoManager()->InvalidateRect(rect);
|
||||
|
||||
if (m_flags & Flag_Bit2) {
|
||||
@@ -154,6 +149,7 @@ void MxStillPresenter::VTable0x88(MxS32 p_x, MxS32 p_y)
|
||||
m_location.SetY(p_y);
|
||||
|
||||
if (IsEnabled()) {
|
||||
// Most likely needs to work with MxSize32 and MxPoint32
|
||||
MxS32 height = GetHeight() - 1;
|
||||
MxS32 width = GetWidth() - 1;
|
||||
|
||||
@@ -174,12 +170,7 @@ void MxStillPresenter::Enable(MxBool p_enable)
|
||||
MxVideoPresenter::Enable(p_enable);
|
||||
|
||||
if (MVideoManager() && (m_alpha || m_bitmap)) {
|
||||
MxS32 height = GetHeight();
|
||||
MxS32 width = GetWidth();
|
||||
MxS32 x = m_location.GetX();
|
||||
MxS32 y = m_location.GetY();
|
||||
|
||||
MxRect32 rect(x, y, width + x, height + y);
|
||||
MxRect32 rect(m_location, MxSize32(GetWidth(), GetHeight()));
|
||||
MVideoManager()->InvalidateRect(rect);
|
||||
MVideoManager()->VTable0x34(rect.GetLeft(), rect.GetTop(), rect.GetWidth(), rect.GetHeight());
|
||||
}
|
||||
|
Reference in New Issue
Block a user