aboutsummaryrefslogtreecommitdiff
path: root/graphics/VectorRenderer.cpp
diff options
context:
space:
mode:
authorVicent Marti2008-05-05 22:21:34 +0000
committerVicent Marti2008-05-05 22:21:34 +0000
commit8209ab0b7b5f258205eae77d05bac326211fe497 (patch)
tree168f4779c6355389b54a175e4caa1cc252442653 /graphics/VectorRenderer.cpp
parent4ada388fb8a304edec515de3883182d9a744b3fd (diff)
downloadscummvm-rg350-8209ab0b7b5f258205eae77d05bac326211fe497.tar.gz
scummvm-rg350-8209ab0b7b5f258205eae77d05bac326211fe497.tar.bz2
scummvm-rg350-8209ab0b7b5f258205eae77d05bac326211fe497.zip
Fixes for GCC 4.0.2+ in strict mode. Max, is it working now?
svn-id: r31885
Diffstat (limited to 'graphics/VectorRenderer.cpp')
-rw-r--r--graphics/VectorRenderer.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/graphics/VectorRenderer.cpp b/graphics/VectorRenderer.cpp
index ed6eaff376..0da5d7568d 100644
--- a/graphics/VectorRenderer.cpp
+++ b/graphics/VectorRenderer.cpp
@@ -77,7 +77,7 @@ void VectorRendererSpec<PixelType, PixelFormat>::
drawSquare(int x, int y, int w, int h, bool fill) {
if ( fill ) {
PixelType *ptr = (PixelType *)_activeSurface->getBasePtr(x, y);
- int pitch = surfacePitch();
+ int pitch = Base::surfacePitch();
while (h--) {
Common::set_to(ptr, ptr + w, (PixelType)_color);
@@ -95,7 +95,7 @@ template<typename PixelType, typename PixelFormat>
void VectorRendererSpec<PixelType,PixelFormat>::
drawLineAlg(int x1, int y1, int x2, int y2, int dx, int dy) {
PixelType *ptr = (PixelType *)_activeSurface->getBasePtr(x1, y1);
- int pitch = surfacePitch();
+ int pitch = Base::surfacePitch();
int xdir = (x2 > x1) ? 1 : -1;
*ptr = (PixelType)_color;
@@ -226,7 +226,7 @@ drawLine(int x1, int y1, int x2, int y2) {
return;
PixelType *ptr = (PixelType *)_activeSurface->getBasePtr(x1, y1);
- int pitch = surfacePitch();
+ int pitch = Base::surfacePitch();
if (dy == 0) { // horizontal lines
// these can be filled really fast with a single memset.
@@ -319,22 +319,22 @@ void VectorRendererAA<PixelType, PixelFormat>::
drawCircleAlg(int x1, int y1, int r) {
int x = r;
int y = 0;
- int p = surfacePitch(), px = 0, py = 0;
+ int p = Base::surfacePitch(), px = 0, py = 0;
uint32 rsq = (r * r) << 16;
uint32 T = 0, oldT;
uint8 a1, a2;
bool fill = false;
- PixelType *ptr = (PixelType *)_activeSurface->getBasePtr(x1, y1);
+ PixelType *ptr = (PixelType *)Base::_activeSurface->getBasePtr(x1, y1);
px = p*x;
py = p*y;
- *(ptr + x) = (PixelType)_color;
- *(ptr - x) = (PixelType)_color;
- *(ptr + px) = (PixelType)_color;
- *(ptr - px) = (PixelType)_color;
+ *(ptr + x) = (PixelType)Base::_color;
+ *(ptr - x) = (PixelType)Base::_color;
+ *(ptr + px) = (PixelType)Base::_color;
+ *(ptr - px) = (PixelType)Base::_color;
- if (fill) Common::set_to( ptr - x, ptr + x, _color );
+ if (fill) Common::set_to(ptr - x, ptr + x, Base::_color);
while (x > y++)
{
@@ -352,10 +352,10 @@ drawCircleAlg(int x1, int y1, int r) {
a1 = ~a2;
if (fill) {
- Common::set_to( ptr - x + py, ptr + x + py, _color );
- Common::set_to( ptr - x - py, ptr + x - py, _color );
- Common::set_to( ptr - y + px, ptr + y + px, _color );
- Common::set_to( ptr - y - px, ptr + y - px, _color );
+ Common::set_to(ptr - x + py, ptr + x + py, Base::_color);
+ Common::set_to(ptr - x - py, ptr + x - py, Base::_color);
+ Common::set_to(ptr - y + px, ptr + y + px, Base::_color);
+ Common::set_to(ptr - y - px, ptr + y - px, Base::_color);
} else {
blendPixelPtr(ptr + x - 1 + py, a2);
blendPixelPtr(ptr + y - (px-p), a2);