diff options
author | leandrogracia@chromium.org <leandrogracia@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-12-20 21:00:07 +0000 |
---|---|---|
committer | leandrogracia@chromium.org <leandrogracia@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-12-20 21:00:07 +0000 |
commit | 894e694065ad44881ac07141bb1d0636c046d687 (patch) | |
tree | eec8d2475b6e4ad602556be8d5df06a9888d1f10 /android_webview/public | |
parent | ed7575c8657bc149c2c2ce1c379394c2226d1d31 (diff) | |
download | chromium_src-894e694065ad44881ac07141bb1d0636c046d687.zip chromium_src-894e694065ad44881ac07141bb1d0636c046d687.tar.gz chromium_src-894e694065ad44881ac07141bb1d0636c046d687.tar.bz2 |
[Android WebView] Update and extend the description of AwDrawGLInfo.
BUG=161409
Review URL: https://chromiumcodereview.appspot.com/11411010
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@174234 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'android_webview/public')
-rw-r--r-- | android_webview/public/browser/draw_gl.h | 28 |
1 files changed, 23 insertions, 5 deletions
diff --git a/android_webview/public/browser/draw_gl.h b/android_webview/public/browser/draw_gl.h index 8bea559..441793e 100644 --- a/android_webview/public/browser/draw_gl.h +++ b/android_webview/public/browser/draw_gl.h @@ -11,13 +11,15 @@ extern "C" { // Holds the information required to trigger an OpenGL drawing operation. struct AwDrawGLInfo { - // Input: Tells the Draw function what action to perform. + // Input: tells the draw function what action to perform. enum Mode { kModeDraw, kModeProcess, } mode; - // Input: current clip rect. + // Input: current clip rect in surface coordinates. Reflects the current state + // of the OpenGL scissor rect. Both the OpenGL scissor rect and viewport are + // set by the caller of the draw function and updated during View animations. int clip_left; int clip_top; int clip_right; @@ -27,10 +29,26 @@ struct AwDrawGLInfo { int width; int height; - // Input: is the render target an FBO. + // Input: is the View rendered into an independent layer. + // If false, the surface is likely to hold to the full screen contents, with + // the scissor box set by the caller to the actual View location and size. + // Also the transformation matrix will contain at least a translation to the + // position of the View to render, plus any other transformations required as + // part of any ongoing View animation. View translucency (alpha) is ignored, + // although the framework will set is_layer to true for non-opaque cases. + // Can be requested via the View.setLayerType(View.LAYER_TYPE_NONE, ...) + // Android API method. + // + // If true, the surface is dedicated to the View and should have its size. + // The viewport and scissor box are set by the caller to the whole surface. + // Animation transformations are handled by the caller and not reflected in + // the provided transformation matrix. Translucency works normally. + // Can be requested via the View.setLayerType(View.LAYER_TYPE_HARDWARE, ...) + // Android API method. bool is_layer; - // Input: current transform matrix, in OpenGL format. + // Input: current transformation matrix in surface pixels. + // Uses the column-based OpenGL matrix format. float transform[16]; // Output: tells the caller what to do next. @@ -43,7 +61,7 @@ struct AwDrawGLInfo { // Output: mask indicating the status after calling the functor. unsigned int status_mask; - // Output: dirty region to redraw. + // Output: dirty region to redraw in surface coordinates. float dirty_left; float dirty_top; float dirty_right; |