Lines Matching defs:scale

98 static void scaleDivRange(int32_t* divs, int count, float scale, int maxValue) {
100 divs[i] = int32_t(divs[i] * scale + 0.5f);
122 static void scaleNinePatchChunk(android::Res_png_9patch* chunk, float scale,
124 chunk->paddingLeft = int(chunk->paddingLeft * scale + 0.5f);
125 chunk->paddingTop = int(chunk->paddingTop * scale + 0.5f);
126 chunk->paddingRight = int(chunk->paddingRight * scale + 0.5f);
127 chunk->paddingBottom = int(chunk->paddingBottom * scale + 0.5f);
129 scaleDivRange(chunk->getXDivs(), chunk->numXDivs, scale, scaledWidth);
130 scaleDivRange(chunk->getYDivs(), chunk->numYDivs, scale, scaledHeight);
146 ScaleCheckingAllocator(float scale, int size)
147 : mScale(scale), mSize(size) {
151 // accounts for scale in final allocation, using eventual size and config
213 // Necessary for decodes when the native decoder cannot scale to appropriately match the sampleSize
215 // scale matches exactly. If sampleSize does not divide evenly, we allow the decoder to choose how
246 float scale = 1.0f;
285 scale = (float) targetDensity / density;
344 if (willScale || scale != 1.0f) {
365 if (scale != 1.0f) {
367 scaledWidth = static_cast<int>(scaledWidth * scale + 0.5f);
368 scaledHeight = static_cast<int>(scaledHeight * scale + 0.5f);
386 ScaleCheckingAllocator scaleCheckingAllocator(scale, existingBufferSize);
398 // for scale case: there will be an extra scaling step.
474 scaleNinePatchChunk(peeker.mPatch, scale, scaledWidth, scaledHeight);
499 peeker.mOutlineRadius, peeker.mOutlineAlpha, scale);
510 // This is weird so let me explain: we could use the scale parameter
513 // The result is slightly different from simply using scale because of
547 canvas.scale(sx, sy);