mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-14 21:59:17 +00:00
DIRECTOR: Fix FilmLoopCastMember::getSubChannels
The new bounding box calculation requires the transformed position/size to be in Sprite, not Channel. Fixes the visibility of the boar hunt in Wrath of the Gods.
This commit is contained in:
parent
f92f78ef9a
commit
fa2e5ac9de
@ -91,14 +91,17 @@ Common::Array<Channel> *FilmLoopCastMember::getSubChannels(Common::Rect &bbox, C
|
||||
int16 width = src._width * widgetRect.width() / _initialRect.width();
|
||||
int16 height = src._height * widgetRect.height() / _initialRect.height();
|
||||
|
||||
// Re-inject the translated position into the Sprite.
|
||||
// This saves the hassle of having to force the Channel to be in puppet mode.
|
||||
src._width = width;
|
||||
src._height = height;
|
||||
src._startPoint = Common::Point(absX, absY);
|
||||
src._stretch = true;
|
||||
|
||||
// Film loop frames are constructed as a series of Channels, much like how a normal frame
|
||||
// is rendered by the Score. We don't include a pointer to the current Score here,
|
||||
// that's only for querying the constraint channel which is not used.
|
||||
Channel chan(nullptr, &src);
|
||||
chan._currentPoint = Common::Point(absX, absY);
|
||||
chan._width = width;
|
||||
chan._height = height;
|
||||
|
||||
_subchannels.push_back(chan);
|
||||
|
||||
}
|
||||
|
@ -302,7 +302,11 @@ void Window::inkBlitFrom(Channel *channel, Common::Rect destRect, Graphics::Mana
|
||||
uint32 renderStartTime = 0;
|
||||
if (debugChannelSet(8, kDebugImages)) {
|
||||
CastType castType = channel->_sprite->_cast ? channel->_sprite->_cast->_type : kCastTypeNull;
|
||||
debugC(8, kDebugImages, "Window::inkBlitFrom(): updating %dx%d @ %d,%d, type: %s, ink: %d", destRect.width(), destRect.height(), destRect.left, destRect.top, castType2str(castType), channel->_sprite->_ink);
|
||||
debugC(8, kDebugImages, "Window::inkBlitFrom(): updating %dx%d @ %d,%d -> %dx%d @ %d,%d, type: %s, cast: %s, ink: %d",
|
||||
srcRect.width(), srcRect.height(), srcRect.left, srcRect.top,
|
||||
destRect.width(), destRect.height(), destRect.left, destRect.top,
|
||||
castType2str(castType), channel->_sprite->_castId.asString().c_str(),
|
||||
channel->_sprite->_ink);
|
||||
renderStartTime = g_system->getMillis();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user