Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(94)

Unified Diff: src/core/SkBitmapProcState.h

Issue 19335002: Production quality fast image up/downsampler (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: avoid using any #defines related to SSE by incorporating padding into the function pointer structure Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/core/SkBitmapProcState.h
diff --git a/src/core/SkBitmapProcState.h b/src/core/SkBitmapProcState.h
index a644dd1e021c3453c2144bbc1aa203e48ff9176d..51d28828973f2903e12988d3ed812bd41a7e1016 100644
--- a/src/core/SkBitmapProcState.h
+++ b/src/core/SkBitmapProcState.h
@@ -59,7 +59,7 @@ struct SkBitmapProcState {
const uint32_t[],
int count,
uint16_t colors[]);
-
+
typedef U16CPU (*FixedTileProc)(SkFixed); // returns 0..0xFFFF
typedef U16CPU (*FixedTileLowBitsProc)(SkFixed, int); // returns 0..0xF
typedef U16CPU (*IntTileProc)(int value, int count); // returns 0..count-1
@@ -78,6 +78,8 @@ struct SkBitmapProcState {
IntTileProc fIntTileProcY; // chooseProcs
SkFixed fFilterOneX;
SkFixed fFilterOneY;
+
+ SkConvolutionProcs* fConvolutionProcs; // possiblyScaleImage
SkPMColor fPaintPMColor; // chooseProcs - A8 config
SkFixed fInvSx; // chooseProcs
@@ -113,7 +115,12 @@ struct SkBitmapProcState {
implementation can do nothing (see SkBitmapProcState_opts_none.cpp)
*/
void platformProcs();
-
+
+ /** Platforms can also optionally overwrite the convolution functions
+ if we have SIMD versions of them.
+ */
+
+ void platformConvolutionProcs();
/** Given the byte size of the index buffer to be passed to the matrix proc,
return the maximum number of resulting pixels that can be computed
@@ -218,8 +225,6 @@ void ClampX_ClampY_nofilter_affine(const SkBitmapProcState& s,
void S32_D16_filter_DX(const SkBitmapProcState& s,
const uint32_t* xy, int count, uint16_t* colors);
-void highQualityFilter_ScaleOnly(const SkBitmapProcState &s, int x, int y,
- SkPMColor *SK_RESTRICT colors, int count);
void highQualityFilter(const SkBitmapProcState &s, int x, int y,
SkPMColor *SK_RESTRICT colors, int count);

Powered by Google App Engine
This is Rietveld 408576698