1 // Copyright 2012 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef CC_TEST_RENDER_PASS_TEST_COMMON_H_ 6 #define CC_TEST_RENDER_PASS_TEST_COMMON_H_ 7 8 #include "cc/quads/render_pass.h" 9 10 namespace cc { 11 class ResourceProvider; 12 } 13 14 namespace cc { 15 16 class TestRenderPass : public cc::RenderPass { 17 public: 18 static scoped_ptr<TestRenderPass> Create() { 19 return make_scoped_ptr(new TestRenderPass); 20 } 21 22 void AppendQuad(scoped_ptr<cc::DrawQuad> quad); 23 void AppendSharedQuadState(scoped_ptr<cc::SharedQuadState> state); 24 25 void AppendOneOfEveryQuadType( 26 cc::ResourceProvider*, RenderPass::Id child_pass); 27 28 protected: 29 TestRenderPass() : RenderPass() {} 30 }; 31 32 } // namespace cc 33 34 #endif // CC_TEST_RENDER_PASS_TEST_COMMON_H_ 35