summaryrefslogtreecommitdiffstats
path: root/content
diff options
context:
space:
mode:
authorilevy@chromium.org <ilevy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-17 06:40:50 +0000
committerilevy@chromium.org <ilevy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-17 06:40:50 +0000
commit3543975945a5667aa3fb48c6d0e1b6312d1ed293 (patch)
treea6ea1e1c640c6e9121a4e2ef066e1f235868099e /content
parent88b2f1aa74e8fe0b4413a4f807681fd427071184 (diff)
downloadchromium_src-3543975945a5667aa3fb48c6d0e1b6312d1ed293.zip
chromium_src-3543975945a5667aa3fb48c6d0e1b6312d1ed293.tar.gz
chromium_src-3543975945a5667aa3fb48c6d0e1b6312d1ed293.tar.bz2
Revert 177288
> cc: Add point-based UV coordinate on TextureLayer > > Previously, the uv coordinates was using gfx::RectF as a struct. > This was limitating because it could not handle negative width > and heights. Soring them as 2 gfx::PointF for the Top-Left and > Bottom-Right points aleviate that restriction. > The current implementation of the phone UI rely on this feature. > > BUG=168927 > > Review URL: https://chromiumcodereview.appspot.com/11783094 This is breaking the android internal chrome build, we need green for a release cut later tonight. Let's reland tomorrow with the corresponding downstream fix. TBR=jscholler@chromium.org Review URL: https://codereview.chromium.org/11959026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@177360 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r--content/common/cc_messages.h3
-rw-r--r--content/common/cc_messages_unittest.cc3
-rw-r--r--content/renderer/browser_plugin/browser_plugin_compositing_helper.cc2
3 files changed, 3 insertions, 5 deletions
diff --git a/content/common/cc_messages.h b/content/common/cc_messages.h
index d0d1da6..1a7bcc0 100644
--- a/content/common/cc_messages.h
+++ b/content/common/cc_messages.h
@@ -176,8 +176,7 @@ IPC_STRUCT_TRAITS_BEGIN(cc::TextureDrawQuad)
IPC_STRUCT_TRAITS_PARENT(cc::DrawQuad)
IPC_STRUCT_TRAITS_MEMBER(resource_id)
IPC_STRUCT_TRAITS_MEMBER(premultiplied_alpha)
- IPC_STRUCT_TRAITS_MEMBER(uv_top_left)
- IPC_STRUCT_TRAITS_MEMBER(uv_bottom_right)
+ IPC_STRUCT_TRAITS_MEMBER(uv_rect)
IPC_STRUCT_TRAITS_MEMBER(flipped)
IPC_STRUCT_TRAITS_END()
diff --git a/content/common/cc_messages_unittest.cc b/content/common/cc_messages_unittest.cc
index efa840d..7261439 100644
--- a/content/common/cc_messages_unittest.cc
+++ b/content/common/cc_messages_unittest.cc
@@ -144,8 +144,7 @@ class CCMessagesTest : public testing::Test {
void Compare(const TextureDrawQuad* a, const TextureDrawQuad* b) {
EXPECT_EQ(a->resource_id, b->resource_id);
EXPECT_EQ(a->premultiplied_alpha, b->premultiplied_alpha);
- EXPECT_EQ(a->uv_top_left, b->uv_top_left);
- EXPECT_EQ(a->uv_bottom_right, b->uv_bottom_right);
+ EXPECT_EQ(a->uv_rect, b->uv_rect);
EXPECT_EQ(a->flipped, b->flipped);
}
diff --git a/content/renderer/browser_plugin/browser_plugin_compositing_helper.cc b/content/renderer/browser_plugin/browser_plugin_compositing_helper.cc
index df54f1a..dd7d84f 100644
--- a/content/renderer/browser_plugin/browser_plugin_compositing_helper.cc
+++ b/content/renderer/browser_plugin/browser_plugin_compositing_helper.cc
@@ -94,7 +94,7 @@ void BrowserPluginCompositingHelper::UpdateUVRect() {
uv_rect.set_height(static_cast<float>(container_size_.height()) /
static_cast<float>(buffer_size_.height()));
}
- texture_layer_->setUV(uv_rect.origin(), uv_rect.bottom_right());
+ texture_layer_->setUVRect(uv_rect);
}
} // namespace content