File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 9393 * been invoked.) It is therefore highly recommended you use a listener to
9494 * be notified when the SurfaceTexture becomes available.</p>
9595 *
96+ * <p>It is important to note that only one producer can use the TextureView.
97+ * For instance, if you use a TextureView to display the camera preview, you
98+ * cannot use {@link #lockCanvas()} to draw onto the TextureView at the same
99+ * time.</p>
100+ *
96101 * @see SurfaceView
97102 * @see SurfaceTexture
98103 */
@@ -523,6 +528,10 @@ public boolean isAvailable() {
523528 * rectangle is specified, in which case, non-dirty pixels will be
524529 * preserved.</p>
525530 *
531+ * <p>This method can only be used if the underlying surface is not already
532+ * owned by another producer. For instance, if the TextureView is being used
533+ * to render the camera's preview you cannot invoke this method.</p>
534+ *
526535 * @return A Canvas used to draw into the surface.
527536 *
528537 * @see #lockCanvas(android.graphics.Rect)
You can’t perform that action at this time.
0 commit comments