performance_properties.h 854 B

123456789101112131415161718192021222324252627
  1. // Copyright 2015 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_PERFORMANCE_PROPERTIES_H_
  5. #define CC_LAYERS_PERFORMANCE_PROPERTIES_H_
  6. #include "ui/gfx/geometry/transform.h"
  7. namespace cc {
  8. // Container for properties used to measure performance
  9. template <typename LayerType>
  10. struct CC_EXPORT PerformanceProperties {
  11. PerformanceProperties()
  12. : num_fixed_point_hits(0), translation_from_last_frame(0.f) {}
  13. // This value stores the numer of times a layer has hit a fixed point
  14. // during commit. It is used to detect jitter in layers.
  15. int num_fixed_point_hits;
  16. float translation_from_last_frame;
  17. gfx::Transform last_commit_screen_space_transform;
  18. };
  19. } // namespace cc
  20. #endif // CC_LAYERS_PERFORMANCE_PROPERTIES_H_