Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(850)

Unified Diff: gpu/ipc/service/direct_composition_surface_win_unittest.cc

Issue 2849743002: Allow binding multiple textures to one DC Layer overlay. (Closed)
Patch Set: put texture id array in ScheduleDCLayer Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gpu/ipc/service/direct_composition_surface_win.cc ('k') | ui/gl/dc_renderer_layer_params.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/ipc/service/direct_composition_surface_win_unittest.cc
diff --git a/gpu/ipc/service/direct_composition_surface_win_unittest.cc b/gpu/ipc/service/direct_composition_surface_win_unittest.cc
index 8e6485b795231dcf49ad16077b32e29be14485ae..9837c021b57f2e792c13ee60ef67040bfdd60e59 100644
--- a/gpu/ipc/service/direct_composition_surface_win_unittest.cc
+++ b/gpu/ipc/service/direct_composition_surface_win_unittest.cc
@@ -309,10 +309,11 @@ TEST(DirectCompositionSurfaceTest, NoPresentTwice) {
new gl::GLImageDXGI(texture_size, nullptr));
image_dxgi->SetTexture(texture, 0);
- ui::DCRendererLayerParams params(false, gfx::Rect(), 1, gfx::Transform(),
- image_dxgi.get(),
- gfx::RectF(gfx::Rect(texture_size)),
- gfx::Rect(window_size), 0, 0, 1.0, 0);
+ ui::DCRendererLayerParams params(
+ false, gfx::Rect(), 1, gfx::Transform(),
+ std::vector<scoped_refptr<gl::GLImage>>{image_dxgi},
+ gfx::RectF(gfx::Rect(texture_size)), gfx::Rect(window_size), 0, 0, 1.0,
+ 0);
surface->ScheduleDCLayer(params);
base::win::ScopedComPtr<IDXGISwapChain1> swap_chain =
@@ -343,10 +344,11 @@ TEST(DirectCompositionSurfaceTest, NoPresentTwice) {
EXPECT_EQ(2u, last_present_count);
// The size of the swapchain changed, so it should be recreated.
- ui::DCRendererLayerParams params2(false, gfx::Rect(), 1, gfx::Transform(),
- image_dxgi.get(),
- gfx::RectF(gfx::Rect(texture_size)),
- gfx::Rect(0, 0, 25, 25), 0, 0, 1.0, 0);
+ ui::DCRendererLayerParams params2(
+ false, gfx::Rect(), 1, gfx::Transform(),
+ std::vector<scoped_refptr<gl::GLImage>>{image_dxgi},
+ gfx::RectF(gfx::Rect(texture_size)), gfx::Rect(0, 0, 25, 25), 0, 0, 1.0,
+ 0);
surface->ScheduleDCLayer(params2);
EXPECT_EQ(gfx::SwapResult::SWAP_ACK, surface->SwapBuffers());
@@ -483,10 +485,11 @@ TEST_F(DirectCompositionPixelTest, VideoSwapchain) {
new gl::GLImageDXGI(texture_size, nullptr));
image_dxgi->SetTexture(texture, 0);
- ui::DCRendererLayerParams params(false, gfx::Rect(), 1, gfx::Transform(),
- image_dxgi.get(),
- gfx::RectF(gfx::Rect(texture_size)),
- gfx::Rect(window_size), 0, 0, 1.0, 0);
+ ui::DCRendererLayerParams params(
+ false, gfx::Rect(), 1, gfx::Transform(),
+ std::vector<scoped_refptr<gl::GLImage>>{image_dxgi},
+ gfx::RectF(gfx::Rect(texture_size)), gfx::Rect(window_size), 0, 0, 1.0,
+ 0);
surface_->ScheduleDCLayer(params);
EXPECT_EQ(gfx::SwapResult::SWAP_ACK, surface_->SwapBuffers());
« no previous file with comments | « gpu/ipc/service/direct_composition_surface_win.cc ('k') | ui/gl/dc_renderer_layer_params.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698