diff options
author | Jamie Gennis <jgennis@google.com> | 2011-11-04 14:24:55 -0700 |
---|---|---|
committer | Jamie Gennis <jgennis@google.com> | 2011-11-04 14:24:55 -0700 |
commit | 2aafe742e5d2d63d77c49df032ec580966661597 (patch) | |
tree | 0156b2ef25b0368623d86b71b259b0d2ee8fe182 /graphics | |
parent | 62015f5d0d1104dfc682b3eb3b6c0be4f63b985a (diff) | |
download | frameworks_base-2aafe742e5d2d63d77c49df032ec580966661597.zip frameworks_base-2aafe742e5d2d63d77c49df032ec580966661597.tar.gz frameworks_base-2aafe742e5d2d63d77c49df032ec580966661597.tar.bz2 |
SurfaceTexture: unhide setDefaultBufferSize
Change-Id: Ia4d3e1829339acaecaa7f10023945a432c581d72
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/java/android/graphics/SurfaceTexture.java | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/graphics/java/android/graphics/SurfaceTexture.java b/graphics/java/android/graphics/SurfaceTexture.java index f3b62ec..29fab11 100644 --- a/graphics/java/android/graphics/SurfaceTexture.java +++ b/graphics/java/android/graphics/SurfaceTexture.java @@ -130,10 +130,17 @@ public class SurfaceTexture { } /** - * Set the size of buffers returned by requestBuffers when a width and height - * of zero is requested. + * Set the default size of the image buffers. The image producer may override the buffer size, + * in which case the producer-set buffer size will be used, not the default size set by this + * method. Both video and camera based image producers do override the size. This method may + * be used to set the image size when producing images with {@link android.graphics.Canvas} (via + * {@link android.view.Surface#lockCanvas}), or OpenGL ES (via an EGLSurface). * - * @hide Pending approval by API council. + * The new default buffer size will take effect the next time the image producer requests a + * buffer to fill. For {@link android.graphics.Canvas} this will be the next time {@link + * android.view.Surface#lockCanvas} is called. For OpenGL ES, the EGLSurface should be + * destroyed (via eglDestroySurface), made not-current (via eglMakeCurrent), and then recreated + * (via eglCreateWindowSurface) to ensure that the new default size has taken effect. */ public void setDefaultBufferSize(int width, int height) { nativeSetDefaultBufferSize(width, height); |