OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 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 | 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 "cc/output/software_renderer.h" | 5 #include "cc/output/software_renderer.h" |
6 | 6 |
7 #include "base/debug/trace_event.h" | 7 #include "base/debug/trace_event.h" |
8 #include "cc/base/math_util.h" | 8 #include "cc/base/math_util.h" |
9 #include "cc/output/compositor_frame.h" | 9 #include "cc/output/compositor_frame.h" |
10 #include "cc/output/compositor_frame_ack.h" | 10 #include "cc/output/compositor_frame_ack.h" |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 capabilities_.max_texture_size = resource_provider_->max_texture_size(); | 69 capabilities_.max_texture_size = resource_provider_->max_texture_size(); |
70 capabilities_.best_texture_format = | 70 capabilities_.best_texture_format = |
71 resource_provider_->best_texture_format(); | 71 resource_provider_->best_texture_format(); |
72 } | 72 } |
73 capabilities_.using_set_visibility = true; | 73 capabilities_.using_set_visibility = true; |
74 // The updater can access bitmaps while the SoftwareRenderer is using them. | 74 // The updater can access bitmaps while the SoftwareRenderer is using them. |
75 capabilities_.allow_partial_texture_updates = true; | 75 capabilities_.allow_partial_texture_updates = true; |
76 capabilities_.using_partial_swap = true; | 76 capabilities_.using_partial_swap = true; |
77 | 77 |
78 capabilities_.using_map_image = Settings().use_map_image; | 78 capabilities_.using_map_image = Settings().use_map_image; |
| 79 capabilities_.using_shared_memory_resources = true; |
79 } | 80 } |
80 | 81 |
81 SoftwareRenderer::~SoftwareRenderer() {} | 82 SoftwareRenderer::~SoftwareRenderer() {} |
82 | 83 |
83 const RendererCapabilities& SoftwareRenderer::Capabilities() const { | 84 const RendererCapabilities& SoftwareRenderer::Capabilities() const { |
84 return capabilities_; | 85 return capabilities_; |
85 } | 86 } |
86 | 87 |
87 void SoftwareRenderer::BeginDrawingFrame(DrawingFrame* frame) { | 88 void SoftwareRenderer::BeginDrawingFrame(DrawingFrame* frame) { |
88 TRACE_EVENT0("cc", "SoftwareRenderer::BeginDrawingFrame"); | 89 TRACE_EVENT0("cc", "SoftwareRenderer::BeginDrawingFrame"); |
(...skipping 399 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
488 visible_ = visible; | 489 visible_ = visible; |
489 } | 490 } |
490 | 491 |
491 void SoftwareRenderer::SetDiscardBackBufferWhenNotVisible(bool discard) { | 492 void SoftwareRenderer::SetDiscardBackBufferWhenNotVisible(bool discard) { |
492 // TODO(piman, skaslev): Can we release the backbuffer? We don't currently | 493 // TODO(piman, skaslev): Can we release the backbuffer? We don't currently |
493 // receive memory policy yet anyway. | 494 // receive memory policy yet anyway. |
494 NOTIMPLEMENTED(); | 495 NOTIMPLEMENTED(); |
495 } | 496 } |
496 | 497 |
497 } // namespace cc | 498 } // namespace cc |
OLD | NEW |