OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "examples/surfaces_app/child_impl.h" | 5 #include "examples/surfaces_app/child_impl.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "cc/output/compositor_frame.h" | 8 #include "cc/output/compositor_frame.h" |
9 #include "cc/output/delegated_frame_data.h" | 9 #include "cc/output/delegated_frame_data.h" |
10 #include "cc/quads/render_pass.h" | 10 #include "cc/quads/render_pass.h" |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 rect, | 84 rect, |
85 color_, | 85 color_, |
86 force_anti_aliasing_off); | 86 force_anti_aliasing_off); |
87 | 87 |
88 scoped_ptr<DelegatedFrameData> delegated_frame_data(new DelegatedFrameData); | 88 scoped_ptr<DelegatedFrameData> delegated_frame_data(new DelegatedFrameData); |
89 delegated_frame_data->render_pass_list.push_back(pass.Pass()); | 89 delegated_frame_data->render_pass_list.push_back(pass.Pass()); |
90 | 90 |
91 scoped_ptr<CompositorFrame> frame(new CompositorFrame); | 91 scoped_ptr<CompositorFrame> frame(new CompositorFrame); |
92 frame->delegated_frame_data = delegated_frame_data.Pass(); | 92 frame->delegated_frame_data = delegated_frame_data.Pass(); |
93 | 93 |
94 surface_->SubmitFrame(mojo::SurfaceId::From(id_), | 94 surface_->SubmitFrame(mojo::SurfaceId::From(id_), mojo::Frame::From(*frame), |
95 mojo::Frame::From(*frame)); | 95 mojo::Closure()); |
96 produce_callback_.Run(SurfaceId::From(id_)); | 96 produce_callback_.Run(SurfaceId::From(id_)); |
97 } | 97 } |
98 | 98 |
99 } // namespace examples | 99 } // namespace examples |
100 } // namespace mojo | 100 } // namespace mojo |
OLD | NEW |