Skip to content

Commit

Permalink
SCI32: Fix signed comparison warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
csnover committed Jul 1, 2016
1 parent 6c8661d commit 948e448
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
8 changes: 4 additions & 4 deletions engines/sci/graphics/frameout.cpp
Expand Up @@ -696,7 +696,7 @@ void GfxFrameout::calcLists(ScreenItemListList &drawLists, EraseListList &eraseL
}

PlaneList::size_type planeCount = _planes.size();
for (int outerPlaneIndex = 0; outerPlaneIndex < planeCount; ++outerPlaneIndex) {
for (PlaneList::size_type outerPlaneIndex = 0; outerPlaneIndex < planeCount; ++outerPlaneIndex) {
const Plane *outerPlane = _planes[outerPlaneIndex];
const Plane *visiblePlane = _visiblePlanes.findByObject(outerPlane->_object);

Expand Down Expand Up @@ -742,7 +742,7 @@ void GfxFrameout::calcLists(ScreenItemListList &drawLists, EraseListList &eraseL
}

if (addedToEraseList) {
for (int rectIndex = 0; rectIndex < eraseList.size(); ++rectIndex) {
for (RectList::size_type rectIndex = 0; rectIndex < eraseList.size(); ++rectIndex) {
const Common::Rect &rect = *eraseList[rectIndex];
for (int innerPlaneIndex = planeCount - 1; innerPlaneIndex >= 0; --innerPlaneIndex) {
const Plane &innerPlane = *_planes[innerPlaneIndex];
Expand Down Expand Up @@ -813,7 +813,7 @@ void GfxFrameout::calcLists(ScreenItemListList &drawLists, EraseListList &eraseL

eraseList.add(outerPlane._screenRect.findIntersectingRect(visibleOuterPlane->_screenRect));

for (PlaneList::size_type innerIndex = planeCount - 1; innerIndex >= 0; --innerIndex) {
for (int innerIndex = (int)planeCount - 1; innerIndex >= 0; --innerIndex) {
// "inner" just refers to the inner loop
const Plane &innerPlane = *_planes[innerIndex];
const Plane *visibleInnerPlane = _visiblePlanes.findByObject(innerPlane._object);
Expand Down Expand Up @@ -903,7 +903,7 @@ void GfxFrameout::calcLists(ScreenItemListList &drawLists, EraseListList &eraseL
}

if (_planes[planeIndex]->_type == kPlaneTypeTransparent) {
for (PlaneList::size_type i = planeIndex - 1; i >= 0; --i) {
for (int i = (int)planeIndex - 1; i >= 0; --i) {
_planes[i]->filterDownEraseRects(drawLists[i], eraseLists[i], eraseLists[planeIndex]);
}

Expand Down
2 changes: 0 additions & 2 deletions engines/sci/graphics/plane32.h
Expand Up @@ -495,8 +495,6 @@ class PlaneList : public PlaneListBase {
using PlaneListBase::push_back;

public:
typedef int size_type;

// A method for finding the index of a plane inside a
// PlaneList is used because entries in the main plane
// list and visible plane list of GfxFrameout are
Expand Down

0 comments on commit 948e448

Please sign in to comment.