Skip to content

Commit

Permalink
DIRECTOR: Use pixel(0,0) for Matte ink
Browse files Browse the repository at this point in the history
  • Loading branch information
sev- committed Aug 3, 2016
1 parent 06a655f commit cc2abbb
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions engines/director/score.cpp
Expand Up @@ -539,7 +539,6 @@ void Frame::display(Archive &_movie, Graphics::ManagedSurface &surface, Common::
surface.blitFrom(*img.getSurface(), Common::Point(x, y));
break;
}
surface.frameRect(drawRect, 0);
}
}
g_system->copyRectToScreen(surface.getPixels(), surface.pitch, 0, 0, surface.getBounds().width(), surface.getBounds().height());
Expand All @@ -561,13 +560,10 @@ void Frame::drawBackgndTransSprite(Graphics::ManagedSurface &target, const Graph

void Frame::drawMatteSprite(Graphics::ManagedSurface &target, const Graphics::Surface &sprite, Common::Rect &drawRect) {
//Like background trans, but all white pixels NOT ENCLOSED by coloured pixels are transparent
uint8 skipColor = 15;
uint8 toColor = 0; // Could be anything, not used.

Graphics::Surface tmp;
tmp.copyFrom(sprite);

Graphics::FloodFill ff(&tmp, skipColor, toColor);
Graphics::FloodFill ff(&tmp, *(byte *)tmp.getBasePtr(0, 0), 0);

for (int yy = 0; yy < tmp.h; yy++) {
ff.addSeed(0, yy);
Expand Down

0 comments on commit cc2abbb

Please sign in to comment.