Merge revision 643 and revision 648 changes:

- Improve the cefclient transparency test by adding the ability to view individual pixel values (issue #584).
- Change cefclient off-screen rendering example to account for premultiplied alpha values (issue #584).

git-svn-id: https://chromiumembedded.googlecode.com/svn/branches/1025@649 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2012-05-25 14:33:01 +00:00
parent 2bd2007fb9
commit 0bccf1bff2
5 changed files with 86 additions and 11 deletions

View File

@@ -40,6 +40,13 @@ class ClientOSRenderer {
void SetSpin(float spinX, float spinY);
void IncrementSpin(float spinDX, float spinDY);
// Retrieve the pixel value from the view buffer. |x| and |y| are relative to
// the upper-left corner of the view.
bool GetPixelValue(int x, int y, unsigned char& r, unsigned char& g,
unsigned char& b, unsigned char& a);
bool IsTransparent() { return transparent_; }
private:
void SetBufferSize(int width, int height, bool view);
void SetRGBA(const void* src, int width, int height, bool view);