Index: cc/output/overlay_strategy_common.h |
diff --git a/cc/output/overlay_strategy_common.h b/cc/output/overlay_strategy_common.h |
index 6d8c40559eb6afed356c8430ec9d0c73040fb75b..ca60a6f73032b961ea8d5060a5c106cfb14b9a30 100644 |
--- a/cc/output/overlay_strategy_common.h |
+++ b/cc/output/overlay_strategy_common.h |
@@ -16,15 +16,27 @@ class OverlayCandidateValidator; |
class StreamVideoDrawQuad; |
class TextureDrawQuad; |
+enum OverlayResult { |
+ DID_NOT_CREATE_OVERLAY, |
+ CREATED_OVERLAY_STOP_LOOKING, |
+ CREATED_OVERLAY_KEEP_LOOKING, |
+}; |
+ |
class CC_EXPORT OverlayStrategyCommonDelegate { |
public: |
virtual ~OverlayStrategyCommonDelegate() {} |
- virtual bool TryOverlay(OverlayCandidateValidator* capability_checker, |
- RenderPassList* render_passes_in_draw_order, |
- OverlayCandidateList* candidate_list, |
- const OverlayCandidate& candidate, |
- QuadList::Iterator iter, |
- float device_scale_factor) = 0; |
+ |
+ // Check if |candidate| can be promoted into an overlay. If so, add it to |
+ // |candidate_list| and update the quads in |render_passes_in_draw_order| |
+ // as necessary. When returning CREATED_OVERLAY_KEEP_LOOKING, |iter| is |
+ // updated to point to the next quad to evaluate. |
+ virtual OverlayResult TryOverlay( |
+ OverlayCandidateValidator* capability_checker, |
+ RenderPassList* render_passes_in_draw_order, |
+ OverlayCandidateList* candidate_list, |
+ const OverlayCandidate& candidate, |
+ QuadList::Iterator* iter, |
+ float device_scale_factor) = 0; |
}; |
class CC_EXPORT OverlayStrategyCommon : public OverlayProcessor::Strategy { |