bug #740 fix was incomplete; this should finish the width->pitch change
git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@1912 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
@@ -1037,7 +1037,7 @@ Scale_BiAdaptAdvFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
// these macros are for clarity; they make the current pixel (0,0)
|
// these macros are for clarity; they make the current pixel (0,0)
|
||||||
// and allow to access pixels in all directions
|
// and allow to access pixels in all directions
|
||||||
#define PIX(x, y) (pixels[1 + (x)][1 + (y)])
|
#define PIX(x, y) (pixels[1 + (x)][1 + (y)])
|
||||||
#define SRC(x, y) (src_p + (x) + ((y) * w))
|
#define SRC(x, y) (src_p + (x) + ((y) * len))
|
||||||
// commonly used operations, for clarity also
|
// commonly used operations, for clarity also
|
||||||
// others are defined at their respective bpp levels
|
// others are defined at their respective bpp levels
|
||||||
#define BIADAPT_RGBHIGH 8000
|
#define BIADAPT_RGBHIGH 8000
|
||||||
@@ -2439,7 +2439,7 @@ Scale_TriScanFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
// these macros are for clarity; they make the current pixel (0,0)
|
// these macros are for clarity; they make the current pixel (0,0)
|
||||||
// and allow to access pixels in all directions
|
// and allow to access pixels in all directions
|
||||||
#define PIX(x, y) (pixels[1 + (x)][1 + (y)])
|
#define PIX(x, y) (pixels[1 + (x)][1 + (y)])
|
||||||
#define SRC(x, y) (src_p + (x) + ((y) * w))
|
#define SRC(x, y) (src_p + (x) + ((y) * len))
|
||||||
|
|
||||||
#define TRISCAN_YUV_MED 100
|
#define TRISCAN_YUV_MED 100
|
||||||
|
|
||||||
@@ -2939,7 +2939,7 @@ void Scale_BilinearFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
{
|
{
|
||||||
p[0] = src_p[0];
|
p[0] = src_p[0];
|
||||||
if (y < h - 1)
|
if (y < h - 1)
|
||||||
p[2] = src_p[src->w];
|
p[2] = src_p[len];
|
||||||
else
|
else
|
||||||
p[2] = 0;
|
p[2] = 0;
|
||||||
|
|
||||||
@@ -2950,7 +2950,7 @@ void Scale_BilinearFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
if (x < w - 1)
|
if (x < w - 1)
|
||||||
{
|
{
|
||||||
p[1] = src_p[1];
|
p[1] = src_p[1];
|
||||||
p[3] = src_p[src->w + 1];
|
p[3] = src_p[len + 1];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -3007,7 +3007,7 @@ void Scale_BilinearFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
{
|
{
|
||||||
p[0] = GET_PIX_24BIT (src_p);
|
p[0] = GET_PIX_24BIT (src_p);
|
||||||
if (y < h - 1)
|
if (y < h - 1)
|
||||||
p[2] = GET_PIX_24BIT (src_p + src->w);
|
p[2] = GET_PIX_24BIT (src_p + len);
|
||||||
else
|
else
|
||||||
p[2] = 0;
|
p[2] = 0;
|
||||||
|
|
||||||
@@ -3018,7 +3018,7 @@ void Scale_BilinearFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
if (x < w - 1)
|
if (x < w - 1)
|
||||||
{
|
{
|
||||||
p[1] = GET_PIX_24BIT (src_p + 1);
|
p[1] = GET_PIX_24BIT (src_p + 1);
|
||||||
p[3] = GET_PIX_24BIT (src_p + src->w + 1);
|
p[3] = GET_PIX_24BIT (src_p + len + 1);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -3075,7 +3075,7 @@ void Scale_BilinearFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
{
|
{
|
||||||
p[0] = src_p[0];
|
p[0] = src_p[0];
|
||||||
if (y < h - 1)
|
if (y < h - 1)
|
||||||
p[2] = src_p[src->w];
|
p[2] = src_p[len];
|
||||||
else
|
else
|
||||||
p[2] = 0;
|
p[2] = 0;
|
||||||
|
|
||||||
@@ -3086,7 +3086,7 @@ void Scale_BilinearFilter (SDL_Surface *src, SDL_Surface *dst, SDL_Rect *r)
|
|||||||
if (x < w - 1)
|
if (x < w - 1)
|
||||||
{
|
{
|
||||||
p[1] = src_p[1];
|
p[1] = src_p[1];
|
||||||
p[3] = src_p[src->w + 1];
|
p[3] = src_p[len + 1];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user