aboutsummaryrefslogtreecommitdiff
path: root/engines/wintermute
diff options
context:
space:
mode:
authorTobia Tesan2013-06-27 17:28:43 +0200
committerTobia Tesan2013-08-01 00:02:48 +0200
commite47deb0e0e02f8ab288c21a33f5ec6187ab15e71 (patch)
tree8f7c2b9f582c840b3d534c1e0769db0847491f40 /engines/wintermute
parente30ab15bb0f21a77f8e1752745cd6ec954661d83 (diff)
downloadscummvm-rg350-e47deb0e0e02f8ab288c21a33f5ec6187ab15e71.tar.gz
scummvm-rg350-e47deb0e0e02f8ab288c21a33f5ec6187ab15e71.tar.bz2
scummvm-rg350-e47deb0e0e02f8ab288c21a33f5ec6187ab15e71.zip
WINTERMUTE: Rename pixel copy functions
Diffstat (limited to 'engines/wintermute')
-rw-r--r--engines/wintermute/graphics/transparent_surface.cpp12
-rw-r--r--engines/wintermute/graphics/transparent_surface.h4
2 files changed, 8 insertions, 8 deletions
diff --git a/engines/wintermute/graphics/transparent_surface.cpp b/engines/wintermute/graphics/transparent_surface.cpp
index 403ce8984e..bdf074fdd9 100644
--- a/engines/wintermute/graphics/transparent_surface.cpp
+++ b/engines/wintermute/graphics/transparent_surface.cpp
@@ -31,7 +31,7 @@
namespace Wintermute {
-void TransparentSurface::nearestCopy(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst) {
+void TransparentSurface::copyPixelNearestNeighbor(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst) {
int srcW = srcRect.width();
int srcH = srcRect.height();
int dstW = dstRect.width();
@@ -51,7 +51,7 @@ void TransparentSurface::nearestCopy(float projX, float projY, int dstX, int dst
WRITE_UINT32((byte *)dst->getBasePtr(dstX, dstY), color);
}
-void TransparentSurface::bilinearCopy(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst) {
+void TransparentSurface::copyPixelBilinear(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst) {
int srcW = srcRect.width();
int srcH = srcRect.height();
@@ -528,7 +528,7 @@ TransparentSurface *TransparentSurface::rotate(TransformStruct transform) const
targX += transform._hotspot.x;
targY += transform._hotspot.y;
- nearestCopy(targX, targY, x, y, srcRect, dstRect, this, target);
+ copyPixelNearestNeighbor(targX, targY, x, y, srcRect, dstRect, this, target);
}
}
} else {
@@ -543,7 +543,7 @@ TransparentSurface *TransparentSurface::rotate(TransformStruct transform) const
targX += transform._hotspot.x;
targY += transform._hotspot.y;
- bilinearCopy(targX, targY, x, y, srcRect, dstRect, this, target);
+ copyPixelBilinear(targX, targY, x, y, srcRect, dstRect, this, target);
}
}
}
@@ -573,7 +573,7 @@ TransparentSurface *TransparentSurface::scale(uint16 newWidth, uint16 newHeight)
for (int x = 0; x < dstW; x++) {
projX = x / dstW * srcW;
projY = y / dstH * srcH;
- nearestCopy(projX, projY, x, y, srcRect, dstRect, this, target);
+ copyPixelNearestNeighbor(projX, projY, x, y, srcRect, dstRect, this, target);
}
}
} else {
@@ -583,7 +583,7 @@ TransparentSurface *TransparentSurface::scale(uint16 newWidth, uint16 newHeight)
for (int x = 0; x < dstW; x++) {
projX = x / (float)dstW * srcW;
projY = y / (float)dstH * srcH;
- bilinearCopy(projX, projY, x, y, srcRect, dstRect, this, target);
+ copyPixelBilinear(projX, projY, x, y, srcRect, dstRect, this, target);
}
}
}
diff --git a/engines/wintermute/graphics/transparent_surface.h b/engines/wintermute/graphics/transparent_surface.h
index 474b10a6f1..f9486d1b25 100644
--- a/engines/wintermute/graphics/transparent_surface.h
+++ b/engines/wintermute/graphics/transparent_surface.h
@@ -53,8 +53,8 @@ struct TransparentSurface : public Graphics::Surface {
void setColorKey(char r, char g, char b);
void disableColorKey();
- static void bilinearCopy(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst);
- static void nearestCopy(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst);
+ static void copyPixelBilinear(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst);
+ static void copyPixelNearestNeighbor(float projX, float projY, int dstX, int dstY, const Common::Rect &srcRect, const Common::Rect &dstRect, const TransparentSurface *src, TransparentSurface *dst);
// Enums
/**