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

Side by Side Diff: gpu/command_buffer/client/gles2_implementation_unittest.cc

Issue 23130004: Enforce a memory limit on MappedMemoryManager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix another namespace error Created 7 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Tests for GLES2Implementation. 5 // Tests for GLES2Implementation.
6 6
7 #include "gpu/command_buffer/client/gles2_implementation.h" 7 #include "gpu/command_buffer/client/gles2_implementation.h"
8 8
9 #include <GLES2/gl2ext.h> 9 #include <GLES2/gl2ext.h>
10 #include <GLES2/gl2extchromium.h> 10 #include <GLES2/gl2extchromium.h>
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 400
401 gl_.reset(new GLES2Implementation( 401 gl_.reset(new GLES2Implementation(
402 helper_.get(), 402 helper_.get(),
403 NULL, 403 NULL,
404 transfer_buffer_.get(), 404 transfer_buffer_.get(),
405 bind_generates_resource, 405 bind_generates_resource,
406 gpu_control_.get())); 406 gpu_control_.get()));
407 ASSERT_TRUE(gl_->Initialize( 407 ASSERT_TRUE(gl_->Initialize(
408 kTransferBufferSize, 408 kTransferBufferSize,
409 kTransferBufferSize, 409 kTransferBufferSize,
410 kTransferBufferSize)); 410 kTransferBufferSize,
411 GLES2Implementation::kNoLimit));
411 } 412 }
412 413
413 EXPECT_CALL(*command_buffer(), OnFlush()) 414 EXPECT_CALL(*command_buffer(), OnFlush())
414 .Times(1) 415 .Times(1)
415 .RetiresOnSaturation(); 416 .RetiresOnSaturation();
416 helper_->CommandBufferHelper::Finish(); 417 helper_->CommandBufferHelper::Finish();
417 ::testing::Mock::VerifyAndClearExpectations(gl_.get()); 418 ::testing::Mock::VerifyAndClearExpectations(gl_.get());
418 419
419 Buffer ring_buffer = helper_->get_ring_buffer(); 420 Buffer ring_buffer = helper_->get_ring_buffer();
420 commands_ = static_cast<CommandBufferEntry*>(ring_buffer.ptr) + 421 commands_ = static_cast<CommandBufferEntry*>(ring_buffer.ptr) +
(...skipping 2450 matching lines...) Expand 10 before | Expand all | Expand 10 after
2871 ClearCommands(); 2872 ClearCommands();
2872 gl_->Enable(GL_BLEND); 2873 gl_->Enable(GL_BLEND);
2873 EXPECT_TRUE(NoCommandsWritten()); 2874 EXPECT_TRUE(NoCommandsWritten());
2874 } 2875 }
2875 2876
2876 2877
2877 #include "gpu/command_buffer/client/gles2_implementation_unittest_autogen.h" 2878 #include "gpu/command_buffer/client/gles2_implementation_unittest_autogen.h"
2878 2879
2879 } // namespace gles2 2880 } // namespace gles2
2880 } // namespace gpu 2881 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/command_buffer/client/gles2_implementation.cc ('k') | gpu/command_buffer/client/mapped_memory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698