pixblock-transform.cpp revision 444eb57880794d9aaa75ab6fc0a584dbe60662b9
#define __NR_PIXBLOCK_SCALER_CPP__
/*
* Functions for blitting pixblocks using matrix transformation
*
* Author:
* Niko Kiirala <niko@kiirala.com>
*
* Copyright (C) 2006 Niko Kiirala
*
* Released under GNU GPL, read the file 'COPYING' for more information
*/
#include <glib.h>
#include <cmath>
#include "round.h"
#include "libnr/nr-pixblock.h"
#include "libnr/nr-matrix.h"
namespace NR {
struct RGBA {
int r, g, b, a;
};
/**
* Sanity check function for indexing pixblocks.
* Catches reading and writing outside the pixblock area.
* When enabled, decreases filter rendering speed massively.
*/
{
if(false) {
}
}
{
g_warning("A non-32-bpp image passed to transform_nearest: scaling aborted.");
return;
}
// Precalculate sizes of source and destination pixblocks
// Loop through every pixel of destination image, a line at a time
+ itrans[4]);
+ itrans[5]);
}
}
}
}
} /* namespace NR */
/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :