append_quads_data.h 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  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. #ifndef CC_LAYERS_APPEND_QUADS_DATA_H_
  5. #define CC_LAYERS_APPEND_QUADS_DATA_H_
  6. #include <stdint.h>
  7. #include <vector>
  8. #include "cc/cc_export.h"
  9. #include "components/viz/common/surfaces/surface_id.h"
  10. #include "third_party/abseil-cpp/absl/types/optional.h"
  11. namespace cc {
  12. // Set by the layer appending quads.
  13. class CC_EXPORT AppendQuadsData {
  14. public:
  15. AppendQuadsData();
  16. ~AppendQuadsData();
  17. int64_t num_incomplete_tiles = 0;
  18. int64_t num_missing_tiles = 0;
  19. int64_t visible_layer_area = 0;
  20. int64_t approximated_visible_content_area = 0;
  21. // This is total of the following two areas.
  22. int64_t checkerboarded_visible_content_area = 0;
  23. // This is the area outside interest rect.
  24. int64_t checkerboarded_no_recording_content_area = 0;
  25. // This is the area within interest rect.
  26. int64_t checkerboarded_needs_raster_content_area = 0;
  27. // The non-default number of BeginFrames to wait before forcibly activating
  28. // this CompositorFrame.
  29. absl::optional<uint32_t> deadline_in_frames;
  30. // Indicates whether or not one of the layers wants to use the default
  31. // activation deadline.
  32. bool use_default_lower_bound_deadline = false;
  33. // This is the set of surface IDs that must have corresponding
  34. // active CompositorFrames so that this CompositorFrame can
  35. // activate.
  36. std::vector<viz::SurfaceId> activation_dependencies;
  37. // Indicates if any layer has SharedElementResourceIds which need to be
  38. // swapped with actual viz::ResourceIds in the Viz process.
  39. bool has_shared_element_resources = false;
  40. };
  41. } // namespace cc
  42. #endif // CC_LAYERS_APPEND_QUADS_DATA_H_