GRAPHICS,SDL: Change oldSrcScale api

More bookkeeping is kept in common scaler code instead of the backend.
Plugins inheriting SourceScaler will have this functionality.

TODO: Some new functions may still be able to be combined to simplify
the API.
This commit is contained in:
Eric Culp 2012-07-16 18:24:57 -04:00 committed by Filippos Karapetis
parent c915efa452
commit c5c5662330
7 changed files with 127 additions and 55 deletions

View file

@ -3561,8 +3561,8 @@ void EdgePlugin::scale(const uint8 *srcPtr, uint32 srcPitch,
}
}
void EdgePlugin::oldSrcScale(const uint8 *srcPtr, uint32 srcPitch,
uint8 *dstPtr, uint32 dstPitch, const uint8 *oldSrcPtr, uint32 oldSrcPitch, int width, int height, int x, int y) {
void EdgePlugin::internScale(const uint8 *srcPtr, uint32 srcPitch,
uint8 *dstPtr, uint32 dstPitch, const uint8 *oldSrcPtr, uint32 oldSrcPitch, int width, int height) {
if (_format.bytesPerPixel == 2) {
if (_factor == 2) {
if (_format.gLoss == 2)