/frameworks/base/libs/hwui/ |
H A D | Layer.h | 95 const float texX = 1.0f / float(texture.width); 113 return texture.width; 123 * @param width The new width of the layer 129 bool resize(const uint32_t width, const uint32_t height); 131 void setSize(uint32_t width, uint32_t height) { argument 132 texture.width = width;
|
H A D | LayerCache.cpp | 99 Layer* LayerCache::get(RenderState& renderState, const uint32_t width, const uint32_t height) { argument 102 LayerEntry entry(width, height);
|
H A D | LayerRenderer.cpp | 53 const float width = mLayer->layer.getWidth(); local 58 dirty.right >= width && dirty.bottom >= height)) { 60 dirty.set(0.0f, 0.0f, width, height); 62 dirty.intersect(0.0f, 0.0f, width, height); 188 Layer* LayerRenderer::createRenderLayer(RenderState& renderState, uint32_t width, uint32_t height) { argument 189 ATRACE_FORMAT("Allocate %ux%u HW Layer", width, height); 190 LAYER_RENDERER_LOGD("Requesting new render layer %dx%d", width, height); 200 Layer* layer = caches.layerCache.get(renderState, width, height); 212 width, height, maxTextureSize, maxTextureSize); 222 layer->layer.set(0.0f, 0.0f, width, heigh 257 resizeLayer(Layer* layer, uint32_t width, uint32_t height) argument 292 updateTextureLayer(Layer* layer, uint32_t width, uint32_t height, bool isOpaque, bool forceFilter, GLenum renderTarget, float* textureTransform) argument [all...] |
H A D | OpenGLRenderer.cpp | 370 info.width = getViewportWidth(); 1954 drawAlpha8TextureMesh(x, y, x + texture->width, y + texture->height, texture->id, 1994 if (quickRejectSetupScissor(0, 0, bitmap->width(), bitmap->height())) { 2006 drawTextureRect(0, 0, bitmap->width(), bitmap->height(), texture, paint); 2013 if (quickRejectSetupScissor(0, 0, bitmap->width(), bitmap->height())) { 2024 drawTextureRect(0, 0, bitmap->width(), bitmap->height(), texture, paint); 2163 const float width = texture->width; local 2166 float u1 = fmax(0.0f, srcLeft / width); 2168 float u2 = fmin(1.0f, srcRight / width); [all...] |
H A D | Patch.cpp | 51 float width, float height, const Res_png_9patch* patch) { 53 return createMesh(bitmapWidth, bitmapHeight, width, height, mapper, patch); 57 float width, float height, const UvMapper& mapper, const Res_png_9patch* patch) { 102 const float xStretch = fmaxf(width - fixed, 0.0f); 104 rescaleX = fixed == 0.0f ? 0.0f : fminf(fmaxf(width, 0.0f) / fixed, 1.0f); 145 width, bitmapWidth, quadCount); 157 width, bitmapWidth, quadCount); 173 float width, float bitmapWidth, uint32_t& quadCount) { 206 x2 = width; 50 createMesh(const float bitmapWidth, const float bitmapHeight, float width, float height, const Res_png_9patch* patch) argument 56 createMesh(const float bitmapWidth, const float bitmapHeight, float width, float height, const UvMapper& mapper, const Res_png_9patch* patch) argument 171 generateRow(const int32_t* xDivs, uint32_t xCount, TextureVertex*& vertex, float y1, float y2, float v1, float v2, float stretchX, float rescaleX, float width, float bitmapWidth, uint32_t& quadCount) argument
|
H A D | PathCache.cpp | 88 float& left, float& top, float& offset, uint32_t& width, uint32_t& height) { 90 PathCache::computeBounds(bounds, paint, left, top, offset, width, height); 94 float& left, float& top, float& offset, uint32_t& width, uint32_t& height) { 95 const float pathWidth = fmax(bounds.width(), 1.0f); 103 width = uint32_t(pathWidth + offset * 2.0 + 0.5); 107 static void initBitmap(SkBitmap& bitmap, uint32_t width, uint32_t height) { argument 108 bitmap.allocPixels(SkImageInfo::MakeA8(width, height)); 125 float left, float top, float offset, uint32_t width, uint32_t height) { 126 initBitmap(bitmap, width, height); 137 uint32_t width, uint32_ 87 computePathBounds(const SkPath* path, const SkPaint* paint, float& left, float& top, float& offset, uint32_t& width, uint32_t& height) argument 93 computeBounds(const SkRect& bounds, const SkPaint* paint, float& left, float& top, float& offset, uint32_t& width, uint32_t& height) argument 124 drawPath(const SkPath *path, const SkPaint* paint, SkBitmap& bitmap, float left, float top, float offset, uint32_t width, uint32_t height) argument 136 createTexture(float left, float top, float offset, uint32_t width, uint32_t height, uint32_t id) argument 240 purgeCache(uint32_t width, uint32_t height) argument 261 uint32_t width, height; local 341 uint32_t width, height; local 504 getRoundRect(float width, float height, float rx, float ry, const SkPaint* paint) argument 550 getOval(float width, float height, const SkPaint* paint) argument 573 getRect(float width, float height, const SkPaint* paint) argument 596 getArc(float width, float height, float startAngle, float sweepAngle, bool useCenter, const SkPaint* paint) argument [all...] |
H A D | PathCache.h | 189 PathTexture* getRoundRect(float width, float height, float rx, float ry, const SkPaint* paint); 191 PathTexture* getOval(float width, float height, const SkPaint* paint); 192 PathTexture* getRect(float width, float height, const SkPaint* paint); 193 PathTexture* getArc(float width, float height, float startAngle, float sweepAngle, 225 float& left, float& top, float& offset, uint32_t& width, uint32_t& height); 227 float& left, float& top, float& offset, uint32_t& width, uint32_t& height); 257 void purgeCache(uint32_t width, uint32_t height); 261 bool checkTextureSize(uint32_t width, uint32_t height) { argument 262 if (width > mMaxTextureSize || height > mMaxTextureSize) { 264 width, heigh [all...] |
H A D | PixelBuffer.cpp | 36 CpuPixelBuffer(GLenum format, uint32_t width, uint32_t height); 44 void upload(uint32_t x, uint32_t y, uint32_t width, uint32_t height, int offset); 50 CpuPixelBuffer::CpuPixelBuffer(GLenum format, uint32_t width, uint32_t height): argument 51 PixelBuffer(format, width, height) { 52 mBuffer = new uint8_t[width * height * formatSize(format)]; 74 void CpuPixelBuffer::upload(uint32_t x, uint32_t y, uint32_t width, uint32_t height, int offset) { argument 75 glTexSubImage2D(GL_TEXTURE_2D, 0, x, y, width, height, 85 GpuPixelBuffer(GLenum format, uint32_t width, uint32_t height); 93 void upload(uint32_t x, uint32_t y, uint32_t width, uint32_t height, int offset); 101 GpuPixelBuffer::GpuPixelBuffer(GLenum format, uint32_t width, uint32_ argument 149 upload(uint32_t x, uint32_t y, uint32_t width, uint32_t height, int offset) argument 161 create(GLenum format, uint32_t width, uint32_t height, BufferType type) argument [all...] |
H A D | PixelBuffer.h | 66 static PixelBuffer* create(GLenum format, uint32_t width, uint32_t height, 119 virtual void upload(uint32_t x, uint32_t y, uint32_t width, uint32_t height, int offset) = 0; 129 void upload(uint32_t x, uint32_t y, uint32_t width, uint32_t height) { argument 130 upload(x, y, width, height, getOffset(x, y)); 134 * Returns the width of the render buffer in pixels. 202 PixelBuffer(GLenum format, uint32_t width, uint32_t height): argument 203 mFormat(format), mWidth(width), mHeight(height), mAccessMode(kAccessMode_None) {
|
H A D | Rect.h | 67 inline Rect(float width, float height): argument 70 right(width),
|
H A D | RenderBuffer.h | 35 RenderBuffer(GLenum format, uint32_t width, uint32_t height): argument 36 mFormat(format), mWidth(width), mHeight(height), mAllocated(false) { 92 void resize(uint32_t width, uint32_t height) { argument 93 if (isAllocated() && (width != mWidth || height != mHeight)) { 94 glRenderbufferStorage(GL_RENDERBUFFER, mFormat, width, height); 97 mWidth = width; 102 * Returns the width of the render buffer in pixels.
|
H A D | RenderBufferCache.cpp | 110 RenderBuffer* RenderBufferCache::get(GLenum format, const uint32_t width, const uint32_t height) { argument 113 RenderBufferEntry entry(format, width, height); 124 RenderBuffer::formatName(format), width, height); 126 buffer = new RenderBuffer(format, width, height); 129 RenderBuffer::formatName(format), width, height);
|
H A D | RenderBufferCache.h | 45 * @param width The desired width of the buffer 48 RenderBuffer* get(GLenum format, const uint32_t width, const uint32_t height); 84 RenderBufferEntry(GLenum format, const uint32_t width, const uint32_t height): argument 85 mBuffer(NULL), mFormat(format), mWidth(width), mHeight(height) {
|
H A D | RenderState.cpp | 84 void RenderState::setViewport(GLsizei width, GLsizei height) { argument 85 mViewportWidth = width;
|
H A D | SkiaShader.cpp | 180 const float width = layer->getWidth(); local 197 glUniform2f(program->getUniform("textureDimension"), 1.0f / width, 1.0f / height); 205 float width; member in struct:android::uirenderer::BitmapShaderInfo 219 const float width = texture->width; local 228 if (!extensions.hasNPot() && (!isPowerOfTwo(width) || !isPowerOfTwo(height)) && 244 shaderInfo->width = width; 295 glUniform2f(program->getUniform("textureDimension"), 1.0f / shaderInfo.width,
|
H A D | Snapshot.h | 157 void initializeViewport(int width, int height) { argument 158 mViewportData.initialize(width, height); 282 void initialize(int width, int height) { argument 283 mWidth = width; 285 mOrthoMatrix.loadOrtho(0, width, height, 0, -1, 1); 291 * The viewport is always defined to be (0, 0, width, height).
|
H A D | StatefulBaseRenderer.cpp | 47 void StatefulBaseRenderer::setViewport(int width, int height) { argument 48 mWidth = width; 50 mFirstSnapshot->initializeViewport(width, height);
|
H A D | TessellationCache.cpp | 445 SkRect rect = SkRect::MakeWH(description.shape.roundRect.width, 462 float width, float height, float rx, float ry) { 464 entry.shape.roundRect.width = width; 471 float width, float height, float rx, float ry) { 472 return getRoundRectBuffer(transform, paint, width, height, rx, ry)->getVertexBuffer(); 460 getRoundRectBuffer( const Matrix4& transform, const SkPaint& paint, float width, float height, float rx, float ry) argument 470 getRoundRect(const Matrix4& transform, const SkPaint& paint, float width, float height, float rx, float ry) argument
|
H A D | TessellationCache.h | 64 float width; member in struct:android::uirenderer::TessellationCache::Description::Shape::RoundRect 125 float width, float height, float rx, float ry) { 126 getRoundRectBuffer(transform, paint, width, height, rx, ry); 129 float width, float height, float rx, float ry); 150 float width, float height); 152 float width, float height, float rx, float ry); 124 precacheRoundRect(const Matrix4& transform, const SkPaint& paint, float width, float height, float rx, float ry) argument
|
H A D | Texture.h | 74 uint32_t width; member in class:android::uirenderer::Texture
|
H A D | TextureCache.cpp | 140 if (bitmap->width() > mMaxTextureSize || bitmap->height() > mMaxTextureSize) { 142 bitmap->width(), bitmap->height(), mMaxTextureSize, mMaxTextureSize); 280 ATRACE_FORMAT("Upload %ux%u Texture", bitmap->width(), bitmap->height()); 288 const bool resize = !regenerate || bitmap->width() != int(texture->width) || 297 texture->width = bitmap->width(); 306 texture->width, texture->height, GL_UNSIGNED_BYTE, bitmap->getPixels()); 312 texture->width, texture->height, GL_UNSIGNED_SHORT_5_6_5, bitmap->getPixels()); 318 texture->width, textur 347 uploadLoFiTexture(bool resize, const SkBitmap* bitmap, uint32_t width, uint32_t height) argument 360 uploadToTexture(bool resize, GLenum format, GLsizei stride, GLsizei bpp, GLsizei width, GLsizei height, GLenum type, const GLvoid * data) argument [all...] |
/frameworks/base/libs/hwui/font/ |
H A D | CacheTexture.cpp | 33 * Insert new block into existing linked list of blocks. Blocks are sorted in increasing-width 111 CacheTexture::CacheTexture(uint16_t width, uint16_t height, GLenum format, uint32_t maxQuadCount) : argument 112 mTexture(NULL), mTextureId(0), mWidth(width), mHeight(height), mFormat(format), 211 uint32_t width = mHasUnpackRowLength ? dirtyRect.getWidth() : mWidth; local 220 mTexture->upload(x, y, width, height); 277 // or it's within ROUNDING_SIZE of the block width 282 // Only enough space for this glyph - don't bother rounding up the width
|
H A D | CacheTexture.h | 41 * horizontally, and if its width is sufficiently close to the column width to avoid 57 CacheBlock(uint16_t x, uint16_t y, uint16_t width, uint16_t height): argument 58 mX(x), mY(y), mWidth(width), mHeight(height), mNext(NULL), mPrev(NULL) { 77 CacheTexture(uint16_t width, uint16_t height, GLenum format, uint32_t maxQuadCount);
|
H A D | Font.cpp | 143 int width = (int) glyph->mBitmapWidth; local 155 if (bounds->right < nPenX + width) { 156 bounds->right = nPenX + width; 165 float width = (float) glyph->mBitmapWidth; local 177 nPenX + width, nPenY, u2, v2, 178 nPenX + width, nPenY - height, u2, v1, 184 float width = (float) glyph->mBitmapWidth; local 189 p[1].iset(glyph->mBitmapLeft + width, glyph->mBitmapTop + height); 190 p[2].iset(glyph->mBitmapLeft + width, glyph->mBitmapTop);
|
/frameworks/base/libs/hwui/renderthread/ |
H A D | CanvasContext.cpp | 131 void CanvasContext::setup(int width, int height, const Vector3& lightCenter, float lightRadius, argument 211 EGLint width, height; local 212 mEglManager.beginFrame(mEglSurface, &width, &height); 213 if (width != mCanvas->getViewportWidth() || height != mCanvas->getViewportHeight()) { 214 mCanvas->setViewport(width, height); 219 if (!dirty.isEmpty() && !dirty.intersect(0, 0, width, height)) { 221 SK_RECT_ARGS(dirty), width, height);
|